tup: Fix static build (#420878)
This commit is contained in:
@@ -38,7 +38,19 @@ stdenv.mkDerivation rec {
|
||||
patches = [ ./fusermount-setuid.patch ];
|
||||
|
||||
configurePhase = ''
|
||||
substituteInPlace src/tup/link.sh --replace '`git describe' '`echo ${version}'
|
||||
substituteInPlace src/tup/link.sh --replace-fail '`git describe' '`echo ${version}'
|
||||
|
||||
for path in Tupfile build.sh src/tup/server/Tupfile ; do
|
||||
substituteInPlace $path --replace-fail "pkg-config" "${stdenv.cc.targetPrefix}pkg-config"
|
||||
done
|
||||
|
||||
# Replace "pcre2-config --libs8" => "pkg-config libpcre2-8 --libs".
|
||||
#
|
||||
# There is prefixed pkg-config for cross-compilation, but no prefixed "pcre2-config".
|
||||
for path in Tupfile Tuprules.tup ; do
|
||||
substituteInPlace $path --replace-fail "pcre2-config" "${stdenv.cc.targetPrefix}pkg-config libpcre2-8 "
|
||||
done
|
||||
substituteInPlace Tupfile --replace-fail "--libs8" "--libs"
|
||||
|
||||
cat << EOF > tup.config
|
||||
CONFIG_CC=${stdenv.cc.targetPrefix}cc
|
||||
|
||||
Reference in New Issue
Block a user