aboutsummaryrefslogtreecommitdiff
path: root/reproduce/software
diff options
context:
space:
mode:
Diffstat (limited to 'reproduce/software')
-rw-r--r--reproduce/software/config/installation/checksums.conf2
-rw-r--r--reproduce/software/config/installation/versions.conf5
-rw-r--r--reproduce/software/make/high-level.mk77
3 files changed, 67 insertions, 17 deletions
diff --git a/reproduce/software/config/installation/checksums.conf b/reproduce/software/config/installation/checksums.conf
index 950880b..7531749 100644
--- a/reproduce/software/config/installation/checksums.conf
+++ b/reproduce/software/config/installation/checksums.conf
@@ -110,7 +110,6 @@ libpng-checksum = 59e8c1059013497ae616a14c3abbe239322d3873c6ded0912403fc62fb2605
libtiff-checksum = d213e5db09fd56b8977b187c5a756f60d6e3e998be172550c2892dbdb4b2a8e8c750202bc863fe27d0d1c577ab9de1710d15e9f6ed665aadbfd857525a81eea8
libtirpc-checksum = 392f391f9fc1bd68d81dc44e4058831a64b32790b5c8c37338b0ab416fad2ae4d16389e632596734dba09780347918cc65c6f134e0c1afd09e81ec250785ed23
libxml2-checksum = cb7784ba4e72e942614e12e4f83f4ceb275f3d738b30e3b5c1f25edf8e9fa6789e854685974eed95b362049dbf6c8e7357e0327d64c681ed390534ac154e6810
-minizip-checksum = 56b5443f79d1a0a5f563a563f7b1c27b0b0fc5ba5b37248367b204a89a9373df7d12ea802c678f3f39c987d5f1766003eac3dd31b643773afa4463a3f6406628
missfits-checksum = 32727f5eb30573a1cedacb8900e2536867e4815059eee32e64e3db65be9291b8a91b9f45b2c9f3cf6fc2a8cc448012ea3d502bdd9dee516008e17d5086aee795
netpbm-checksum = 064720f8a9d0a502488e1af4daecdbf3936910996507ca6f311073a0ad842346692a148eb1ddf7b717f7b108f60500246cb4b83f4d3665f5fc285a84ae1d63d6
openblas-checksum = 91b3074eb922453bf843158b4281cde65db9e8bbdd7590e75e9e6cdcb486157f7973f2936f327bb3eb4f1702ce0ba51ae6729d8d4baf2d986c50771e8f696df0
@@ -129,6 +128,7 @@ tides-checksum = c3360ff0d023b43749ba09a33302ca059f017a157b3ce7cdcf4f1a1578e90d3
wcslib-checksum = fed47771defb2a93fb50aa2e701c46f8ce35773dd3de91eeaed311b5a0474c096c7f9be6996fe95f82faa30b1d5c0aba892bca5da80bc32b15919dfaf551aeb7
xlsxio-checksum = 22870fda7bd4eefd5fea2a9ad7530c9049135129d9b69805091777e6b54b2fc6c3f0e69c6954f36bce54eebbfeccaf637cce9e271a593221a4296d6632470a6c
yaml-checksum = 13d2197135946204323dbfccafa0ac7b3d05437e920545a56f46811fd7319c01419a58083090ce85fccd4d6901a620ceb9f1190078cc0830bc0ce769bb024f51
+zlib-checksum = 73fd3fff4adeccd4894084c15ddac89890cd10ef105dd5e1835e1e9bbb6a49ff229713bd197d203edfa17c2727700fce65a2a235f07568212d820dca88b528ae
diff --git a/reproduce/software/config/installation/versions.conf b/reproduce/software/config/installation/versions.conf
index 592d931..39642d4 100644
--- a/reproduce/software/config/installation/versions.conf
+++ b/reproduce/software/config/installation/versions.conf
@@ -107,7 +107,6 @@ libpng-version = 1.6.37
libtiff-version = 4.0.10
libtirpc-version = 1.1.4
libxml2-version = 2.9.9
-minizip-version = 2.9.2
missfits-version = 2.8.0
openblas-version = 0.3.5
openmpi-version = 4.0.1
@@ -216,3 +215,7 @@ lapack-version = 3.8.0
libgit2-version = 0.28.2
netpbm-version = 10.86.99
wcslib-version = 6.4
+
+# Minizip is installed as a part of `zlib', and they have the same version.
+zlib-version = 1.2.11
+minizip-version = $(zlib-version)
diff --git a/reproduce/software/make/high-level.mk b/reproduce/software/make/high-level.mk
index 274bcdf..43dfaa1 100644
--- a/reproduce/software/make/high-level.mk
+++ b/reproduce/software/make/high-level.mk
@@ -184,7 +184,6 @@ tarballs = $(foreach t, apachelog4cxx-$(apachelog4cxx-version).tar.lz \
libpng-$(libpng-version).tar.xz \
libtirpc-$(libtirpc-version).tar.bz2 \
libxml2-$(libxml2-version).tar.gz \
- minizip-$(minizip-version).tar.gz \
missfits-$(missfits-version).tar.gz \
netpbm-$(netpbm-version).tar.gz \
openblas-$(openblas-version).tar.gz \
@@ -203,6 +202,7 @@ tarballs = $(foreach t, apachelog4cxx-$(apachelog4cxx-version).tar.lz \
wcslib-$(wcslib-version).tar.bz2 \
xlsxio-$(xlsxio-version).tar.gz \
yaml-$(yaml-version).tar.gz \
+ zlib-$(zlib-version).tar.gz \
, $(tdir)/$(t) )
$(tarballs): $(tdir)/%: | $(lockdir)
@@ -282,10 +282,6 @@ $(tarballs): $(tdir)/%: | $(lockdir)
w=https://github.com/libgit2/libgit2/archive/v$(libgit2-version).tar.gz
elif [ $$n = libtirpc ]; then c=$(libtirpc-checksum); w=https://downloads.sourceforge.net/libtirpc
elif [ $$n = libxml ]; then c=$(libxml2-checksum); w=ftp://xmlsoft.org/libxml2
- elif [ $$n = minizip ]; then
- mergenames=0
- c=$(minizip-checksum);
- w=https://github.com/nmoinvaz/minizip/archive/$(minizip-version).tar.gz
elif [ $$n = missfits ]; then c=$(missfits-checksum); w=https://www.astromatic.net/download/missfits
elif [ $$n = netpbm ]; then c=$(netpbm-checksum); w=http://akhlaghi.org/reproduce-software
elif [ $$n = openblas ]; then
@@ -319,6 +315,7 @@ $(tarballs): $(tdir)/%: | $(lockdir)
c=$(xlsxio-checksum);
w=https://github.com/brechtsanders/xlsxio/archive/$(xlsxio-version).tar.gz
elif [ $$n = yaml ]; then c=$(yaml-checksum); w=pyyaml.org/download/libyaml
+ elif [ $$n = zlib ]; then c=$(zlib-checksum); w=https://zlib.net
else
echo; echo; echo;
echo "'$$n' not recognized as a software tarball name to download."
@@ -927,8 +924,8 @@ $(ibidir)/ghostscript: $(ibidir)/libpng \
# First we need to make sure some necessary X11 libraries that we
# don't yet install in this template are present on the host
# system, see https://savannah.nongnu.org/task/?15481 .
- # Adding `-L/opt/X11/lib' to LDFLAGS is necessary for macOS systems
- # because X11 libraries used to be installed there.
+ # Adding `-L/opt/X11/lib' to LDFLAGS is necessary for macOS systems
+ # because X11 libraries used to be installed there.
echo;
echo "Template: testing necessary X11 libraries for ghostscript"
echo "---------------------------------------------------------"
@@ -1036,10 +1033,43 @@ $(ibidir)/imfit: $(ibidir)/gsl \
fi \
&& echo "Imfit $(imfit-version) \citep{imfit2015}" > $@
-$(ibidir)/minizip: $(ibidir)/cmake \
- | $(tdir)/minizip-$(minizip-version).tar.gz
- $(call cbuild, minizip-$(minizip-version), static) \
- && echo "minizip $(minizip-version)" > $@
+# Minizip 1.x is actually distributed within zlib. It doesn't have its own
+# independent tarball. So we need a custom build, which include the GNU
+# Autotools (Autoconf and Automake). Note that Minizip 2.x isn't like this
+# any more and has its own independent tarball, but currently the programs
+# that depend on Minizip need Minizip 1.x. The instructions to build
+# minizip were taken from ArchLinux.
+#
+# About deleting the final crypt.h file after installation, see
+# https://bugzilla.redhat.com/show_bug.cgi?id=1424609
+$(ibidir)/minizip: $(ibidir)/automake \
+ | $(tdir)/zlib-$(zlib-version).tar.gz
+ cd $(ddir) \
+ && unpackdir=minizip-$(minizip-version) \
+ && rm -rf $$unpackdir \
+ && mkdir $$unpackdir \
+ && if ! tar xf $(word 1,$(filter $(tdir)/%,$|)) \
+ -C$$unpackdir --strip-components=1; then \
+ echo; echo "Tar error"; exit 1; \
+ fi \
+ && cd $$unpackdir\
+ && ./configure --prefix=$(idir) \
+ && make \
+ && cd contrib/minizip \
+ && cp Makefile Makefile.orig \
+ && cp ../README.contrib readme.txt \
+ && autoreconf --install \
+ && ./configure --prefix=$(idir) \
+ && make \
+ && cd ../../ \
+ && make test \
+ && cd contrib/minizip \
+ && make -f Makefile.orig test \
+ && make install \
+ && rm $(iidir)/minizip/crypt.h \
+ && cd ../../.. \
+ && rm -rf $$unpackdir \
+ && echo "Minizip $(minizip)" > $@
$(ibidir)/missfits: | $(tdir)/missfits-$(missfits-version).tar.gz
$(call gbuild, missfits-$(missfits-version), static) \
@@ -1152,11 +1182,29 @@ $(ibidir)/swig: | $(tdir)/swig-$(swig-version).tar.gz
$(call gbuild, swig-$(swig-version), static, --without-pcre) \
&& echo "Swig $(swig-version)" > $@
-$(ibidir)/xlsxio: $(ibidir)/expat \
+$(ibidir)/xlsxio: $(ibidir)/cmake \
+ $(ibidir)/expat \
$(ibidir)/minizip \
| $(tdir)/xlsxio-$(xlsxio-version).tar.gz
- export LDFLAGS="-lbz2 -lbsd"; \
- $(call cbuild, xlsxio-$(xlsxio-version), static) \
+ if [ x$(on_mac_os) = xyes ]; then \
+ export CC=clang; \
+ export CXX=clang++; \
+ export LDFLAGS="-lbz2"; \
+ else \
+ export LDFLAGS="-lbz2 -lbsd"; \
+ fi; \
+ $(call cbuild, xlsxio-$(xlsxio-version), static, \
+ -DMINIZIP_DIR:PATH=$(idir) \
+ -DMINIZIP_LIBRARIES=$(idir) \
+ -DMINIZIP_INCLUDE_DIRS=$(iidir)) \
+ && if [ "x$(on_mac_os)" != xyes ]; then \
+ echo "Adding RPATH to the XLSX I/O executables..."; \
+ for f in $(ibdir)/xlsxio_* $(ildir)/libxlsxio_*.so; do \
+ patchelf --set-rpath $(ildir) $$f; \
+ done; \
+ fi \
+ && echo "Deleting XLSX I/O example files..." \
+ && rm $(ibdir)/example_xlsxio_* \
&& echo "XLSX I/O $(xlsxio-version)" > $@
@@ -1166,7 +1214,6 @@ $(ibidir)/xlsxio: $(ibidir)/expat \
-
# Since we want to avoid complicating the PATH, we are putting a symbolic
# link of all the TeX Live executables in $(ibdir). But symbolic links are
# hard to track for Make (as a target). Also, TeX in general is optional