lmi-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lmi-commits] [lmi] master 2804717: Define and use exec_prefix in librar


From: Greg Chicares
Subject: [lmi-commits] [lmi] master 2804717: Define and use exec_prefix in library makefiles
Date: Wed, 24 May 2017 09:32:28 -0400 (EDT)

branch: master
commit 28047171e32715b83220437d48f8048e91973d24
Author: Gregory W. Chicares <address@hidden>
Commit: Gregory W. Chicares <address@hidden>

    Define and use exec_prefix in library makefiles
    
    The default definition does nothing new; the purpose of this change is
    to allow the default to be overridden, so that builds for various
    architectures (or compilers, or other options) can be maintained in the
    same filesystem.
---
 install_libxml2_libxslt.make | 18 +++++++++++++++---
 install_wx.make              |  5 ++++-
 install_wxpdfdoc.make        |  5 +++++
 3 files changed, 24 insertions(+), 4 deletions(-)

diff --git a/install_libxml2_libxslt.make b/install_libxml2_libxslt.make
index 2e5766a..eb2ab87 100644
--- a/install_libxml2_libxslt.make
+++ b/install_libxml2_libxslt.make
@@ -49,6 +49,7 @@ $(zlib_version).tar.gz: host_path :=
 mingw_dir     := /MinGW_
 
 prefix        := /opt/lmi/local
+exec_prefix   := $(prefix)
 
 cache_dir     := /cache_for_lmi/downloads
 
@@ -79,7 +80,9 @@ endif
 # that it builds; apparently that doesn't matter because libxml2
 # doesn't link it explicitly.
 
-$(zlib_version)_options :=
+$(zlib_version)_options := \
+  --prefix=$(prefix) \
+  --eprefix=$(exec_prefix) \
 
 $(zlib_version)_overrides := \
   LDSHARED='gcc -shared -Wl,--out-implib,libz1.dll.a' \
@@ -97,6 +100,8 @@ $(zlib_version)_overrides := \
 #   .deps/DOCBparser.Plo:1: *** multiple target patterns.  Stop.
 
 xmlsoft_common_options := \
+  --prefix=$(prefix) \
+  --exec-prefix=$(exec_prefix) \
   --build=$(build_type) \
   --host=$(host_type) \
   --disable-dependency-tracking \
@@ -113,9 +118,15 @@ $(libxml2_version)_options := \
   --without-modules \
   --without-schematron \
 
+# The '--with-libxml-prefix' option is documented thus:
+#   "Specify location of libxml config"
+# and libxml2 installs 'xml2-config' under its own $exec_prefix if
+# that differs from its own $prefix. It would seem clearer if this
+# libxslt option were named '--with-libxml-exec-prefix'.
+
 $(libxslt_version)_options := \
   $(xmlsoft_common_options) \
-  --with-libxml-prefix=$(prefix) \
+  --with-libxml-prefix=$(exec_prefix) \
   --without-crypto \
 
 # Utilities 
####################################################################
@@ -145,6 +156,7 @@ initial_setup     :| clobber
 .PHONY: initial_setup
 initial_setup:
        $(MKDIR) --parents $(prefix)
+       $(MKDIR) --parents $(exec_prefix)
        $(MKDIR) --parents $(cache_dir)
        $(MKDIR) --parents $(xml_dir)
 
@@ -179,7 +191,7 @@ $(libraries):
        -[ -e address@hidden ] && $(PATCH) --directory=$(xml_dir) --strip=1 
<address@hidden
        cd $(xml_dir)/$@ \
          && export PATH="$(mingw_bin_dir):${PATH}" \
-         && $(address@hidden) ./configure --prefix=$(prefix) $(address@hidden) 
\
+         && $(address@hidden) ./configure $(address@hidden) \
          && $(MAKE) \
          && $(MAKE) install \
 
diff --git a/install_wx.make b/install_wx.make
index 904aab1..6590b0e 100644
--- a/install_wx.make
+++ b/install_wx.make
@@ -26,6 +26,7 @@ this_makefile := $(abspath $(lastword $(MAKEFILE_LIST)))
 mingw_dir     := /MinGW_
 
 prefix        := /opt/lmi/local
+exec_prefix   := $(prefix)
 
 cache_dir     := /cache_for_lmi/downloads
 
@@ -94,6 +95,7 @@ wx_cxx_flags   := -fno-omit-frame-pointer -std=c++11
 
 config_options = \
   --prefix=$(prefix) \
+  --exec-prefix=$(exec_prefix) \
   --build=$(build_type) \
   --host=$(host_type) \
   --disable-apple_ieee \
@@ -149,6 +151,7 @@ initial_setup: clobber
 .PHONY: initial_setup
 initial_setup:
        $(MKDIR) --parents $(prefix)
+       $(MKDIR) --parents $(exec_prefix)
        $(MKDIR) --parents $(cache_dir)
        $(MKDIR) --parents $(wx_dir)
 
@@ -200,6 +203,6 @@ clobber:
 # WX !! The 'uninstall' target doesn't remove quite everything.
        -cd $(build_dir) && $(MAKE) uninstall distclean
        -$(RM) --force --recursive $(prefix)/include/wx-$(basename 
$(wx_version))
-       -$(RM) --force --recursive $(prefix)/lib/wx
+       -$(RM) --force --recursive $(exec_prefix)/lib/wx
        -$(RM) --force --recursive $(wx_dir)
 
diff --git a/install_wxpdfdoc.make b/install_wxpdfdoc.make
index 14cd36b..d29973b 100644
--- a/install_wxpdfdoc.make
+++ b/install_wxpdfdoc.make
@@ -26,6 +26,7 @@ this_makefile := $(abspath $(lastword $(MAKEFILE_LIST)))
 mingw_dir     := /MinGW_
 
 prefix        := /opt/lmi/local
+exec_prefix   := $(prefix)
 
 cache_dir     := /cache_for_lmi/downloads
 
@@ -67,6 +68,9 @@ wx_cxx_flags     := -fno-omit-frame-pointer -std=c++11
 
 config_options = \
   --prefix=$(prefix) \
+  --exec-prefix=$(exec_prefix) \
+  --with-wx-prefix=$(prefix) \
+  --with-wx-exec-prefix=$(exec_prefix) \
   --build=$(build_type) \
   --host=$(host_type) \
   --disable-dependency-tracking \
@@ -92,6 +96,7 @@ all: clobber
 .PHONY: initial_setup
 initial_setup:
        $(MKDIR) --parents $(prefix)
+       $(MKDIR) --parents $(exec_prefix)
        $(MKDIR) --parents $(cache_dir)
        $(MKDIR) --parents $(wxpdfdoc_dir)
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]