From 3c9bf3aff30f02c7d31bd86f36c4db2520f8ffa4 Mon Sep 17 00:00:00 2001 From: Mohammad Akhlaghi <mohammad@akhlaghi.org> Date: Fri, 3 May 2024 13:07:41 +0200 Subject: Configuration: no dependency on /bin/sh and useful run-time options SUMMARY: no change necessary in your project, this commit only involves changes in how already-existing software are built. Some handy options have also been added to the top-level project script and the copyright years have been updated. Until now, if the host's '/bin/sh' had conflicts with the Maneage environment, the configuration of Maneage would crash as soon as we entered the building of high-level software. The full scenario is described in the comments of the newly added 'reproduce/software/shell/prep-source.sh'. This is most relevant when building older Maneage'd project in newer environments. With this commit, the following changes were made to avoid the problem above: - Maneage edits the source code of all installed software to replace '/bin/sh' with Maneage's own shell before the programs are built. Through this, we were able to solve the problem described above. - The portable '#!/usr/bin/env sh' shebangs are now used at the start of the scripts that run during configure time so it uses the first available shell that it finds in its PATH (the system's before Dash is built), then Dash, and after Dash is built, Bash. - For TeXLive, since we don't install it from source, it was necessary to add the libraries necessary for the local '/bin/sh' in LD_LIBRARY_PATH. Some high-level options have been added to the './project' script to simplify certain operations: --keep-going: do not stop upon the first crash, but keep going on to build targets until all build-able targets have been built. This is very useful for debugging large pipelines and allows you to isolate the problematic part of your project. --highlight-all: equivalent to calling both '--highlight-new' & '--highlight-notes'. --- reproduce/software/make/high-level.mk | 90 +++++++++++++++++++++++++++-------- 1 file changed, 71 insertions(+), 19 deletions(-) (limited to 'reproduce/software/make/high-level.mk') diff --git a/reproduce/software/make/high-level.mk b/reproduce/software/make/high-level.mk index 3f9c40c..2274c45 100644 --- a/reproduce/software/make/high-level.mk +++ b/reproduce/software/make/high-level.mk @@ -12,8 +12,8 @@ # # ------------------------------------------------------------------------ # -# Copyright (C) 2018-2023 Mohammad Akhlaghi <mohammad@akhlaghi.org> -# Copyright (C) 2019-2023 Raul Infante-Sainz <infantesainz@gmail.com> +# Copyright (C) 2018-2025 Mohammad Akhlaghi <mohammad@akhlaghi.org> +# Copyright (C) 2019-2025 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 @@ -64,6 +64,12 @@ ipydir = $(BDIR)/software/installed/version-info/python ircrandir = $(BDIR)/software/installed/version-info/r-cran ilibrcrandir = $(BDIR)/software/installed/lib/R/library +# Special files. +makewshell = $(ibdir)/make-with-shell + + + + # Targets to build. ifeq ($(strip $(all_highlevel)),1) @@ -232,7 +238,7 @@ $(idircustom):; mkdir $@ # Afer putting everything together, we use the first server as the # reference for all software if their '-url' variable isn't defined (in # 'reproduce/software/config/urls.conf'). -downloadwrapper = ./reproduce/analysis/bash/download-multi-try +downloadwrapper = ./reproduce/analysis/bash/download-multi-try.sh maneage_backup_urls := $(shell awk '!/^#/{printf "%s ", $$1}' \ reproduce/software/config/servers-backup.conf) backupservers_all = $(user_backup_urls) $(maneage_backup_urls) @@ -339,6 +345,7 @@ $(ibidir)/atlas-$(atlas-version): cd $(ddir) tar -xf $(tdir)/atlas-$(atlas-version).tar.lz cd ATLAS + $(shsrcdir)/prep-source.sh $(ibdir) rm -rf build mkdir build cd build @@ -395,6 +402,7 @@ $(ibidir)/boost-$(boost-version): \ cd $(ddir) tar -xf $(tdir)/$$tarball cd $$unpackdir + $(shsrcdir)/prep-source.sh $(ibdir) ./bootstrap.sh --prefix=$(idir) --with-libraries=all \ --with-python=python3 echo "using mpi ;" > project-config.jam @@ -417,9 +425,7 @@ $(ibidir)/cfitsio-$(cfitsio-version): topdir=$(pwd); cd $(ddir); tar -xf $(tdir)/$$tarball customtar=cfitsio-$(cfitsio-version)-custom.tar.gz cd cfitsio-$(cfitsio-version) - sed configure -e's|@rpath|$(ildir)|g' > configure_tmp - mv configure_tmp configure - chmod +x configure + sed -i -e's|@rpath|$(ildir)|g' configure cd .. tar cf $$customtar cfitsio-$(cfitsio-version) cd $$topdir @@ -518,6 +524,12 @@ $(ibidir)/fftw-$(fftw-version): echo "FFTW $(fftw-version) \citep{fftw}" > $@ $(ibidir)/freetype-$(freetype-version): $(ibidir)/libpng-$(libpng-version) +# As of version 2.13.2, FreeType doesn't account for the 'SHELL' +# environment variable. The issue has been reported to the +# developers. But until future versions, the work-around was +# discoverd to be setting the 'GNUMAKE' environment variable so it +# includes 'SHELL'. + export GNUMAKE="$(makewshell)" tarball=freetype-$(freetype-version).tar.lz $(call import-source, $(freetype-url), $(freetype-checksum)) $(call gbuild, freetype-$(freetype-version), static) @@ -578,7 +590,9 @@ $(ibidir)/healpix-$(healpix-version): $(healpix-python-dep) \ rm -rf $(ddir)/Healpix_$(healpix-version) topdir=$(pwd); cd $(ddir); tar -xf $(tdir)/$$tarball - cd Healpix_$(healpix-version)/src/C/autotools/ + cd Healpix_$(healpix-version) + $(shsrcdir)/prep-source.sh $(ibdir) + cd src/C/autotools autoreconf --install ./configure --prefix=$(idir) make V=1 -j$(numthreads) SHELL=$(ibdir)/bash @@ -670,6 +684,7 @@ $(ibidir)/libpaper-$(libpaper-version): \ tar -xf $(tdir)/$$tarball unpackdir=libpaper-$(libpaper-version) cd $$unpackdir + $(shsrcdir)/prep-source.sh $(ibdir) autoreconf -fi ./configure --prefix=$(idir) --sysconfdir=$(idir)/etc \ --disable-static @@ -799,6 +814,7 @@ $(ibidir)/openblas-$(openblas-version): cd $(ddir) tar -xf $(tdir)/$$tarball cd OpenBLAS-$(openblas-version) + $(shsrcdir)/prep-source.sh $(ibdir) make -j$(numthreads) make PREFIX=$(idir) install cd .. @@ -1007,6 +1023,7 @@ $(ibidir)/astrometrynet-$(astrometrynet-version): \ rm -rf astrometry.net-$(astrometrynet-version) tar -xf $(tdir)/$$tarball cd astrometry.net-$(astrometrynet-version) + $(shsrcdir)/prep-source.sh $(ibdir) sed -e 's|cat /proc/cpuinfo|echo "Ignoring CPU info"|' \ -e 's|-free|echo "Ignoring RAM info"|' Makefile > Makefile.tmp mv Makefile.tmp Makefile @@ -1045,6 +1062,7 @@ $(ibidir)/cdsclient-$(cdsclient-version): cd $(ddir) tar -xf $(tdir)/$$tarball cd cdsclient-$(cdsclient-version) + $(shsrcdir)/prep-source.sh $(ibdir) touch * ./configure --prefix=$(idir) make @@ -1061,25 +1079,29 @@ $(ibidir)/cmake-$(cmake-version): tarball=cmake-$(cmake-version).tar.lz $(call import-source, $(cmake-url), $(cmake-checksum)) -# After searching in 'bootstrap', I couldn't find 'LIBS', only -# 'LDFLAGS'. So the extra libraries are being added to 'LDFLAGS', not -# 'LIBS'. -# # On Mac systems, the build complains about 'clang' specific # features, so we can't use our own GCC build here. if [ x$(on_mac_os) = xyes ]; then export CC=clang export CXX=clang++ fi + +# CMake wants a single executable for 'MAKE', so we can't use 'make +# SHELL=$(SHELL) and we have defined this script. + export MAKE="$(makewshell)" + +# Go into the unpacked directory and build CMake. cd $(ddir) rm -rf cmake-$(cmake-version) tar -xf $(tdir)/$$tarball cd cmake-$(cmake-version) + $(shsrcdir)/prep-source.sh $(ibdir) ./bootstrap --prefix=$(idir) --system-curl --system-zlib \ --system-bzip2 --system-liblzma --no-qt-gui \ --parallel=$(numthreads) - make -j$(numthreads) LIBS="$$LIBS -lssl -lcrypto -lz" VERBOSE=1 - make install + $(makewshell) VERBOSE=1 LIBS="$$LIBS -lssl -lcrypto -lz" \ + -j$(numthreads) + $(makewshell) install cd .. rm -rf cmake-$(cmake-version) echo "CMake $(cmake-version)" > $@ @@ -1129,6 +1151,7 @@ $(ibidir)/ghostscript-$(ghostscript-version): \ cd $(ddir) tar -xf $(tdir)/$$tarball cd ghostscript-$(ghostscript-version) + $(shsrcdir)/prep-source.sh $(ibdir) ./configure --prefix=$(idir) \ --disable-cups \ --enable-dynamic \ @@ -1170,7 +1193,7 @@ $(ibidir)/gnuastro-$(gnuastro-version): \ $(call gbuild, gnuastro-$(gnuastro-version), static, , \ -j$(numthreads)) cp $(dtexdir)/gnuastro.tex $(ictdir)/ - echo "GNU Astronomy Utilities $(gnuastro-version) \citep{gnuastro,akhlaghi19}" > $@ + echo "GNU Astronomy Utilities $(gnuastro-version) \citep{gnuastro}" > $@ $(ibidir)/icu-$(icu-version): $(ibidir)/python-$(python-version) @@ -1188,7 +1211,9 @@ $(ibidir)/icu-$(icu-version): $(ibidir)/python-$(python-version) cd $(ddir) tar -xf $(tdir)/$$tarball unpackdir=icu-$(icu-version) - cd $$unpackdir/icu4c/source + cd $$unpackdir + $(shsrcdir)/prep-source.sh $(ibdir) + cd icu4c/source ./configure --enable-static --prefix=$(idir) make -j$(numthreads) V=1 make install @@ -1255,6 +1280,7 @@ $(ibidir)/imfit-$(imfit-version): \ rm -rf $$unpackdir tar -xf $(tdir)/$$tarball cd $$unpackdir + $(shsrcdir)/prep-source.sh $(ibdir) sed -i 's|/usr/local|$(idir)|g' SConstruct sed -i 's|/usr/include|$(idir)/include|g' SConstruct sed -i 's|.append(|.insert(0,|g' SConstruct @@ -1302,6 +1328,7 @@ $(ibidir)/minizip-$(minizip-version): $(ibidir)/automake-$(automake-version) mkdir $$unpackdir tar -xf $(tdir)/$$tarball -C$$unpackdir --strip-components=1 cd $$unpackdir + $(shsrcdir)/prep-source.sh $(ibdir) ./configure --prefix=$(idir) make cd contrib/minizip @@ -1363,6 +1390,7 @@ $(ibidir)/netpbm-$(netpbm-version): \ rm -rf $$unpackdir tar -xf $(tdir)/$$tarball cd $$unpackdir + $(shsrcdir)/prep-source.sh $(ibdir) # As of NetPBM 10.73.39 and Flex 2.6.4-410-74a89fd (commit 74a89fd in # Flex's Git that is 410 commits after version 2.6.4), there is the @@ -1482,6 +1510,7 @@ $(ibidir)/scons-$(scons-version): $(ibidir)/python-$(python-version) rm -rf $$unpackdir tar -xf $(tdir)/$$tarball cd $$unpackdir + $(shsrcdir)/prep-source.sh $(ibdir) # Unfortuantely SCons hard-codes its search PATH in its source (to # use POSIX operating system defaults)! So the only way to modify it @@ -1625,8 +1654,9 @@ $(ibidir)/util-linux-$(util-linux-version): | $(idircustom) cd $(ddir) tar -xf $(tdir)/$$tarball cd util-linux-$(util-linux-version) + $(shsrcdir)/prep-source.sh $(ibdir) -# If a patch exists for the current version, apply it. +# If a patch is necessary, apply it. if [ -f $(patchdir)/util-linux-$(util-linux-version)-macos.patch ]; then cp $(patchdir)/util-linux-$(util-linux-version)-macos.patch \ util-linux-$(util-linux-version)-macos.patch @@ -1727,6 +1757,7 @@ $(ibidir)/vim-$(vim-version): tar -xf $(tdir)/$$tarball unpackdir=vim-$(vim-version) cd $(ddir)/$$unpackdir + $(shsrcdir)/prep-source.sh $(ibdir) ./configure --prefix=$(idir) \ --disable-canberra \ --enable-multibyte \ @@ -1795,10 +1826,16 @@ $(itidir)/texlive-ready-tlmgr: reproduce/software/config/texlive.conf rm -rf install-tl-* tar -xf $(tdir)/install-tl-unx.tar.gz cd install-tl-* + $(shsrcdir)/prep-source.sh $(ibdir) sed -e's|@installdir[@]|$(idir)|g' \ "$$topdir"/reproduce/software/config/texlive.conf \ > texlive.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 will need '$(sys_library_sh_path)'). + export LD_LIBRARY_PATH="$(sys_library_sh_path):$$LD_LIBRARY_PATH" + # TeX Live's installation may fail due to any reason. But TeX Live is # optional (only necessary for building the final PDF). So we don't # want the configure script to fail if it can't run. Possible error @@ -1867,13 +1904,16 @@ $(itidir)/texlive-ready-tlmgr: reproduce/software/config/texlive.conf tarballurl=$$url/install-tl-unx.tar.gz touch $(lockdir)/download downloader="wget --no-use-server-timestamps -O" - if $(downloadwrapper) "$$downloader" $(lockdir)/download \ - $$tarballurl "$(tdir)/install-tl-unx.tar.gz" \ - "$(backupservers)"; then + if $(downloadwrapper) "$$downloader" \ + $(lockdir)/download \ + $$tarballurl \ + "$(tdir)/install-tl-unx.tar.gz" \ + "$(backupservers)"; then cd $(ddir) rm -rf install-tl-* tar -xf $(tdir)/install-tl-unx.tar.gz cd install-tl-* + $(shsrcdir)/prep-source.sh $(ibdir) sed -e's|@installdir[@]|$(idir)|g' \ $$topdir/reproduce/software/config/texlive.conf \ > texlive.conf @@ -1917,6 +1957,11 @@ $(itidir)/texlive: reproduce/software/config/texlive-packages.conf \ echo "" > $@ else +# 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" + # To update itself, tlmgr needs a backup directory. backupdir=$(idir)/texlive/backups mkdir -p $$backupdir @@ -1940,6 +1985,13 @@ $(itidir)/texlive: reproduce/software/config/texlive-packages.conf \ # directory so we don't have to modify 'PATH'. ln -fs $(idir)/texlive/maneage/bin/*/* $(ibdir)/ +# Correct any reference to '/bin/sh' within the installed LaTeX +# 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. texlive=$$(pdflatex --version \ | awk 'NR==1' \ -- cgit v1.2.1 From 890858795fd6e0c8c1f3050adec7f4bc78e9e47c Mon Sep 17 00:00:00 2001 From: Giacomo Lorenzetti <glorenzetti@cefca.es> Date: Tue, 21 Jan 2025 18:57:10 +0100 Subject: IMPORTANT: 73 software upgrades and added offline mode Summary: This is a software update to make Maneage more portable and up to date. It does not involve any Maneage infrastructure changes. You should just re-build your project to make sure the updated software haven't removed/changed any of their features that you were using. Until now, the software in Maneage had not been updated for almost 2.5 years (since August 2022) and were starting to get dated! Also, when no internet is available (for example in a HPC), the Zenodo check would always cause a crash and needed to be commented manually. With this commit, all the basic software that had been updated as well as the dependencies of Gnuastro (which we commit to maintaining) have been updated after a check of their webpage (see the full list below). To fix the offline issue, a new '--offline' option has been added to the project script. The other following changes were made: - tarball-prepare: has become more resilient (for dealing with file name with spaces or Lzip, which should not be compressed). - Readme: improve documentation when used in Docker. Below you can see the list of basic software that have been updated. The only basic software that have not been updated upstream since the previous Maneage software update are 'bison', 'flock', 'm4', 'pkgconfig', 'unzip' and 'zip'. bash 5.2-rc2 5.2.37 binutils 2.39 2.43.1 coreutils 9.1 9.6 curl 7.84.0 8.11.1 dash 0.5.11-057cd65 0.5.12 diffutils 3.8 3.10 file 5.42 5.46 findutils 4.9.0 4.10.0 gawk 5.1.1 5.3.1 gcc 12.1.0 14.2.0 gettext 0.21 0.23.1 git 2.37.1 2.48.1 gmp 6.2.1 6.3.0 grep 3.7 3.11 gzip 1.12 1.13 help2man 1.49.2 1.49.3 isl 0.24 0.27 less 590 668 libiconv 1.17 1.18 libtool 2.4.7 2.5.4 libunistring 1.0 1.3 libxml2 2.9.12 2.13.5 lzip 1.23 1.25 make 4.3 4.4.1 mpc 1.2.1 1.3.1 mpfr 4.1.0 4.2.1 nano 6.4 8.3 ncurses 6.3 6.5 openssl 3.0.5 3.4.0 perl 5.36.0 5.40.1 podlators 4.14 6.0.2 readline 8.2-rc2 8.2.13 sed 4.8 4.9 tar 1.34 1.35 texinfo 6.8 7.2 wget 1.21.2 1.25.0 which 2.21 2.23 xz 5.2.5 5.6.3 zlib 1.2.11 1.3.1 The high-level software that have been updated. autoconf 2.71 2.72 automake 1.16.5 1.17 cfitsio 4.1.0 4.5.0 cmake 3.24.0 3.31.5 expat 2.4.1 2.6.4 fontconfig 2.14.0 2.16.0 freetype 2.11.0 2.13.3 ghostscript 9.56.1 10.04.0 gnuastro 0.18 0.23 gsl 2.7 2.8 libffi 3.4.2 3.4.7 libgit2 1.3.0 1.9.0 libice 1.0.10 1.1.2 libidn 1.38 1.42 libjpeg 9e 9f libpaper 1.1.28 1.1.29 libpng 1.6.37 1.6.46 libpthread-stubs 0.4 0.5 libsm 1.2.3 1.2.5 libtiff 4.4.0 4.7.0 libxau 1.0.9 1.0.12 libxcb 1.15 1.17 libxdmcp 1.1.3 1.1.5 libxext 1.3.4 1.3.6 libxt 1.2.1 1.3.1 python 3.10.6 3.13.12 util-macros 1.19.3 1.20.2 wcslib 7.11 8.4 xcb-proto 1.15 1.17 xorgproto 2022.1 2024.1 xtrans 1.4.0 1.5.2 --- reproduce/software/make/high-level.mk | 46 +++++++++++++++++++++++------------ 1 file changed, 31 insertions(+), 15 deletions(-) (limited to 'reproduce/software/make/high-level.mk') diff --git a/reproduce/software/make/high-level.mk b/reproduce/software/make/high-level.mk index 2274c45..fdab193 100644 --- a/reproduce/software/make/high-level.mk +++ b/reproduce/software/make/high-level.mk @@ -118,11 +118,16 @@ else endif +# Disable the TeXLive target if `--offline` +ifneq ($(strip $(offline)),1) + target-texlive := $(itidir)/texlive +endif + # Ultimate Makefile target. all: $(foreach p, $(targets-proglib), $(ibidir)/$(p)) \ $(foreach p, $(targets-python), $(ipydir)/$(p)) \ $(foreach p, $(targets-r-cran), $(ircrandir)/$(p)) \ - $(itidir)/texlive + $(target-texlive) # Define the shell environment # ---------------------------- @@ -433,11 +438,14 @@ $(ibidir)/cfitsio-$(cfitsio-version): # Continue the standard build on the customized tarball. Note that # with the installation of CFITSIO, 'fpack' and 'funpack' are not # installed by default. Because of that, they are added explicity. +# +# Note that older versions of CFITSIO (before 4.4.0) require a +# specific 'shared' target for the building of the shared libraries. export gbuild_tar=$(ddir)/$$customtar $(call gbuild, cfitsio-$(cfitsio-version), , \ --enable-sse2 --enable-reentrant \ --with-bzip2=$(idir), , \ - make shared fpack funpack) + make fpack funpack) rm $$customtar echo "CFITSIO $(cfitsio-version)" > $@ @@ -921,8 +929,8 @@ $(ibidir)/libgit2-$(libgit2-version): $(ibidir)/cmake-$(cmake-version) -DUSE_SSH=OFF -DBUILD_CLAR=OFF \ -DTHREADSAFE=ON -DUSE_ICONV=OFF ) if [ x$(on_mac_os) = xyes ]; then - install_name_tool -id $(ildir)/libgit2.1.3.dylib \ - $(ildir)/libgit2.1.3.dylib + install_name_tool -id $(ildir)/libgit2.1.9.dylib \ + $(ildir)/libgit2.1.9.dylib fi echo "Libgit2 $(libgit2-version)" > $@ @@ -1156,7 +1164,9 @@ $(ibidir)/ghostscript-$(ghostscript-version): \ --disable-cups \ --enable-dynamic \ --disable-compile-inits \ - CFLAGS="-DPNG_ARM_NEON_OPT=0" + --disable-hidden-visibility \ + CFLAGS="-DPNG_ARM_NEON_OPT=0" \ + LDFLAGS=-Wl,--copy-dt-needed-entries # Build and install the program and the shared libraries. make V=1 -j$(numthreads) @@ -1642,7 +1652,10 @@ $(ibidir)/swig-$(swig-version): # '$(ibdir)'. If any program does need 'util-linux' libraries, they can # simply add the proper directories to the environment variables, see # 'fontconfig' for example. -$(ibidir)/util-linux-$(util-linux-version): | $(idircustom) +$(ibidir)/util-linux-$(util-linux-version): \ + $(ibidir)/autoconf-$(autoconf-version) \ + $(ibidir)/automake-$(automake-version) \ + | $(idircustom) # Import the source. tarball=util-linux-$(util-linux-version).tar.lz @@ -1663,18 +1676,20 @@ $(ibidir)/util-linux-$(util-linux-version): | $(idircustom) git apply util-linux-$(util-linux-version)-macos.patch fi -# The 'mkswap' feature needs low-level file system and kernel headers -# that are not always available (in particular on older Linux -# kernels). Also, creating SWAP space will need root permissions, so -# its not something a Maneager may need! Unfortunately there is no -# configuration option to disable this so we'll have to disable it -# manually by commenting the relevant files in the -# 'configure.ac'. Having a more recent 'configure.ac' will trigger -# the './configure' script to be re-created after the first run, but -# it is pretty fast and not a problem. +# The 'mkswap' feature needs low-level file system and kernel headers +# that are not always available (in particular on older Linux +# kernels). Also, creating SWAP space will need root permissions, so +# its not something a Maneager may need! Unfortunately there is no +# configuration option to disable this so we'll have to disable it +# manually by commenting the relevant files in the +# 'configure.ac'. sed -e's|UL_BUILD_INIT(\[mkswap\], \[yes\])|UL_BUILD_INIT(\[mkswap\], \[no\])|' \ -i configure.ac +# 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. + autoreconf -f # Configure Util-linux export CONFIG_SHELL=$(ibdir)/bash @@ -1682,6 +1697,7 @@ $(ibidir)/util-linux-$(util-linux-version): | $(idircustom) --disable-dependency-tracking \ --enable-libmount-support-mtab \ --disable-silent-rules \ + --disable-liblastlog2 \ --disable-mountpoint \ --disable-libmount \ --disable-unshare \ -- cgit v1.2.1 From a55a407c1f2a1b280be78f24abd1fe6d4a8032e2 Mon Sep 17 00:00:00 2001 From: Mohammad Akhlaghi <mohammad@akhlaghi.org> Date: Thu, 13 Feb 2025 19:27:57 +0100 Subject: Configuration: new server for tarballs and portability fixed SUMMARY: no change is necessary for your pipeline after upgrading to this commit. Until this commit, the following noteworthy portability problems existed that have been fixed as described in each item. - In commit 8908587 (titled "IMPORTANT: 73 software upgrades and added offline mode"; committed on 2025-02-11); the versions of all (except those that were not updated upstream) basic software as well as the high-level software necessary for Gnuastro were updated. This included Python. However, the update of Python could cause crashes in the Python-related software that are also in Maneage but not tested for that commit. -- With this commit, Python has been revered back to 3.10.6 (from 3.13.2) and it has been taken to a dedicated part of 'versions.conf' (reminding the reader that the version of Python should only be updated by the Python maintainer: to ensure it doesn't conflict with Python-based builds). - Following the update of XZ Utils in 8908587, the custom build recipe that was necessary is no longer necessary. This was reported by Boud Roukema (see https://savannah.nongnu.org/bugs/index.php?62700). -- With this commit, XZ Utils uses our basic high-level build scripts. - CMake could use out-of-Maneage libraries for those that we already had in Maneage on some systems. This was reported by Boud Roukema (see https://savannah.nongnu.org/bugs/?63043) -- With this commit, CMake is built with '--no-system-libs'; so it builds and statically links to all its necessary libraries internally (not confusing between Maneage and the host). - Building Binutils 2.39 was likely to fail on older GCC versions due to special features (such as the 'gprofng' feature when building with GCC 6.2.0). This was reported by Boud Roukema in https://savannah.nongnu.org/bugs/index.php?63242. -- With this commit, the 'gprofng' feature of Binutils has been disabled by default to allow reproducibility on older systems. If you need it, remove the '--enable-gprofng=no' option in the build recipe of Binutils. - The Maneage tarball repository is now also kept in 'gitlab.cefca.es'. -- With this commit, a new server URL has been added for this. - The list of TeXLive packages included some packages that get installed in the basic scheme that we do for the initial setup of TeXLive. -- With this commit, the extra packages have been removed. --- reproduce/software/make/high-level.mk | 33 ++++++++++++++++++++++++++------- 1 file changed, 26 insertions(+), 7 deletions(-) (limited to 'reproduce/software/make/high-level.mk') diff --git a/reproduce/software/make/high-level.mk b/reproduce/software/make/high-level.mk index fdab193..928d0a2 100644 --- a/reproduce/software/make/high-level.mk +++ b/reproduce/software/make/high-level.mk @@ -1098,18 +1098,28 @@ $(ibidir)/cmake-$(cmake-version): # SHELL=$(SHELL) and we have defined this script. export MAKE="$(makewshell)" -# Go into the unpacked directory and build CMake. +# Go into the unpacked directory and prepare CMake. cd $(ddir) rm -rf cmake-$(cmake-version) tar -xf $(tdir)/$$tarball cd cmake-$(cmake-version) $(shsrcdir)/prep-source.sh $(ibdir) - ./bootstrap --prefix=$(idir) --system-curl --system-zlib \ - --system-bzip2 --system-liblzma --no-qt-gui \ + +# Bootstrap, build and install CMake: +# - With the '--no-system-libs' option, CMake builds and statically +# links all the libraries it needs. Even though some of those (like +# liblzma, libcurl, zlib or bzip2) are within Maneage, we +# discovered that CMake can get confused and use out-of-Maneage +# libraries (https://savannah.nongnu.org/bugs/?63043). + ./bootstrap --no-qt-gui \ + --prefix=$(idir) \ + --no-system-libs \ --parallel=$(numthreads) $(makewshell) VERBOSE=1 LIBS="$$LIBS -lssl -lcrypto -lz" \ -j$(numthreads) $(makewshell) install + +# Clean up. cd .. rm -rf cmake-$(cmake-version) echo "CMake $(cmake-version)" > $@ @@ -1960,10 +1970,19 @@ $(itidir)/texlive-ready-tlmgr: reproduce/software/config/texlive.conf # Live itself (only very basic TeX and LaTeX) and the installation of its # necessary packages into two packages. # -# Note that Biber needs to link with libraries like libnsl. However, we -# don't currently build biber from source. So we can't choose the library -# version. But we have the source and build instructions for the 'nsl' -# library. When we later build biber from source, we can easily use them. +# Note that we do not build the TeXLive executables (like Biber) from +# source. So in case they need special libraries, we can't choose the +# library version here (for example see [1] and [2]). In such cases there +# is no solution but to manually add the location necessary library to +# LD_LIBRARY_PATH when calling the respective LaTeX command in +# 'reproduce/analysis/make/paper.mk'. Fortunately as of Biber 2.20, it does +# not depend on anything except the C library (all dependencies are now +# statically linked), so problems [1] and [2] will not happen. But this can +# generally happen for any other tool/OS, so it is important to build +# TeXLive from source as soon as possible [3]. +# [1] https://github.com/plk/biber/issues/445 +# [2] https://savannah.nongnu.org/bugs/index.php?63175 +# [3] https://savannah.nongnu.org/task/?15267 $(itidir)/texlive: reproduce/software/config/texlive-packages.conf \ $(itidir)/texlive-ready-tlmgr -- cgit v1.2.1