From 33944d5ddd7ddfb841248c77f45c46d2228d21a8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Tue, 20 Sep 2022 16:25:47 +0200 Subject: [PATCH] openssl: fix static cross compilation --- pkgs/development/libraries/openssl/default.nix | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/openssl/default.nix b/pkgs/development/libraries/openssl/default.nix index 471666129fc1..78cc680c7be5 100644 --- a/pkgs/development/libraries/openssl/default.nix +++ b/pkgs/development/libraries/openssl/default.nix @@ -67,7 +67,8 @@ let !(stdenv.hostPlatform.useLLVM or false) && stdenv.cc.isGNU; - nativeBuildInputs = [ perl ]; + nativeBuildInputs = [ perl ] + ++ lib.optionals static [ removeReferencesTo ]; buildInputs = lib.optional withCryptodev cryptodev # perl is included to allow the interpreter path fixup hook to set the # correct interpreter in c_rehash. @@ -155,7 +156,7 @@ let postInstall = (if static then '' # OPENSSLDIR has a reference to self - ${removeReferencesTo}/bin/remove-references-to -t $out $out/lib/*.a + remove-references-to -t $out $out/lib/*.a '' else '' # If we're building dynamic libraries, then don't install static # libraries.