diff --git a/etc/scripts/build-external-libs/boost/fetch.sh b/etc/scripts/build-external-libs/boost/fetch.sh index 24c9ea6..8a68690 100755 --- a/etc/scripts/build-external-libs/boost/fetch.sh +++ b/etc/scripts/build-external-libs/boost/fetch.sh @@ -44,7 +44,7 @@ out=${name}_${version}.tar.bz2 rm -rf ${name}_${version} -if [ -f $SRC_BOOST ]; then +if [ ! -z $SRC_BOOST ]; then echo "using pre-fetched $name" cp $SRC_BOOST $out else diff --git a/etc/scripts/build-external-libs/iconv/fetch.sh b/etc/scripts/build-external-libs/iconv/fetch.sh index 1ed1bc8..fe65176 100755 --- a/etc/scripts/build-external-libs/iconv/fetch.sh +++ b/etc/scripts/build-external-libs/iconv/fetch.sh @@ -43,7 +43,7 @@ out=${name}-${version}.tar.gz rm -rf ${name}-${version} -if [ -f $SRC_ICONV ]; then +if [ ! -z $SRC_ICONV ]; then echo "using pre-fetched $name" cp $SRC_ICONV $out else diff --git a/etc/scripts/build-external-libs/openssl/fetch.sh b/etc/scripts/build-external-libs/openssl/fetch.sh index bae8fb1..2584b9b 100755 --- a/etc/scripts/build-external-libs/openssl/fetch.sh +++ b/etc/scripts/build-external-libs/openssl/fetch.sh @@ -43,7 +43,7 @@ out=openssl-${version}.tar.gz rm -rf ${name}-${version} -if [ -f $SRC_OPENSSL ]; then +if [ ! -z $SRC_OPENSSL ]; then echo "using pre-fetched $name" cp $SRC_OPENSSL $out else diff --git a/etc/scripts/build-external-libs/sodium/fetch.sh b/etc/scripts/build-external-libs/sodium/fetch.sh index 10bcfff..b8402a9 100755 --- a/etc/scripts/build-external-libs/sodium/fetch.sh +++ b/etc/scripts/build-external-libs/sodium/fetch.sh @@ -43,7 +43,7 @@ out=${name}-${version}.tar.gz rm -rf ${name}-${version} -if [ -f $SRC_SODIUM ]; then +if [ ! -z $SRC_SODIUM ]; then echo "using pre-fetched $name" cp $SRC_SODIUM $out else diff --git a/etc/scripts/build-external-libs/wownero/fetch.sh b/etc/scripts/build-external-libs/wownero/fetch.sh index 24b78b0..bf0ad08 100755 --- a/etc/scripts/build-external-libs/wownero/fetch.sh +++ b/etc/scripts/build-external-libs/wownero/fetch.sh @@ -45,39 +45,40 @@ chmod u+w -f -R $out || true rm -rf $out -if [ -d $SRC_WOWNERO_DIR ]; then +if [ ! -z $SRC_WOWNERO_DIR ]; then echo "using pre-fetched $name" rsync -av --no-perms --no-owner --no-group --delete $SRC_WOWNERO_DIR/* $out chmod u+w -R $out/external + cd $name else git clone --depth 1 https://github.com/wownero/wownero.git -b $version + cd $name test `git rev-parse HEAD` = $githash || exit 1 fi -cd $name -if [ -d $SRC_MINIUPNP_DIR ]; then +if [ ! -z $SRC_MINIUPNP_DIR ]; then echo "using pre-fetched miniupnpc" rsync -av --no-perms --no-owner --no-group --delete $SRC_MINIUPNP_DIR/* external/miniupnp else git submodule update --init external/miniupnp fi -if [ -d $SRC_RAPIDJSON_DIR ]; then +if [ ! -z $SRC_RAPIDJSON_DIR ]; then echo "using pre-fetched rapidjson" rsync -av --no-perms --no-owner --no-group --delete $SRC_RAPIDJSON_DIR/* external/rapidjson else git submodule update --init external/rapidjson fi -if [ -f $SRC_RANDOMWOW ]; then +if [ ! -z $SRC_RANDOMWOW ]; then echo "using pre-fetched RandomWOW" tar xzf $SRC_RANDOMWOW -C external/RandomWOW --strip-components=1 else git submodule update --init external/RandomWOW fi -if [ -d $SRC_UNBOUND_DIR ]; then +if [ ! -z $SRC_UNBOUND_DIR ]; then echo "using pre-fetched unbound" rsync -av --no-perms --no-owner --no-group --delete $SRC_UNBOUND_DIR/* external/unbound else