diff options
author | Boud Roukema <boud@cosmo.torun.pl> | 2020-04-26 16:20:37 +0200 |
---|---|---|
committer | Mohammad Akhlaghi <mohammad@akhlaghi.org> | 2020-04-27 00:22:20 +0100 |
commit | a21ea20c54628989b9737e9aa2ecd72806456307 (patch) | |
tree | a31ccdce097ec4eb80fd885ff7163fa982a87800 /reproduce/software/make/basic.mk | |
parent | 3409a54c74e522ebac48546c2c5347dea6aeee16 (diff) |
Configuration: improved version separation from tarball name
Until now, the sed script for determining URL download rules in the three
software building Makefiles (`basic.mk', `high-level.mk' and `python.mk')
considered package names such as `fftw-3...` and `fftw2-2.1...` to be
identical. As the example above shows, this would make it hard to include
some software that may hav conflicting non-number names.
With this commit, the SED script that is used to separate the version from
the tarball name only matches numbers that are after a dash
(`-'). Therefore considers `fftw-3...` and `fftw-2...` to be identical, but
`fftw-3-...` and `fftw2-2.1...` to be different. As a result of this
change, the `elif' check for some of the other programs like `m4', or
`help2man' was also corrected in all three Makefiles.
While doing this check on all the software, we noticed that `zlib-version'
is being repeated two times in `version.conf' so it was removed. It caused
no complications, because both were the same number, but could lead to bugs
later.
Diffstat (limited to 'reproduce/software/make/basic.mk')
-rw-r--r-- | reproduce/software/make/basic.mk | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/reproduce/software/make/basic.mk b/reproduce/software/make/basic.mk index 138e07e..ebcd9b1 100644 --- a/reproduce/software/make/basic.mk +++ b/reproduce/software/make/basic.mk @@ -156,14 +156,18 @@ tarballs = $(foreach t, bash-$(bash-version).tar.lz \ , $(tdir)/$(t) ) $(tarballs): $(tdir)/%: | $(lockdir) - n=$$(echo $* | sed -e's/[0-9\-]/ /g' \ - -e's/\./ /g' \ + # Remove the version numbers and suffix from the tarball name so we + # can search more easily only with the program name. This requires + # the first character of the version to be a digit: packages such + # as `foo' and `foo-3' will not be distinguished, but `foo' and + # `foo2' will be distinguished. + n=$$(echo $* | sed -e's/-[0-9]/ /' -e's/\./ /g' \ | awk '{print $$1}' ); \ \ mergenames=1; \ if [ $$n = bash ]; then c=$(bash-checksum); w=http://akhlaghi.org/maneage-software; \ elif [ $$n = binutils ]; then c=$(binutils-checksum); w=http://ftp.gnu.org/gnu/binutils; \ - elif [ $$n = bzip ]; then c=$(bzip2-checksum); w=http://akhlaghi.org/maneage-software; \ + elif [ $$n = bzip2 ]; then c=$(bzip2-checksum); w=http://akhlaghi.org/maneage-software; \ elif [ $$n = cert ]; then c=$(cert-checksum); w=http://akhlaghi.org/maneage-software; \ elif [ $$n = coreutils ]; then c=$(coreutils-checksum); w=http://ftp.gnu.org/gnu/coreutils;\ elif [ $$n = curl ]; then c=$(curl-checksum); w=https://curl.haxx.se/download; \ @@ -181,7 +185,7 @@ $(tarballs): $(tdir)/%: | $(lockdir) elif [ $$n = libiconv ]; then c=$(libiconv-checksum); w=https://ftp.gnu.org/pub/gnu/libiconv; \ elif [ $$n = libtool ]; then c=$(libtool-checksum); w=http://ftp.gnu.org/gnu/libtool; \ elif [ $$n = lzip ]; then c=$(lzip-checksum); w=http://download.savannah.gnu.org/releases/lzip; \ - elif [ $$n = m ]; then \ + elif [ $$n = m4 ]; then \ mergenames=0; \ c=$(m4-checksum); \ w=http://akhlaghi.org/maneage-software/m4-1.4.18-patched.tar.gz; \ |