diff options
Diffstat (limited to 'reproduce/software/make')
| -rw-r--r-- | reproduce/software/make/README.md | 2 | ||||
| -rw-r--r-- | reproduce/software/make/atlas-multiple.mk | 2 | ||||
| -rw-r--r-- | reproduce/software/make/atlas-single.mk | 2 | ||||
| -rw-r--r-- | reproduce/software/make/basic.mk | 32 | ||||
| -rw-r--r-- | reproduce/software/make/build-rules.mk | 2 | ||||
| -rw-r--r-- | reproduce/software/make/high-level.mk | 81 | ||||
| -rw-r--r-- | reproduce/software/make/python.mk | 4 | ||||
| -rw-r--r-- | reproduce/software/make/r-cran.mk | 4 | ||||
| -rw-r--r-- | reproduce/software/make/xorg.mk | 4 |
9 files changed, 93 insertions, 40 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 4b18c29..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 @@ -344,24 +344,22 @@ $(ibidir)/zlib-$(zlib-version): | $(ibdir) $(ildir) $(lockdir) 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)" > $@ @@ -540,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 @@ -565,7 +564,7 @@ $(ibidir)/bash-$(bash-version): \ if [ "x$(static_build)" = xyes ]; then stopt="--enable-static-link" else stopt="" fi; - export CFLAGS="$$CFLAGS -std=gnu17 \ + export CFLAGS="$$CFLAGS \ -DDEFAULT_PATH_VALUE='\"$(ibdir)\"' \ -DSTANDARD_UTILS_PATH='\"$(ibdir)\"' \ -DSYS_BASHRC='\"$(BASH_ENV)\"' " @@ -1065,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 @@ -1076,10 +1071,9 @@ $(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)) - export CFLAGS="-std=gnu17 $$CFLAGS" $(call gbuild, m4-$(m4-version), static, \ --with-syscmd-shell=$(ibdir)/dash, \ -j$(numthreads) V=1) diff --git a/reproduce/software/make/build-rules.mk b/reproduce/software/make/build-rules.mk index 463fbbf..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 diff --git a/reproduce/software/make/high-level.mk b/reproduce/software/make/high-level.mk index 67ca8b6..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 @@ -731,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): @@ -1186,6 +1187,14 @@ $(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. @@ -1193,13 +1202,13 @@ $(ibidir)/ghostscript-$(ghostscript-version): \ 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) @@ -1224,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) @@ -1718,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. @@ -1729,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 \ @@ -1808,6 +1866,7 @@ $(ibidir)/vim-$(vim-version): unpackdir=vim-$(vim-version) cd $(ddir)/$$unpackdir $(shsrcdir)/prep-source.sh $(ibdir) + export CFLAGS="-std=gnu17 $$CFLAGS" ./configure --prefix=$(idir) \ --disable-canberra \ --enable-multibyte \ diff --git a/reproduce/software/make/python.mk b/reproduce/software/make/python.mk index c994e3f..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 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 |
