diff options
author | Richard Levitte <levitte@openssl.org> | 2016-07-06 18:50:47 +0200 |
---|---|---|
committer | Richard Levitte <levitte@openssl.org> | 2016-07-07 15:07:32 +0200 |
commit | b2de11c58b57e7f0d58c6f8a1d4177705650647e (patch) | |
tree | 6d408c6633b961cd668699063dd5dc6ff9f7eae5 /Configurations | |
parent | ee0a61cfb827097d510f3ef09d00d0382d9ff46d (diff) |
Versioning engines default location: the Unix case
OpenSSL engines are tied to the OpenSSL shared library versions,
starting with OpenSSL 1.1. We therefore need to install them in
directories which have the shared library version in it's name, to
easily allow multiple OpenSSL versions to be installed at the same
time.
For Unix, the default installation directory is changed from
$PREFIX/lib/engines to $PREFIX/lib/engines-${major}_${minor} (mingw)
or $PREFIX/lib/engines-${major}.${minor} (all but mingw)
($PREFIX is the directory given for the configuration option --prefix,
and ${major} and ${minor} are the major and minor shared library
version numbers)
Reviewed-by: Rich Salz <rsalz@openssl.org>
Diffstat (limited to 'Configurations')
-rw-r--r-- | Configurations/unix-Makefile.tmpl | 24 |
1 files changed, 14 insertions, 10 deletions
diff --git a/Configurations/unix-Makefile.tmpl b/Configurations/unix-Makefile.tmpl index 9898961561..af7a5e75a3 100644 --- a/Configurations/unix-Makefile.tmpl +++ b/Configurations/unix-Makefile.tmpl @@ -14,6 +14,10 @@ sub windowsdll { $config{target} =~ /^(?:Cygwin|mingw)/ } + our $sover = $config{target} =~ /^mingw/ + ? $config{shlib_major}."_".$config{shlib_minor} + : $config{shlib_major}.".".$config{shlib_minor}; + # shlib and shlib_simple both take a static library name and figure # out what the shlib name should be. # @@ -144,7 +148,7 @@ LIBDIR={- # our $libdir = $config{libdir} || "lib$multilib"; $libdir -} ENGINESDIR={- use File::Spec::Functions; - catdir($prefix,$libdir,"engines") -} + catdir($prefix,$libdir,"engines-$sover") -} MANDIR=$(INSTALLTOP)/share/man DOCDIR=$(INSTALLTOP)/share/doc/$(BASENAME) @@ -433,7 +437,7 @@ uninstall_dev: install_engines: @[ -n "$(INSTALLTOP)" ] || (echo INSTALLTOP should not be empty; exit 1) - @$(PERL) $(SRCDIR)/util/mkdir-p.pl $(DESTDIR)$(INSTALLTOP)/$(LIBDIR)/engines/ + @$(PERL) $(SRCDIR)/util/mkdir-p.pl $(DESTDIR)$(ENGINESDIR)/ @echo "*** Installing engines" @set -e; for e in dummy $(ENGINES); do \ if [ "$$e" = "dummy" ]; then continue; fi; \ @@ -441,11 +445,11 @@ install_engines: if [ "$$fn" = '{- dso("ossltest") -}' ]; then \ continue; \ fi; \ - echo "install $$e -> $(DESTDIR)$(INSTALLTOP)/$(LIBDIR)/engines/$$fn"; \ - cp $$e $(DESTDIR)$(INSTALLTOP)/$(LIBDIR)/engines/$$fn.new; \ - chmod 755 $(DESTDIR)$(INSTALLTOP)/$(LIBDIR)/engines/$$fn.new; \ - mv -f $(DESTDIR)$(INSTALLTOP)/$(LIBDIR)/engines/$$fn.new \ - $(DESTDIR)$(INSTALLTOP)/$(LIBDIR)/engines/$$fn; \ + echo "install $$e -> $(DESTDIR)$(ENGINESDIR)/$$fn"; \ + cp $$e $(DESTDIR)$(ENGINESDIR)/$$fn.new; \ + chmod 755 $(DESTDIR)$(ENGINESDIR)/$$fn.new; \ + mv -f $(DESTDIR)$(ENGINESDIR)/$$fn.new \ + $(DESTDIR)$(ENGINESDIR)/$$fn; \ done uninstall_engines: @@ -456,10 +460,10 @@ uninstall_engines: if [ "$$fn" = '{- dso("ossltest") -}' ]; then \ continue; \ fi; \ - echo "$(RM) $(DESTDIR)$(INSTALLTOP)/$(LIBDIR)/engines/$$fn"; \ - $(RM) $(DESTDIR)$(INSTALLTOP)/$(LIBDIR)/engines/$$fn; \ + echo "$(RM) $(DESTDIR)$(ENGINESDIR)/$$fn"; \ + $(RM) $(DESTDIR)$(ENGINESDIR)/$$fn; \ done - -$(RMDIR) $(DESTDIR)$(INSTALLTOP)/$(LIBDIR)/engines + -$(RMDIR) $(DESTDIR)$(ENGINESDIR) install_runtime: @[ -n "$(INSTALLTOP)" ] || (echo INSTALLTOP should not be empty; exit 1) |