aboutsummaryrefslogtreecommitdiff
path: root/reproduce/software/make
diff options
context:
space:
mode:
Diffstat (limited to 'reproduce/software/make')
-rw-r--r--reproduce/software/make/README.md2
-rw-r--r--reproduce/software/make/atlas-multiple.mk2
-rw-r--r--reproduce/software/make/atlas-single.mk2
-rw-r--r--reproduce/software/make/basic.mk85
-rw-r--r--reproduce/software/make/build-rules.mk4
-rw-r--r--reproduce/software/make/high-level.mk145
-rw-r--r--reproduce/software/make/python.mk8
-rw-r--r--reproduce/software/make/r-cran.mk4
-rw-r--r--reproduce/software/make/xorg.mk4
9 files changed, 164 insertions, 92 deletions
diff --git a/reproduce/software/make/README.md b/reproduce/software/make/README.md
index 00afef4..0d1464d 100644
--- a/reproduce/software/make/README.md
+++ b/reproduce/software/make/README.md
@@ -1,7 +1,7 @@
Software building instructions
------------------------------
-Copyright (C) 2019-2025 Mohammad Akhlaghi <mohammad@akhlaghi.org>\
+Copyright (C) 2019-2026 Mohammad Akhlaghi <mohammad@akhlaghi.org>\
See the end of the file for license conditions.
This directory contains Makefiles that are called by the high-level
diff --git a/reproduce/software/make/atlas-multiple.mk b/reproduce/software/make/atlas-multiple.mk
index 6e7d415..a20f558 100644
--- a/reproduce/software/make/atlas-multiple.mk
+++ b/reproduce/software/make/atlas-multiple.mk
@@ -8,7 +8,7 @@
#
# ------------------------------------------------------------------------
#
-# Copyright (C) 2019-2025 Mohammad Akhlaghi <mohammad@akhlaghi.org>
+# Copyright (C) 2019-2026 Mohammad Akhlaghi <mohammad@akhlaghi.org>
#
# This Makefile is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
diff --git a/reproduce/software/make/atlas-single.mk b/reproduce/software/make/atlas-single.mk
index 2b68677..79f5b42 100644
--- a/reproduce/software/make/atlas-single.mk
+++ b/reproduce/software/make/atlas-single.mk
@@ -8,7 +8,7 @@
#
# ------------------------------------------------------------------------
#
-# Copyright (C) 2019-2025 Mohammad Akhlaghi <mohammad@akhlaghi.org>
+# Copyright (C) 2019-2026 Mohammad Akhlaghi <mohammad@akhlaghi.org>
#
# This Makefile is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
diff --git a/reproduce/software/make/basic.mk b/reproduce/software/make/basic.mk
index 745aeca..4e85807 100644
--- a/reproduce/software/make/basic.mk
+++ b/reproduce/software/make/basic.mk
@@ -21,9 +21,9 @@
#
# ------------------------------------------------------------------------
#
-# Copyright (C) 2018-2025 Mohammad Akhlaghi <mohammad@akhlaghi.org>
-# Copyright (C) 2019-2025 Raul Infante-Sainz <infantesainz@gmail.com>
-# Copyright (C) 2022-2025 Pedram Ashofteh Ardakani <pedramardakani@pm.me>
+# Copyright (C) 2018-2026 Mohammad Akhlaghi <mohammad@akhlaghi.org>
+# Copyright (C) 2019-2026 Raul Infante-Sainz <infantesainz@gmail.com>
+# Copyright (C) 2022-2026 Pedram Ashofteh Ardakani <pedramardakani@pm.me>
#
# This Makefile is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -39,7 +39,7 @@
# along with this Makefile. If not, see <http://www.gnu.org/licenses/>.
# Top level environment
-include reproduce/software/config/LOCAL.conf
+include .build/software/config/LOCAL.conf
include reproduce/software/make/build-rules.mk
include reproduce/software/config/versions.conf
include reproduce/software/config/checksums.conf
@@ -63,10 +63,13 @@ ibidir = $(BDIR)/software/installed/version-info/proglib
# editor) is installed by default, it is recommended to have it in the
# 'basic.mk', so Maneaged projects can be edited on any system (even when
# there is no command-line text editor available).
+#
+# The recipe is '@echo > /dev/null' so Make does not print "make: Nothing
+# to be done for 'all'."
targets-proglib = low-level-links \
gcc-$(gcc-version) \
nano-$(nano-version)
-all: $(foreach p, $(targets-proglib), $(ibidir)/$(p))
+all: $(foreach p, $(targets-proglib), $(ibidir)/$(p)); @echo > /dev/null
# Define the shell environment
# ----------------------------
@@ -144,10 +147,17 @@ backupservers_all = $(user_backup_urls) $(maneage_backup_urls)
topbackupserver = $(word 1, $(backupservers_all))
backupservers = $(filter-out $(topbackupserver),$(backupservers_all))
-
-
-
-
+# When building in Apptainer containers, as of 2025-04-18, we need to
+# configure Maneage as root (within the container). In such cases, we need
+# to activate the 'FORCE_UNSAFE_CONFIGURE' environment variable to build
+# some of the software. The 'if' statement is here to make sure we are in
+# Apptainer: in other situations, the "unsafe" configure script shouldn't
+# be activated. Note that this doesn't happen in Docker (where the Maneage
+# source is in the same directory) because we build a non-root ('maneager'
+# user there who executes the configure command.
+unsafe-config = if [ $$(pwd) = "/home/maneager/source" ] \
+ && [ $$(whoami) = root ]; then \
+ export FORCE_UNSAFE_CONFIGURE=1; fi
@@ -261,11 +271,8 @@ $(ibidir)/low-level-links: $(ibidir)/grep-$(grep-version) \
#
# The first set of programs to be built are those that we need to unpack
# the source code tarballs of each program. We have already installed Lzip
-# before calling 'basic.mk', so it is present and working. Hence we first
-# build the Lzipped tarball of Gzip, then use our own Gzip to unpack the
-# tarballs of the other compression programs. Once all the compression
-# programs/libraries are complete, we build our own GNU Tar and continue
-# with other software.
+# before calling 'basic.mk', so it is present and working. So the only
+# prerequisites of these (until reaching Tar) is the necessary directories.
$(lockdir): | $(BDIR); mkdir $@
$(ibidir)/gzip-$(gzip-version): | $(ibdir) $(ildir) $(lockdir)
tarball=gzip-$(gzip-version).tar.lz
@@ -273,13 +280,13 @@ $(ibidir)/gzip-$(gzip-version): | $(ibdir) $(ildir) $(lockdir)
$(call gbuild, gzip-$(gzip-version), static, , V=1)
echo "GNU Gzip $(gzip-version)" > $@
-$(ibidir)/xz-$(xz-version): $(ibidir)/gzip-$(gzip-version)
+$(ibidir)/xz-$(xz-version): | $(ibdir) $(ildir) $(lockdir)
tarball=xz-$(xz-version).tar.lz
$(call import-source, $(xz-url), $(xz-checksum))
$(call gbuild, xz-$(xz-version), static)
echo "XZ Utils $(xz-version)" > $@
-$(ibidir)/bzip2-$(bzip2-version): $(ibidir)/gzip-$(gzip-version)
+$(ibidir)/bzip2-$(bzip2-version): | $(ibdir) $(ildir) $(lockdir)
# Download the tarball.
tarball=bzip2-$(bzip2-version).tar.lz
@@ -308,7 +315,7 @@ $(ibidir)/bzip2-$(bzip2-version): $(ibidir)/gzip-$(gzip-version)
fi
cd $(ddir)
rm -rf $$tdir
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd $$tdir
$(shsrcdir)/prep-source.sh $(ibdir)
sed -e 's@\(ln -s -f \)$$(PREFIX)/bin/@\1@' Makefile \
@@ -330,30 +337,29 @@ $(ibidir)/bzip2-$(bzip2-version): $(ibidir)/gzip-$(gzip-version)
#
# Note for a static-only build: Zlib's './configure' doesn't use Autoconf's
# configure script, it just accepts a direct '--static' option.
-$(ibidir)/zlib-$(zlib-version): $(ibidir)/gzip-$(gzip-version)
+$(ibidir)/zlib-$(zlib-version): | $(ibdir) $(ildir) $(lockdir)
tarball=zlib-$(zlib-version).tar.lz
$(call import-source, $(zlib-url), $(zlib-checksum))
$(call gbuild, zlib-$(zlib-version))
echo "Zlib $(zlib-version)" > $@
# GNU Tar: When built statically, tar gives a segmentation fault on
-# unpacking Bash. So we'll build it dynamically. Note that technically, zip
-# and unzip aren't dependencies of Tar, but for a clean build, we'll set
-# Tar to be the last compression-related software (the first-set of
-# software to be built).
+# unpacking Bash. So we'll build it dynamically.
$(ibidir)/tar-$(tar-version): \
$(ibidir)/xz-$(xz-version) \
$(ibidir)/gzip-$(gzip-version) \
$(ibidir)/zlib-$(zlib-version) \
$(ibidir)/bzip2-$(bzip2-version)
-# Since all later programs depend on Tar, the configuration will hit
-# a bottleneck here: only making Tar. So its more efficient to built
-# it on multiple threads (even when the user's Make doesn't pass down
-# the number of threads).
+# About the onfigurations: nls and iconv were creating problems with
+# the dependencies on MacOs and are not relevant in the context of
+# Maneage, hence, they are disabled.
+ $(call unsafe-config)
tarball=tar-$(tar-version).tar.lz
$(call import-source, $(tar-url), $(tar-checksum))
- $(call gbuild, tar-$(tar-version), , , -j$(numthreads) V=1)
+ $(call gbuild, tar-$(tar-version), , \
+ --disable-nls am_cv_func_iconv=no, \
+ -j$(numthreads) V=1)
echo "GNU Tar $(tar-version)" > $@
@@ -418,6 +424,7 @@ $(ibidir)/ncurses-$(ncurses-version): $(ibidir)/patchelf-$(patchelf-version)
rm -f $(ibdir)/bash* $(ibdir)/awk* $(ibdir)/gawk*
# Standard build process.
+ export CFLAGS="-std=gnu17 $$CFLAGS"
$(call gbuild, ncurses-$(ncurses-version), static, \
--with-shared --enable-rpath --without-normal \
--without-debug --with-cxx-binding \
@@ -531,6 +538,7 @@ $(ibidir)/readline-$(readline-version): \
# pname=bash50-$(printf "%03d" $i); \
# wget http://ftp.gnu.org/gnu/bash/bash-5.0-patches/$pname -O ../$pname;\
# patch -p0 -i ../$pname; \
+# rm ../$pname; \
# done
# $ cd ..
# $ mv bash-5.0 bash-5.0.$number
@@ -615,7 +623,7 @@ $(ibidir)/perl-$(perl-version): $(ibidir)/patchelf-$(patchelf-version)
| awk '{printf("%d.%d", $$1, $$2)}')
cd $(ddir)
rm -rf perl-$(perl-version)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd perl-$(perl-version)
$(shsrcdir)/prep-source.sh $(ibdir)
./Configure -des \
@@ -675,14 +683,15 @@ $(ibidir)/coreutils-$(coreutils-version): \
$(ibidir)/perl-$(perl-version) \
$(ibidir)/openssl-$(openssl-version)
-# Import the source tarball.
+# Import, unpack and enter the source directory.
+ $(call unsafe-config)
tarball=coreutils-$(coreutils-version).tar.lz
$(call import-source, $(coreutils-url), $(coreutils-checksum))
# Unpack and enter the source.
cd $(ddir)
rm -rf coreutils-$(coreutils-version)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd coreutils-$(coreutils-version)
$(shsrcdir)/prep-source.sh $(ibdir)
@@ -696,7 +705,7 @@ $(ibidir)/coreutils-$(coreutils-version): \
# Fix RPATH if necessary.
if [ -f $(ibdir)/patchelf ]; then
make SHELL=$(ibdir)/bash install DESTDIR=junkinst
- unalias ls || true # avoid decorated 'ls' commands with extra characters
+ unalias ls || true # Not decorated 'ls' (with extra characters).
instprogs=$$(ls junkinst/$(ibdir))
for f in $$instprogs; do
$(ibdir)/patchelf --set-rpath $(ildir) $(ibdir)/$$f
@@ -721,7 +730,7 @@ $(ibidir)/podlators-$(podlators-version): $(ibidir)/perl-$(perl-version)
$(call import-source, $(podlators-url), $(podlators-checksum))
cd $(ddir)
rm -rf podlators-$(podlators-version)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd podlators-$(podlators-version)
$(shsrcdir)/prep-source.sh $(ibdir)
perl Makefile.PL
@@ -1008,6 +1017,7 @@ $(ibidir)/gmp-$(gmp-version): \
$(ibidir)/coreutils-$(coreutils-version)
tarball=gmp-$(gmp-version).tar.lz
$(call import-source, $(gmp-url), $(gmp-checksum))
+ export CFLAGS="-std=gnu17 $$CFLAGS"
$(call gbuild, gmp-$(gmp-version), static, \
--enable-cxx --enable-fat, \
-j$(numthreads))
@@ -1054,10 +1064,6 @@ $(ibidir)/grep-$(grep-version): $(ibidir)/coreutils-$(coreutils-version)
-j$(numthreads) V=1)
echo "GNU Grep $(grep-version)" > $@
-# M4 doesn't depend on PatchELF, but just to be consistent with the
-# levels/phases introduced here (where the compressors are level 1,
-# PatchELF is level 2, and ...), we'll set it as a dependency.
-#
# The '--with-syscmd-shell' is used as the default shell and if not given,
# 'm4' will use '/bin/sh' (which is not under Maneage control and can cause
# problems in 'high-level.mk' because it closes off the system's
@@ -1065,7 +1071,7 @@ $(ibidir)/grep-$(grep-version): $(ibidir)/coreutils-$(coreutils-version)
# library, the high-level programs will not be built). We are setting this
# default shell to Dash because M4 is built before our own Bash. Recall
# that Dash is built before we enter this Makefile.
-$(ibidir)/m4-$(m4-version): $(ibidir)/patchelf-$(patchelf-version)
+$(ibidir)/m4-$(m4-version): $(ibidir)/libiconv-$(libiconv-version)
tarball=m4-$(m4-version).tar.lz
$(call import-source, $(m4-url), $(m4-checksum))
$(call gbuild, m4-$(m4-version), static, \
@@ -1100,6 +1106,7 @@ $(ibidir)/pkg-config-$(pkgconfig-version): $(ibidir)/patchelf-$(patchelf-version
if [ x$(on_mac_os) = xyes ]; then export compiler="CC=clang"
else export compiler=""
fi
+ export CFLAGS="-std=gnu17 $$CFLAGS"
$(call gbuild, pkg-config-$(pkgconfig-version), static, \
$$compiler --with-internal-glib \
--with-pc-path=$(ildir)/pkgconfig, V=1)
@@ -1400,7 +1407,7 @@ $(ibidir)/gcc-$(gcc-version): $(ibidir)/binutils-$(binutils-version)
# Unpack GCC and prepare the 'build' directory inside it for all
# the built files.
rm -rf gcc-$(gcc-version)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
if [ $$odir != $(ddir) ]; then
ln -s $$odir/gcc-$(gcc-version) $(ddir)/gcc-$(gcc-version)
fi
@@ -1530,7 +1537,7 @@ $(ibidir)/lzip-$(lzip-version): $(ibidir)/gcc-$(gcc-version)
unpackdir=lzip-$(lzip-version)
cd $(ddir)
rm -rf $$unpackdir
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd $$unpackdir
$(shsrcdir)/prep-source.sh $(ibdir)
./configure --build --check --installdir="$(ibdir)"
diff --git a/reproduce/software/make/build-rules.mk b/reproduce/software/make/build-rules.mk
index 62cb6d5..984d0bf 100644
--- a/reproduce/software/make/build-rules.mk
+++ b/reproduce/software/make/build-rules.mk
@@ -3,7 +3,7 @@
# imported into 'basic.mk' and 'high-level.mk'. They should be activated
# with Make's 'Call' function.
#
-# Copyright (C) 2018-2025 Mohammad Akhlaghi <mohammad@akhlaghi.org>
+# Copyright (C) 2018-2026 Mohammad Akhlaghi <mohammad@akhlaghi.org>
#
# This Makefile is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -160,7 +160,7 @@ uncompress = csuffix=$$(echo $$utarball \
intarrm=0; \
intar=$$utarball; \
fi; \
- if tar -xf $$intar; then \
+ if tar -xf $$intar --no-same-owner --no-same-permissions; then \
if [ x$$intarrm = x1 ]; then rm $$intar; fi; \
else \
echo; echo "Tar error"; exit 1; \
diff --git a/reproduce/software/make/high-level.mk b/reproduce/software/make/high-level.mk
index c81f0b9..83486dc 100644
--- a/reproduce/software/make/high-level.mk
+++ b/reproduce/software/make/high-level.mk
@@ -12,8 +12,8 @@
#
# ------------------------------------------------------------------------
#
-# Copyright (C) 2018-2025 Mohammad Akhlaghi <mohammad@akhlaghi.org>
-# Copyright (C) 2019-2025 Raul Infante-Sainz <infantesainz@gmail.com>
+# Copyright (C) 2018-2026 Mohammad Akhlaghi <mohammad@akhlaghi.org>
+# Copyright (C) 2019-2026 Raul Infante-Sainz <infantesainz@gmail.com>
#
# This Makefile is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -29,7 +29,7 @@
# along with this Makefile. If not, see <http://www.gnu.org/licenses/>.
# Top level environment (same as 'basic.mk')
-include reproduce/software/config/LOCAL.conf
+include .build/software/config/LOCAL.conf
include reproduce/software/make/build-rules.mk
include reproduce/software/config/versions.conf
include reproduce/software/config/checksums.conf
@@ -123,11 +123,12 @@ ifneq ($(strip $(offline)),1)
target-texlive := $(itidir)/texlive
endif
-# Ultimate Makefile target.
+# Ultimate Makefile target. The recipe is '@echo > /dev/null' so Make does
+# not print "make: Nothing to be done for 'all'."
all: $(foreach p, $(targets-proglib), $(ibidir)/$(p)) \
$(foreach p, $(targets-python), $(ipydir)/$(p)) \
$(foreach p, $(targets-r-cran), $(ircrandir)/$(p)) \
- $(target-texlive)
+ $(target-texlive); @echo > /dev/null
# Define the shell environment
# ----------------------------
@@ -348,7 +349,8 @@ $(ibidir)/atlas-$(atlas-version):
# 'rpath_command'.
export LDFLAGS=-L$(ildir)
cd $(ddir)
- tar -xf $(tdir)/atlas-$(atlas-version).tar.lz
+ tar -xf $(tdir)/atlas-$(atlas-version).tar.lz \
+ --no-same-owner --no-same-permissions
cd ATLAS
$(shsrcdir)/prep-source.sh $(ibdir)
rm -rf build
@@ -405,7 +407,7 @@ $(ibidir)/boost-$(boost-version): \
rm -rf $(ddir)/$$unpackdir
topdir=$(pwd)
cd $(ddir)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd $$unpackdir
$(shsrcdir)/prep-source.sh $(ibdir)
./bootstrap.sh --prefix=$(idir) --with-libraries=all \
@@ -427,7 +429,8 @@ $(ibidir)/cfitsio-$(cfitsio-version):
# systems. So we need to change it to our library installation
# path. It doesn't affect GNU/Linux, so we'll just do it in any case
# to keep things clean.
- topdir=$(pwd); cd $(ddir); tar -xf $(tdir)/$$tarball
+ topdir=$(pwd); cd $(ddir)
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
customtar=cfitsio-$(cfitsio-version)-custom.tar.gz
cd cfitsio-$(cfitsio-version)
sed -i -e's|@rpath|$(ildir)|g' configure
@@ -467,7 +470,8 @@ $(ibidir)/eigen-$(eigen-version):
tarball=eigen-$(eigen-version).tar.lz
$(call import-source, $(eigen-url), $(eigen-checksum))
rm -rf $(ddir)/eigen-eigen-*
- topdir=$(pwd); cd $(ddir); tar -xf $(tdir)/$$tarball
+ topdir=$(pwd); cd $(ddir)
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd eigen-$(eigen-version)
if ! [ -d $(iidir)/eigen3 ]; then mkdir $(iidir)/eigen3; fi
cp -r Eigen/* $(iidir)/eigen3/ # Some expect 'eigen3'.
@@ -597,7 +601,7 @@ $(ibidir)/healpix-$(healpix-version): $(healpix-python-dep) \
fi
rm -rf $(ddir)/Healpix_$(healpix-version)
topdir=$(pwd); cd $(ddir);
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd Healpix_$(healpix-version)
$(shsrcdir)/prep-source.sh $(ibdir)
cd src/C/autotools
@@ -689,7 +693,7 @@ $(ibidir)/libpaper-$(libpaper-version): \
# Unpack, build the configure system, build and install.
cd $(ddir)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
unpackdir=libpaper-$(libpaper-version)
cd $$unpackdir
$(shsrcdir)/prep-source.sh $(ibdir)
@@ -727,7 +731,8 @@ $(ibidir)/libtiff-$(libtiff-version): $(ibidir)/libjpeg-$(libjpeg-version)
$(call gbuild, libtiff-$(libtiff-version), static, \
--disable-jbig \
--disable-webp \
- --disable-zstd)
+ --disable-zstd \
+ --disable-libdeflate )
echo "Libtiff $(libtiff-version)" > $@
$(ibidir)/libtirpc-$(libtirpc-version):
@@ -824,7 +829,7 @@ $(ibidir)/ninjabuild-$(ninjabuild-version): $(ibidir)/cmake-$(cmake-version)
tarball=ninjabuild-$(ninjabuild-version).tar.lz
$(call import-source, $(ninjabuild-url), $(ninjabuild-checksum))
cd $(ddir)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd ninjabuild-$(ninjabuild-version)
cmake -Bbuild-cmake
cmake --build build-cmake -j$(numthreads)
@@ -839,7 +844,7 @@ $(ibidir)/openblas-$(openblas-version):
$(call import-source, $(openblas-url), $(openblas-checksum))
if [ x$(on_mac_os) = xyes ]; then export CC=clang; fi
cd $(ddir)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd openblas-$(openblas-version)
$(shsrcdir)/prep-source.sh $(ibdir)
make -j$(numthreads)
@@ -1048,7 +1053,7 @@ $(ibidir)/astrometrynet-$(astrometrynet-version): \
# 'astrometrynet'
cd $(ddir)
rm -rf astrometry.net-$(astrometrynet-version)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd astrometry.net-$(astrometrynet-version)
$(shsrcdir)/prep-source.sh $(ibdir)
sed -e 's|cat /proc/cpuinfo|echo "Ignoring CPU info"|' \
@@ -1087,7 +1092,7 @@ $(ibidir)/cdsclient-$(cdsclient-version):
tarball=cdsclient-$(cdsclient-version).tar.lz
$(call import-source, $(cdsclient-url), $(cdsclient-checksum))
cd $(ddir)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd cdsclient-$(cdsclient-version)
$(shsrcdir)/prep-source.sh $(ibdir)
touch *
@@ -1120,7 +1125,7 @@ $(ibidir)/cmake-$(cmake-version):
# Go into the unpacked directory and prepare CMake.
cd $(ddir)
rm -rf cmake-$(cmake-version)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd cmake-$(cmake-version)
$(shsrcdir)/prep-source.sh $(ibdir)
@@ -1182,20 +1187,28 @@ $(ibidir)/ghostscript-$(ghostscript-version): \
tarball=ghostscript-$(ghostscript-version).tar.lz
$(call import-source, $(ghostscript-url), $(ghostscript-checksum))
+# On macOS we use the system compiler and linker. The system linker
+# there doesn't support '--copy-dt-needed-entries', while the one on
+# Linux crashes if we remove it. So we only activate it on macOS.
+ ldflags=""
+ if [ x$(on_mac_os) = xno ]; then
+ ldflags="LDFLAGS=-Wl,--copy-dt-needed-entries"
+ fi
+
# Unpack it and configure Ghostscript. The option
# '-DPNG_ARM_NEON_OPT=0' prevents an arm64 'neon' library from being
# required at compile time.
cd $(ddir)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd ghostscript-$(ghostscript-version)
$(shsrcdir)/prep-source.sh $(ibdir)
- ./configure --prefix=$(idir) \
+ ./configure $$ldflags \
--disable-cups \
+ --prefix=$(idir) \
--enable-dynamic \
--disable-compile-inits \
- --disable-hidden-visibility \
- CFLAGS="-DPNG_ARM_NEON_OPT=0" \
- LDFLAGS=-Wl,--copy-dt-needed-entries
+ --disable-hidden-visibility \
+ CFLAGS="-DPNG_ARM_NEON_OPT=0"
# Build and install the program and the shared libraries.
make V=1 -j$(numthreads)
@@ -1209,9 +1222,9 @@ $(ibidir)/ghostscript-$(ghostscript-version): \
# Install the fonts.
tar -xvf $(tdir)/ghostscript-fonts-std-$(ghostscript-fonts-std-version).tar.lz \
- -C $(idir)/share/ghostscript
+ -C $(idir)/share/ghostscript --no-same-owner --no-same-permissions
tar -xvf $(tdir)/ghostscript-fonts-gnu-$(ghostscript-fonts-gnu-version).tar.lz \
- -C $(idir)/share/ghostscript
+ -C $(idir)/share/ghostscript --no-same-owner --no-same-permissions
fc-cache -v $(idir)/share/ghostscript/fonts/
echo; echo "Ghostscript fonts added to Fontconfig."; echo;
@@ -1220,18 +1233,61 @@ $(ibidir)/ghostscript-$(ghostscript-version): \
rm -rf ghostscript-$(ghostscript-version)
echo "GPL Ghostscript $(ghostscript-version)" > $@
+# Gnuastro can optionally depend on libgit2, but it is not included as a
+# dependency here for the two reasons below. If you would like to have it,
+# add it as a dependency (its build instruction and dependencies are here
+# already), then remove the '--without-libgit2' configure option) and also
+# comment the following two generic configuration lines: 'outfitsnocommit'
+# and 'outfitsnoconfig'.
+# - Within Maneage, we have everything under Git already and users are
+# expected to include the version in all their products.
+# - libgit2 can only be built with CMake (which takes extremely long to
+# compile: possibly even longer than GCC!).
+# - Maneage is often run on HPCs that can have network connections
+# between the storage and processer and the necessary libgit2
+# operations on every created file can have a performance impact.
$(ibidir)/gnuastro-$(gnuastro-version): \
$(ibidir)/gsl-$(gsl-version) \
$(ibidir)/wcslib-$(wcslib-version) \
$(ibidir)/libjpeg-$(libjpeg-version) \
$(ibidir)/libtiff-$(libtiff-version) \
- $(ibidir)/libgit2-$(libgit2-version) \
$(ibidir)/ghostscript-$(ghostscript-version)
+
+# Generic installation.
tarball=gnuastro-$(gnuastro-version).tar.lz
$(call import-source, $(gnuastro-url), $(gnuastro-checksum))
- $(call gbuild, gnuastro-$(gnuastro-version), static, , \
- -j$(numthreads))
+ $(call gbuild, gnuastro-$(gnuastro-version), static, \
+ --without-libgit2, -j$(numthreads))
cp $(dtexdir)/gnuastro.tex $(ictdir)/
+
+# Generally, besides the Git commit, we are also disabling the
+# default mode of printing any type of metadata and versions of
+# dependencies in output headers (through the installation-wide
+# configuration file). This is done because within a large pipeline,
+# Gnuastro is used to create many intermediate files (that are
+# deleted shortly after being created) and it is not worth the
+# overhread to keep this information in those intermediate products:
+# it is the pipeline's responsibility to put them in the final
+# outputs. We recommend to use the Gnuastro Fits program's keyword
+# writing options to add as much contextual metadata on your final
+# products as possible. Some tips:
+# - The creation date is not good (because it is not reproducible
+# and will make simple validation hard). The project's Commit
+# should be used instead.
+# - Define a keyword to keep the public URL of the repository of
+# the Maneage'd project. In this way, a person who gets your
+# final product can easily check that for all the information
+# (including software versions and configuration options).
+ gconf=$(idir)/etc/gnuastro/gnuastro.conf
+ echo "" >> $$gconf
+ echo "# Maneage specific (see Gnuastro build rule for details)." \
+ >> $$gconf
+ echo " outfitsnocommit = 1" >> $$gconf
+ echo " outfitsnoconfig = 1" >> $$gconf
+ echo " outfitsnodate = 1" >> $$gconf
+ echo " outfitsnoversions = 1" >> $$gconf
+
+# Final target.
echo "GNU Astronomy Utilities $(gnuastro-version) \citep{gnuastro}" > $@
$(ibidir)/icu-$(icu-version): $(ibidir)/python-$(python-version)
@@ -1248,7 +1304,7 @@ $(ibidir)/icu-$(icu-version): $(ibidir)/python-$(python-version)
tarball=icu-$(icu-version).tar.lz
$(call import-source, $(icu-url), $(icu-checksum))
cd $(ddir)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
unpackdir=icu-$(icu-version)
cd $$unpackdir
$(shsrcdir)/prep-source.sh $(ibdir)
@@ -1317,7 +1373,7 @@ $(ibidir)/imfit-$(imfit-version): \
cd $(ddir)
unpackdir=imfit-$(imfit-version)
rm -rf $$unpackdir
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd $$unpackdir
$(shsrcdir)/prep-source.sh $(ibdir)
sed -i 's|/usr/local|$(idir)|g' SConstruct
@@ -1365,7 +1421,8 @@ $(ibidir)/minizip-$(minizip-version): $(ibidir)/automake-$(automake-version)
unpackdir=minizip-$(minizip-version)
rm -rf $$unpackdir
mkdir $$unpackdir
- tar -xf $(tdir)/$$tarball -C$$unpackdir --strip-components=1
+ tar -xf $(tdir)/$$tarball -C$$unpackdir --strip-components=1 \
+ --no-same-owner --no-same-permissions
cd $$unpackdir
$(shsrcdir)/prep-source.sh $(ibdir)
./configure --prefix=$(idir)
@@ -1427,7 +1484,7 @@ $(ibidir)/netpbm-$(netpbm-version): \
cd $(ddir)
unpackdir=netpbm-$(netpbm-version)
rm -rf $$unpackdir
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd $$unpackdir
$(shsrcdir)/prep-source.sh $(ibdir)
@@ -1547,7 +1604,7 @@ $(ibidir)/scons-$(scons-version): $(ibidir)/python-$(python-version)
cd $(ddir)
unpackdir=scons-$(scons-version)
rm -rf $$unpackdir
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd $$unpackdir
$(shsrcdir)/prep-source.sh $(ibdir)
@@ -1593,7 +1650,7 @@ $(ibidir)/sextractor-$(sextractor-version): \
unpackdir=sextractor-$(sextractor-version)
cd $(ddir)
rm -rf $$unpackdir
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd $$unpackdir
# See comment above 'missfits' for '-fcommon'.
@@ -1694,7 +1751,7 @@ $(ibidir)/util-linux-$(util-linux-version): \
# explained above). As shown below, later, we'll put a symbolic link
# of all the necessary binaries in the main '$(idir)/bin'.
cd $(ddir)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd util-linux-$(util-linux-version)
$(shsrcdir)/prep-source.sh $(ibdir)
@@ -1713,8 +1770,15 @@ $(ibidir)/util-linux-$(util-linux-version): \
# manually by commenting the relevant files in the
# 'configure.ac'.
sed -e's|UL_BUILD_INIT(\[mkswap\], \[yes\])|UL_BUILD_INIT(\[mkswap\], \[no\])|' \
+ -e's|UL_BUILD_INIT(\[bits\], \[yes\])|UL_BUILD_INIT(\[bits\], \[no\])|' \
-i configure.ac
+# 'autogen.sh' checks for dependencies, but 'flex' (that is not built
+# in Maneage) is not needed when compiling from tarball (see:
+# https://github.com/util-linux/util-linux/pull/2531#issuecomment-1798020594)
+ sed -i '/flex/d' autogen.sh
+ ./autogen.sh
+
# Having updated 'configure.ac', we need to re-generate the
# './configure' script with 'autoreconf' (which is part of Autoconf
# and needs Automake; hence why they are dependencies.
@@ -1724,7 +1788,6 @@ $(ibidir)/util-linux-$(util-linux-version): \
export CONFIG_SHELL=$(ibdir)/bash
./configure --prefix=$(idircustom)/util-linux \
--disable-dependency-tracking \
- --enable-libmount-support-mtab \
--disable-silent-rules \
--disable-liblastlog2 \
--disable-mountpoint \
@@ -1799,10 +1862,11 @@ $(ibidir)/vim-$(vim-version):
tarball=vim-$(vim-version).tar.lz
$(call import-source, $(vim-url), $(vim-checksum))
cd $(ddir)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
unpackdir=vim-$(vim-version)
cd $(ddir)/$$unpackdir
$(shsrcdir)/prep-source.sh $(ibdir)
+ export CFLAGS="-std=gnu17 $$CFLAGS"
./configure --prefix=$(idir) \
--disable-canberra \
--enable-multibyte \
@@ -1869,7 +1933,8 @@ $(itidir)/texlive-ready-tlmgr: reproduce/software/config/texlive.conf
@topdir=$$(pwd)
cd $(ddir)
rm -rf install-tl-*
- tar -xf $(tdir)/install-tl-unx.tar.gz
+ tar -xf $(tdir)/install-tl-unx.tar.gz \
+ --no-same-owner --no-same-permissions
cd install-tl-*
$(shsrcdir)/prep-source.sh $(ibdir)
sed -e's|@installdir[@]|$(idir)|g' \
@@ -1956,7 +2021,8 @@ $(itidir)/texlive-ready-tlmgr: reproduce/software/config/texlive.conf
"$(backupservers)"; then
cd $(ddir)
rm -rf install-tl-*
- tar -xf $(tdir)/install-tl-unx.tar.gz
+ tar -xf $(tdir)/install-tl-unx.tar.gz \
+ --no-same-owner --no-same-permissions
cd install-tl-*
$(shsrcdir)/prep-source.sh $(ibdir)
sed -e's|@installdir[@]|$(idir)|g' \
@@ -2014,7 +2080,7 @@ $(itidir)/texlive: reproduce/software/config/texlive-packages.conf \
# We do not build TeXLive from source and for its installation it
# downloads components from the web internally; and those
# components can use '/bin/sh' (which needs 'sys_library_sh_path').
- export LD_LIBRARY_PATH="$(sys_library_sh_path):$$LD_LIBRARY_PATH"
+ export LD_LIBRARY_PATH="$(sys_library_sh_path)"
# To update itself, tlmgr needs a backup directory.
backupdir=$(idir)/texlive/backups
@@ -2043,7 +2109,6 @@ $(itidir)/texlive: reproduce/software/config/texlive-packages.conf \
# files (this is because we do no yet install LaTeX from source):
cdir=$$(pwd)
cd $(idir)/texlive
- $(shsrcdir)/prep-source.sh $(ibdir)
cd $$cdir
# Get all the necessary versions.
diff --git a/reproduce/software/make/python.mk b/reproduce/software/make/python.mk
index c017fd2..c499996 100644
--- a/reproduce/software/make/python.mk
+++ b/reproduce/software/make/python.mk
@@ -12,8 +12,8 @@
#
# ------------------------------------------------------------------------
#
-# Copyright (C) 2019-2025 Raul Infante-Sainz <infantesainz@gmail.com>
-# Copyright (C) 2019-2025 Mohammad Akhlaghi <mohammad@akhlaghi.org>
+# Copyright (C) 2019-2026 Raul Infante-Sainz <infantesainz@gmail.com>
+# Copyright (C) 2019-2026 Mohammad Akhlaghi <mohammad@akhlaghi.org>
#
# This Makefile is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -99,7 +99,7 @@ $(ibidir)/python-$(python-version): $(ibidir)/libffi-$(libffi-version)
# Unpack the tarball (see below for the necessary modification).
cd $(ddir)
unpackdir=python-$(python-version)
- tar -xf $(tdir)/$$tarball
+ tar -xf $(tdir)/$$tarball --no-same-owner --no-same-permissions
cd $$unpackdir
$(shsrcdir)/prep-source.sh $(ibdir)
@@ -215,7 +215,7 @@ pybuild = cd $(ddir); \
packagedir=$(strip $(2)); \
if (printf "$$packagedir" | grep "[a-z][a-z]"); then rm -rf $$packagedir; fi; \
printf "\nStarting to install python package with maneage pybuild rule: $(4)\n ..."; \
- if ! $(1) $(tdir)/$$tarball; then \
+ if ! $(1) $(tdir)/$$tarball --no-same-owner --no-same-permissions; then \
echo; echo "Tar error"; exit 1; \
fi; \
cd $$packagedir; \
diff --git a/reproduce/software/make/r-cran.mk b/reproduce/software/make/r-cran.mk
index 7c86c23..7a09915 100644
--- a/reproduce/software/make/r-cran.mk
+++ b/reproduce/software/make/r-cran.mk
@@ -12,8 +12,8 @@
#
# ------------------------------------------------------------------------
#
-# Copyright (C) 2022-2025 Boud Roukema <boud@cosmo.torun.pl>
-# Copyright (C) 2022-2025 Mohammad Akhlaghi <mohammad@akhlaghi.org>
+# Copyright (C) 2022-2026 Boud Roukema <boud@cosmo.torun.pl>
+# Copyright (C) 2022-2026 Mohammad Akhlaghi <mohammad@akhlaghi.org>
#
# This Makefile is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
diff --git a/reproduce/software/make/xorg.mk b/reproduce/software/make/xorg.mk
index 864c32a..db42d70 100644
--- a/reproduce/software/make/xorg.mk
+++ b/reproduce/software/make/xorg.mk
@@ -14,8 +14,8 @@
#
# ------------------------------------------------------------------------
#
-# Copyright (C) 2021-2025 Mohammad Akhlaghi <mohammad@akhlaghi.org>
-# Copyright (C) 2021-2025 Raul Infante-Sainz <infantesainz@gmail.com>
+# Copyright (C) 2021-2026 Mohammad Akhlaghi <mohammad@akhlaghi.org>
+# Copyright (C) 2021-2026 Raul Infante-Sainz <infantesainz@gmail.com>
#
# This Makefile is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by