From 06576a0508f98993bfd2f4d6435f89e28bc892b4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lucio=20Andr=C3=A9s=20Illanes=20Albornoz?= Date: Sat, 15 Feb 2020 15:50:32 +0000 Subject: subr/build_init.subr:buildp_init_prereqs(): remove openssl from & add sha256sum to list of prerequisite commands. subr/ex_rtl_fetch.subr:ex_rtl_fetch_url_wget(): use sha256sum(1) instead of openssl(1) w/ dgst -sha256. etc/README: updated. --- etc/README | 4 ++-- subr/build_init.subr | 6 +++--- subr/ex_rtl_fetch.subr | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/etc/README b/etc/README index 6a7abe1b..ba49f75b 100644 --- a/etc/README +++ b/etc/README @@ -13,8 +13,8 @@ A Midipix distribution consists of the following: libraries such as ncurses, libressl, as well as Perl and Python. ## Build-time dependencies -* **Alpine Linux**: binutils bzip2 cmake coreutils findutils g++ gawk gcc git grep gzip libc-dev linux-headers lzip make musl-dev net-tools openssl patch procps sed tar wget xz zip -* **Debian/-derived Linux**: binutils bzip2 clzip cmake coreutils curl findutils g++ gawk gcc git grep gzip hostname libc6-dev lzma make openssl patch procps sed tar wget xz-utils zip +* **Alpine Linux**: binutils bzip2 cmake coreutils findutils g++ gawk gcc git grep gzip libc-dev linux-headers lzip make musl-dev net-tools patch procps sed tar wget xz zip +* **Debian/-derived Linux**: binutils bzip2 clzip cmake coreutils curl findutils g++ gawk gcc git grep gzip hostname libc6-dev lzma make patch procps sed tar wget xz-utils zip > N.B. Some packages (*coreutils*, *grep*, and *tar*, among others) override Alpine's BusyBox utilities of the same name, as the latter are either non- diff --git a/subr/build_init.subr b/subr/build_init.subr index 8e3adca5..ef0a2150 100644 --- a/subr/build_init.subr +++ b/subr/build_init.subr @@ -164,9 +164,9 @@ buildp_init_prereqs() { if ! which \ awk bunzip2 cat chmod cp date find git grep \ gunzip gzip hostname install kill ln lzip make \ - mkdir mkfifo mv openssl paste patch pgrep pkill \ - printf readlink rm sed seq sort stat tail tar \ - test touch tr wget xz >/dev/null; then + mkdir mkfifo mv paste patch pgrep pkill printf \ + readlink rm sed seq sha256sum sort stat tail \ + tar test touch tr wget xz >/dev/null; then _rc=4; _status="Error: missing prerequisite package(s)."; elif ! awk -V 2>/dev/null | grep -q "^GNU Awk "; then _rc=5; _status="Error: awk(1) in \$PATH must be GNU Awk."; diff --git a/subr/ex_rtl_fetch.subr b/subr/ex_rtl_fetch.subr index 19c0d0d3..8aaebf66 100644 --- a/subr/ex_rtl_fetch.subr +++ b/subr/ex_rtl_fetch.subr @@ -80,7 +80,7 @@ ex_rtl_fetch_url_wget() { if [ ! -e "${_url_dst}.fetched" ]; then wget ${DEFAULT_WGET_ARGS} -O "${_url_dst}" "${_url}"; if [ -n "${_sha256sum_src}" ]; then - set -- $(openssl dgst -sha256 "${_url_dst}"); shift $((${#}-1)); + set -- $(sha256sum "${_url_dst}"); if [ "${_sha256sum_dst:=${1}}" != "${_sha256sum_src}" ]; then ex_rtl_log_msg failexit "Error: hash mismatch for URL \`${_url}' (downloaded file: ${_sha256sum_dst}, from build variables: ${_sha256sum_src}.)"; fi; -- cgit v1.2.3