autogen: try fixing on darwin

and cause no rebuild elsewhere.
In commit 2988780 I forgot that patchelf makes no sense there.
This commit is contained in:
Vladimír Čunát 2020-06-14 09:11:14 +02:00
parent 0697ad33c0
commit e1b93806ba
No known key found for this signature in database
GPG key ID: E747DF1F9575A3AA

View file

@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
outputs = [ "bin" "dev" "lib" "out" "man" "info" ];
nativeBuildInputs = [
which pkgconfig perl autoreconfHook/*patches applied*/
which pkgconfig perl autoreconfHook/*patches applied*/
] ++ stdenv.lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
# autogen needs a build autogen when cross-compiling
buildPackages.buildPackages.autogen buildPackages.texinfo
@ -62,6 +62,7 @@ stdenv.mkDerivation rec {
sed -e "s|$lib/lib|/no-such-autogen-lib-path|" -i $f
done
'' + stdenv.lib.optionalString (!stdenv.hostPlatform.isDarwin) ''
# remove /build/** from RPATHs
for f in "$bin"/bin/*; do
local nrp="$(patchelf --print-rpath "$f" | sed -E 's@(:|^)/build/[^:]*:@\1@g')"