From b66e0183982574a6429e4a9c023d10a5e2bea151 Mon Sep 17 00:00:00 2001 From: Lucio Andrés Illanes Albornoz (arab, vxp) Date: Sep 10 2016 13:16:55 +0000 Subject: Adds msgfmt and Perl {autodie,ExtUtils::MakeMaker} prerequisite dependencies. --- diff --git a/build.sh b/build.sh index 1b4e2b2..b59834f 100755 --- a/build.sh +++ b/build.sh @@ -56,6 +56,7 @@ done; # Check whether the pathnames in build.vars contain non-empty valid values. # Check whether all prerequisite command names resolve. # Check whether all prerequisite pathnames resolve. +# Check whether all prerequisite Perl modules exist. for __ in $(export | sed -e 's/^export //' -e 's/=.*$//'); do if ! match_list "${CLEAR_ENV_VARS_EXCEPT}" " " "${__}"; then unset "${__}"; @@ -81,6 +82,12 @@ for __ in ${CHECK_PREREQ_CMDS} ${CHECK_PREREQ_FILES}; do fi; fi; done; +for __ in ${CHECK_PREREQ_PERL_MODULES}; do + if ! perl -M"${__}" -e "" 2>/dev/null; then + log_msg fail "Error: missing prerequisite Perl module \`${__}'."; + __exit=1; + fi; +done; if [ ${__exit:-0} = 1 ]; then exit 1; elif [ -n "${__exit}" ]; then diff --git a/build.vars b/build.vars index 8520994..582780e 100644 --- a/build.vars +++ b/build.vars @@ -41,8 +41,9 @@ export PATH="${PREFIX}/bin${PATH:+:${PATH}}"; : ${BUILD_LOG_FNAME:=${PREFIX}/build.log}; : ${BUILD_LOG_LAST_FNAME:=${PREFIX}/build.log.last}; : ${BUILD_STATUS_IN_PROGRESS_FNAME:=${PREFIX}/BUILD_IN_PROGRESS}; -: ${CHECK_PREREQ_CMDS:="aclocal autoconf autopoint awk basename bunzip2 find flex git groff gunzip install libtool lzma make makeinfo nl nroff openssl patch sed sha256sum sort tar tee tr uname wget xz"}; +: ${CHECK_PREREQ_CMDS:="aclocal autoconf autopoint awk basename bunzip2 find flex git groff gunzip install libtool lzma make makeinfo msgfmt nl nroff openssl patch sed sha256sum sort tar tee tr uname wget xz"}; : ${CHECK_PREREQ_FILES:="/usr/include/gmpxx.h /usr/include/mpc.h /usr/include/mpfr.h"}; +: ${CHECK_PREREQ_PERL_MODULES:="autodie ExtUtils::MakeMaker"}; : ${CHECK_PATH_VARS:="PREFIX PREFIX_NATIVE PREFIX_CROSS DLCACHEDIR WORKDIR"}; : ${CLEAR_ENV_VARS_EXCEPT:="ARG_TARBALL ARG_VERBOSE HOME PATH SHELL TERM USER"}; : ${CLEAR_PREFIX_DIRS:="bin i686-nt32-midipix include lib lib64 libexec minipix native share tmp x86_64-nt64-midipix"};