[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lmi-commits] [lmi] odd/multiarch 8af108a 4/8: Rework the 'install' targ
From: |
Greg Chicares |
Subject: |
[lmi-commits] [lmi] odd/multiarch 8af108a 4/8: Rework the 'install' target to support multiple architectures [351] |
Date: |
Sat, 27 Apr 2019 09:59:22 -0400 (EDT) |
branch: odd/multiarch
commit 8af108afcc0f8fe187e4e2388b5a7f08dd67f509
Author: Gregory W. Chicares <address@hidden>
Commit: Gregory W. Chicares <address@hidden>
Rework the 'install' target to support multiple architectures [351]
See:
https://lists.nongnu.org/archive/html/lmi/2019-04/msg00023.html
| [Supporting] multiple installation directories would be
| difficult with today's 'install' target, which simply
| - copies lmi's own binaries to $INSTALL/bin
| - copies (or generates) data in $INSTALL/data
| and relies on $PATH and $WINEPATH to find libraries for the
| appropriate architecture. [To make] an $INSTALL directory
| configurable, and [permit] multiple independent installations:
...
| Copy all required libraries as well as lmi's own binaries, so that
| each $INSTALL directory would have a complete set and there'd be no
| need to alter any path variable in the environment.
Also see:
https://lists.nongnu.org/archive/html/lmi/2019-04/msg00042.html
---
workhorse.make | 17 ++++++++++-------
1 file changed, 10 insertions(+), 7 deletions(-)
diff --git a/workhorse.make b/workhorse.make
index f89fe50..d54f6ef 100644
--- a/workhorse.make
+++ b/workhorse.make
@@ -1043,12 +1043,9 @@ lmi_msw_res.o: lmi.ico
################################################################################
# Install.
-
-# TODO ?? This line
-# $(CP) --preserve --update $^
-# isn't quite right: running 'make install build_type=[...]' with
-# different build_types and picking the latest version of each
-# component can produce a mismatched set.
+#
+# Architecture-independent files are copied with 'cp --update'.
+# Architecture-dependent files are copied without '--update'.
data_files := \
$(wildcard $(addprefix $(srcdir)/,*.ico *.png *.xml *.xrc *.xsd *.xsl)) \
@@ -1056,6 +1053,12 @@ data_files := \
help_files := \
$(wildcard $(addprefix $(srcdir)/,*.html)) \
+installable_binaries := \
+ $(default_targets) \
+ $(wildcard $(localbindir)/*$(SHREXT)) \
+ $(wildcard $(locallibdir)/*$(SHREXT)) \
+ $(wildcard $(prefix)/third_party/bin/*$(EXEEXT)) \
+
.PHONY: install
install: $(default_targets)
address@hidden -d $(exec_prefix) ] || $(MKDIR) --parents
$(exec_prefix)
@@ -1063,7 +1066,7 @@ install: $(default_targets)
address@hidden -d $(datadir) ] || $(MKDIR) --parents $(datadir)
address@hidden -d $(test_dir) ] || $(MKDIR) --parents $(test_dir)
address@hidden -d $(touchstone_dir) ] || $(MKDIR) --parents
$(touchstone_dir)
- @$(CP) --preserve --update $^ $(bindir)
+ @$(CP) --preserve $(installable_binaries) $(bindir)
@$(CP) --preserve --update $(data_files) $(datadir)
@$(CP) --preserve --update $(help_files) $(datadir)
@datadir=$(datadir) srcdir=$(srcdir) $(srcdir)/mst_to_xst.sh
- [lmi-commits] [lmi] odd/multiarch updated (62e0e85 -> 723fd45), Greg Chicares, 2019/04/27
- [lmi-commits] [lmi] odd/multiarch 9170c01 1/8: Add a missing word to a comment, Greg Chicares, 2019/04/27
- [lmi-commits] [lmi] odd/multiarch 0c52510 3/8: Revert "Install gcc runtime libraries before building default targets", Greg Chicares, 2019/04/27
- [lmi-commits] [lmi] odd/multiarch e37d450 2/8: Copy compiler runtime files to build directory, Greg Chicares, 2019/04/27
- [lmi-commits] [lmi] odd/multiarch 8af108a 4/8: Rework the 'install' target to support multiple architectures [351],
Greg Chicares <=
- [lmi-commits] [lmi] odd/multiarch 894cbe9 5/8: Remove unnecessary host specifications, Greg Chicares, 2019/04/27
- [lmi-commits] [lmi] odd/multiarch 723fd45 8/8: When eviscerating, also remove the bin/ subdirectory, Greg Chicares, 2019/04/27
- [lmi-commits] [lmi] odd/multiarch dd609f5 7/8: Copy compiler runtime files to $(bindir) without '--update', as intended, Greg Chicares, 2019/04/27
- [lmi-commits] [lmi] odd/multiarch 155086d 6/8: Improve $log_dir concinnity, Greg Chicares, 2019/04/27