1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-27 11:07:44 +00:00

Merge pull request #5019 from sargas/explain-gnu-build-clone

util/build-gnu.sh: Improve error message when missing GNU Coreutils repository
This commit is contained in:
Daniel Hofstetter 2023-06-29 16:38:31 +02:00 committed by GitHub
commit 4ec73aa184
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -11,28 +11,31 @@ ME="${0}"
ME_dir="$(dirname -- "$(readlink -fm -- "${ME}")")" ME_dir="$(dirname -- "$(readlink -fm -- "${ME}")")"
REPO_main_dir="$(dirname -- "${ME_dir}")" REPO_main_dir="$(dirname -- "${ME_dir}")"
echo "ME='${ME}'"
echo "ME_dir='${ME_dir}'"
echo "REPO_main_dir='${REPO_main_dir}'"
### * config (from environment with fallback defaults); note: GNU is expected to be a sibling repo directory ### * config (from environment with fallback defaults); note: GNU is expected to be a sibling repo directory
path_UUTILS=${path_UUTILS:-${REPO_main_dir}} path_UUTILS=${path_UUTILS:-${REPO_main_dir}}
path_GNU="$(readlink -fm -- "${path_GNU:-${path_UUTILS}/../gnu}")" path_GNU="$(readlink -fm -- "${path_GNU:-${path_UUTILS}/../gnu}")"
echo "path_UUTILS='${path_UUTILS}'"
echo "path_GNU='${path_GNU}'"
### ###
if test ! -d "${path_GNU}"; then if test ! -d "${path_GNU}"; then
echo "Could not find GNU (expected at '${path_GNU}')" echo "Could not find GNU coreutils (expected at '${path_GNU}')"
echo "Run the following to download into the expected path:"
echo "git clone --recurse-submodules https://github.com/coreutils/coreutils.git \"${path_GNU}\"" echo "git clone --recurse-submodules https://github.com/coreutils/coreutils.git \"${path_GNU}\""
exit 1 exit 1
fi fi
### ###
echo "ME='${ME}'"
echo "ME_dir='${ME_dir}'"
echo "REPO_main_dir='${REPO_main_dir}'"
echo "path_UUTILS='${path_UUTILS}'"
echo "path_GNU='${path_GNU}'"
###
UU_MAKE_PROFILE=${UU_MAKE_PROFILE:-release} UU_MAKE_PROFILE=${UU_MAKE_PROFILE:-release}
echo "UU_MAKE_PROFILE='${UU_MAKE_PROFILE}'" echo "UU_MAKE_PROFILE='${UU_MAKE_PROFILE}'"