Skip to content

Commit

Permalink
Rename INSTALL_PREFIX to DESTDIR, remove option --install_prefix
Browse files Browse the repository at this point in the history
INSTALL_PREFIX is a confusing name, as there's also --prefix.
Instead, tag along with the rest of the open source world and adopt
the Makefile variable DESTDIR to designate the desired staging
directory.

The Configure option --install_prefix is removed, the only way to
designate a staging directory is with the Makefile variable (this is
also implemented for VMS' descrip.mms et al).

Reviewed-by: Rich Salz <[email protected]>
  • Loading branch information
levitte committed Feb 12, 2016
1 parent c619e81 commit 3c65577
Show file tree
Hide file tree
Showing 14 changed files with 233 additions and 239 deletions.
6 changes: 6 additions & 0 deletions CHANGES
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@

Changes between 1.0.2f and 1.1.0 [xx XXX xxxx]

*) The INSTALL_PREFIX Makefile variable has been renamed to
DESTDIR. That makes for less confusion on what this variable
is for. Also, the configuration option --install_prefix is
removed.
[Richard Levitte]

*) Heartbeat for TLS has been removed and is disabled by default
for DTLS; configure with enable-heartbeats. Code that uses the
old #define's might need to be updated.
Expand Down
24 changes: 11 additions & 13 deletions Configurations/descrip.mms.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -106,15 +106,13 @@ PROGRAMS={- join(", ", map { "-\n\t".$_.".EXE" } grep { !m|^\[\.test\]| } @{$uni
TESTPROGS={- join(", ", map { "-\n\t".$_.".EXE" } grep { m|^\[\.test\]| } @{$unified_info{programs}}) -}
SCRIPTS={- join(", ", map { "-\n\t".$_ } @{$unified_info{scripts}}) -}

# INSTALL_PREFIX is for package builders so that they can configure for, say,
# DESTDIR is for package builders so that they can configure for, say,
# SYS$COMMON:[OPENSSL] and yet have everything installed in STAGING:[USER].
# In that case, configure with --prefix=SYS$COMMON:[OPENSSL] and then run
# MMS with /MACROS=(INSTALL_PREFIX=STAGING:[USER]). The result will end
# up in STAGING:[USER.OPENSSL].
# Note that INSTALL_PREFIX can also be given at configuration time, with
# --install_prefix.
# MMS with /MACROS=(DESTDIR=STAGING:[USER]). The result will end up in
# STAGING:[USER.OPENSSL].
# Normally it is left empty.
INSTALL_PREFIX={- $config{install_prefix} -}
DESTDIR=

# Do not edit this manually. Use Configure --prefix=DIR to change this!
INSTALLTOP={- catdir($config{prefix}) || "SYS\$COMMON:[OPENSSL-\$(MAJOR).\$(MINOR)]" -}
Expand Down Expand Up @@ -160,7 +158,7 @@ NODEBUG=@
$(NODEBUG) internal_inc3 = F$PARSE("{- catdir($config{sourcedir},"[.crypto.include.internal]") -}","A.;",,,"SYNTAX_ONLY") - "A.;"
$(NODEBUG) DEFINE openssl 'openssl_inc1','openssl_inc2'
$(NODEBUG) DEFINE internal 'internal_inc1','internal_inc2','internal_inc3'
$(NODEBUG) staging_dir = "$(INSTALL_PREFIX)"
$(NODEBUG) staging_dir = "$(DESTDIR)"
$(NODEBUG) IF staging_dir .NES. "" THEN -
staging_dir = F$PARSE("A.;",staging_dir,"[]",,"SYNTAX_ONLY") - "A.;"
$(NODEBUG) !
Expand All @@ -179,7 +177,7 @@ NODEBUG=@
$(NODEBUG) !
$(NODEBUG) datatop = F$PARSE("$(OPENSSLDIR)","[000000]A.;",,,"SYNTAX_ONLY") -
- "]A.;" + ".]"
$(NODEBUG) IF "$(INSTALL_PREFIX)" .EQS. "" THEN -
$(NODEBUG) IF "$(DESTDIR)" .EQS. "" THEN -
DEFINE ossl_dataroot 'datatop'
$(NODEBUG) !
$(NODEBUG) ! Figure out the architecture
Expand All @@ -193,7 +191,7 @@ NODEBUG=@

.LAST :
$(NODEBUG) {- join("\n\t\$(NODEBUG) ", map { "DEASSIGN ".uc($_) } map { $unified_info{sharednames}->{$_} || () } @{$unified_info{libraries}}) || "!" -}
$(NODEBUG) IF "$(INSTALL_PREFIX)" .EQS. "" THEN DEASSIGN ossl_dataroot
$(NODEBUG) IF "$(DESTDIR)" .EQS. "" THEN DEASSIGN ossl_dataroot
$(NODEBUG) DEASSIGN ossl_installroot
$(NODEBUG) DEASSIGN internal
$(NODEBUG) DEASSIGN openssl
Expand Down Expand Up @@ -266,7 +264,7 @@ install_sw : all install_dev install_engines install_runtime install_config
@ WRITE SYS$OUTPUT ""
@ WRITE SYS$OUTPUT "Installation complete"
@ WRITE SYS$OUTPUT ""
@ IF "$(INSTALL_PREFIX)" .NES. "" THEN EXIT 1
@ IF "$(DESTDIR)" .NES. "" THEN EXIT 1
@ WRITE SYS$OUTPUT "Run @$(INSTALLTOP)openssl_startup to set up logical names"
@ WRITE SYS$OUTPUT "then run @$(INSTALLTOP)openssl_setup to define commands"
@ WRITE SYS$OUTPUT ""
Expand Down Expand Up @@ -316,10 +314,10 @@ install_engines : check_INSTALLTOP

install_config : [.VMS]openssl_startup.com [.VMS]openssl_shutdown.com -
check_INSTALLTOP
IF "$(INSTALL_PREFIX)" .EQS. "" THEN -
IF "$(DESTDIR)" .EQS. "" THEN -
IF F$SEARCH("OSSL_DATAROOT:[000000]CERTS.DIR;1") .EQS. "" THEN -
CREATE/DIR/PROT=(S:RWED,O:RWE,G:RE,W:RE) OSSL_DATAROOT:[CERTS]
IF "$(INSTALL_PREFIX)" .EQS. "" THEN -
IF "$(DESTDIR)" .EQS. "" THEN -
IF F$SEARCH("OSSL_DATAROOT:[000000]PRIVATE.DIR;1") .EQS. "" THEN -
CREATE/DIR/PROT=(S:RWED,O:RWE,G:,W:) OSSL_DATAROOT:[PRIVATE]
CREATE/DIR ossl_installroot:[SYS$STARTUP]
Expand Down Expand Up @@ -388,7 +386,7 @@ copy-certs :

debug_logicals :
SH LOGICAL/PROC openssl,internal,ossl_installroot
IF "$(INSTALL_PREFIX)" .EQS. "" THEN -
IF "$(DESTDIR)" .EQS. "" THEN -
SH LOGICAL/PROC ossl_dataroot

# Building targets ###################################################
Expand Down
Loading

0 comments on commit 3c65577

Please sign in to comment.