aboutsummaryrefslogtreecommitdiff
path: root/reproduce/software/make
diff options
context:
space:
mode:
authorMohammad Akhlaghi <mohammad@akhlaghi.org>2019-07-28 02:32:20 +0100
committerMohammad Akhlaghi <mohammad@akhlaghi.org>2019-07-28 02:53:34 +0100
commit6ef4cc854d1df46b719de5d66b45537b0aa11f92 (patch)
treea4b9680ef483167e41089a4a8b911cca70c11164 /reproduce/software/make
parent8847155563e25aa70663413f6a8dc9657ca79993 (diff)
Single wrapper instead of old ./configure, Makefile and ./for-group
Until now, to work on a project, it was necessary to `./configure' it and build the software. Then we had to run `.local/bin/make' to run the project and do the analysis every time. If the project was a shared project between many users on a large server, it was necessary to call the `./for-group' script. This way of managing the project had a major problem: since the user directly called the lower-level `./configure' or `.local/bin/make' it was not possible to provide high-level control (for example limiting the environment variables). This was especially noticed recently with a bug that was related to environment variables (bug #56682). With this commit, this problem is solved using a single script called `project' in the top directory. To configure and build the project, users can now run these commands: $ ./project configure $ ./project make To work on the project with other users in a group these commands can be used: $ ./project configure --group=GROUPNAME $ ./project make --group=GROUPNAME The old options to both configure and make the project are still valid. Run `./project --help' to see a list. For example: $ ./project configure -e --host-cc $ ./project make -j8 The old `configure' script has been moved to `reproduce/software/bash/configure.sh' and is called by the new `./project' script. The `./project' script now just manages the options, then passes control to the `configure.sh' script. For the "make" step, it also reads the options, then calls Make. So in the lower-level nothing has changed. Only the `./project' script is now the single/direct user interface of the project. On a parallel note: as part of bug #56682, we also found out that on some macOS systems, the `DYLD_LIBRARY_PATH' environment variable has to be set to blank. This is no problem because RPATH is automatically set in macOS and the executables and libraries contain the absolute address of the libraries they should link with. But having `DYLD_LIBRARY_PATH' can conflict with some low-level system libraries and cause very hard to debug linking errors (like that reported in the bug report). This fixes bug #56682.
Diffstat (limited to 'reproduce/software/make')
-rwxr-xr-xreproduce/software/make/atlas-multiple.mk4
-rwxr-xr-xreproduce/software/make/atlas-single.mk4
-rw-r--r--reproduce/software/make/basic.mk10
-rw-r--r--reproduce/software/make/high-level.mk13
-rw-r--r--reproduce/software/make/python.mk4
5 files changed, 23 insertions, 12 deletions
diff --git a/reproduce/software/make/atlas-multiple.mk b/reproduce/software/make/atlas-multiple.mk
index fef25c7..f5efb35 100755
--- a/reproduce/software/make/atlas-multiple.mk
+++ b/reproduce/software/make/atlas-multiple.mk
@@ -3,8 +3,8 @@
# ------------------------------------------------------------------------
# !!!!! IMPORTANT NOTES !!!!!
#
-# This Makefile will be run during the initial `./configure' script. It is
-# not included into the reproduction pipe after that.
+# This Makefile will be run during the initial `./project configure'
+# script. It is not included into the reproduction pipe after that.
#
# ------------------------------------------------------------------------
#
diff --git a/reproduce/software/make/atlas-single.mk b/reproduce/software/make/atlas-single.mk
index dde2926..c4621ce 100755
--- a/reproduce/software/make/atlas-single.mk
+++ b/reproduce/software/make/atlas-single.mk
@@ -3,8 +3,8 @@
# ------------------------------------------------------------------------
# !!!!! IMPORTANT NOTES !!!!!
#
-# This Makefile will be run during the initial `./configure' script. It is
-# not included into the reproduction pipe after that.
+# This Makefile will be run during the initial `./project configure'
+# script. It is not included into the reproduction pipe after that.
#
# ------------------------------------------------------------------------
#
diff --git a/reproduce/software/make/basic.mk b/reproduce/software/make/basic.mk
index bab37ed..e4ab55a 100644
--- a/reproduce/software/make/basic.mk
+++ b/reproduce/software/make/basic.mk
@@ -4,8 +4,8 @@
# ------------------------------------------------------------------------
# !!!!! IMPORTANT NOTES !!!!!
#
-# This Makefile will be run by the initial `./configure' script. It is not
-# included into the project after that.
+# This Makefile will be run by the initial `./project configure' script. It
+# is not included into the project after that.
#
# This Makefile builds very low-level and basic tools like GNU Tar, GNU
# Bash, GNU Make, GCC and etc. Therefore this is the only Makefile in the
@@ -58,7 +58,11 @@ export PKG_CONFIG_LIBDIR := $(ildir)/pkgconfig
export CPPFLAGS := -I$(idir)/include $(CPPFLAGS)
export LD_LIBRARY_PATH := $(ildir):$(LD_LIBRARY_PATH)
export LDFLAGS := $(rpath_command) -L$(ildir) $(LDFLAGS)
-export DYLD_LIBRARY_PATH := $(ildir):$(DYLD_LIBRARY_PATH)
+
+# RPATH is automatically written in macOS, so `DYLD_LIBRARY_PATH' is
+# ultimately redundant. But on some systems, even having a single value
+# causes crashs (see bug #56682). So we'll just give it no value at all.
+export DYLD_LIBRARY_PATH :=
# Define the top-level basic programs (that don't depend on any other).
top-level-programs = low-level-links gcc
diff --git a/reproduce/software/make/high-level.mk b/reproduce/software/make/high-level.mk
index dee23ca..b9a70de 100644
--- a/reproduce/software/make/high-level.mk
+++ b/reproduce/software/make/high-level.mk
@@ -3,8 +3,8 @@
# ------------------------------------------------------------------------
# !!!!! IMPORTANT NOTES !!!!!
#
-# This Makefile will be run by the initial `./configure' script. It is not
-# included into the reproduction pipe after that.
+# This Makefile will be run by the initial `./project configure' script. It
+# is not included into the reproduction pipe after that.
#
# ------------------------------------------------------------------------
#
@@ -76,7 +76,11 @@ export LD_RUN_PATH := $(ildir):$(il64dir)
export PKG_CONFIG_PATH := $(ildir)/pkgconfig
export LD_LIBRARY_PATH := $(ildir):$(il64dir)
export PKG_CONFIG_LIBDIR := $(ildir)/pkgconfig
-export DYLD_LIBRARY_PATH := $(ildir):$(il64dir)
+
+# RPATH is automatically written in macOS, so `DYLD_LIBRARY_PATH' is
+# ultimately redundant. But on some systems, even having a single value
+# causes crashs (see bug #56682). So we'll just give it no value at all.
+export DYLD_LIBRARY_PATH :=
# Building flags:
#
@@ -90,6 +94,9 @@ export CXXFLAGS := -liconv
endif
+
+
+
# We want the download to happen on a single thread. So we need to define a
# lock, and call a special script we have written for this job. These are
# placed here because we want them both in the `high-level.mk' and
diff --git a/reproduce/software/make/python.mk b/reproduce/software/make/python.mk
index 22b668f..ed1c87d 100644
--- a/reproduce/software/make/python.mk
+++ b/reproduce/software/make/python.mk
@@ -3,8 +3,8 @@
# ------------------------------------------------------------------------
# !!!!! IMPORTANT NOTES !!!!!
#
-# This Makefile will be run by the initial `./configure' script. It is not
-# included into the reproduction pipe after that.
+# This Makefile will be run by the initial `./project configure' script. It
+# is not included into the reproduction pipe after that.
#
# ------------------------------------------------------------------------
#