From 1ed8ae38c954e5b4b2607f50bf50831d9dddda13 Mon Sep 17 00:00:00 2001 From: Izorkin Date: Thu, 30 Jun 2022 23:28:12 +0300 Subject: [PATCH 1/3] quictls: 3.0.3+quick_unstable-2022-05.04 -> 3.0.5+quick_unstable-2022-07.05 --- pkgs/development/libraries/quictls/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/libraries/quictls/default.nix b/pkgs/development/libraries/quictls/default.nix index 0f85836a9c68..3dab26f17489 100644 --- a/pkgs/development/libraries/quictls/default.nix +++ b/pkgs/development/libraries/quictls/default.nix @@ -11,13 +11,13 @@ stdenv.mkDerivation rec { pname = "quictls"; - version = "3.0.3+quick_unstable-2022-05.04"; + version = "3.0.5+quick_unstable-2022-07.05"; src = fetchFromGitHub { owner = "quictls"; repo = "openssl"; - rev = "368c9d581b17f0bbe425f8dedeaa7b864a7b29ce"; - sha256 = "sha256-W3bILxhyeziWQNZUHUg/D9eV8LnmHJqEFwyzWjJrRuc="; + rev = "75e940831d0570d6b020cfebf128ae500f424867"; + sha256 = "sha256-1HBGKafcCbM0RZWLvyl3vpSfGBsAcGDgjz1Nm/qclWM="; }; patches = [ From 94ffbb4fdfd2e96e2a34885d13a647f6064b26e9 Mon Sep 17 00:00:00 2001 From: Izorkin Date: Thu, 30 Jun 2022 23:52:34 +0300 Subject: [PATCH 2/3] quictls: specify the ABI explicitly on mips64 cherry picked from commit 77d6781cdc7b472bc5d6991b5afc5b6c0928d3d6 --- pkgs/development/libraries/quictls/default.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pkgs/development/libraries/quictls/default.nix b/pkgs/development/libraries/quictls/default.nix index 3dab26f17489..72640989be6e 100644 --- a/pkgs/development/libraries/quictls/default.nix +++ b/pkgs/development/libraries/quictls/default.nix @@ -68,6 +68,12 @@ stdenv.mkDerivation rec { x86_64-linux = "./Configure linux-x86_64"; x86_64-solaris = "./Configure solaris64-x86_64-gcc"; riscv64-linux = "./Configure linux64-riscv64"; + mips64el-linux = + if stdenv.hostPlatform.isMips64n64 + then "./Configure linux64-mips64" + else if stdenv.hostPlatform.isMips64n32 + then "./Configure linux-mips64" + else throw "unsupported ABI for ${stdenv.hostPlatform.system}"; }.${stdenv.hostPlatform.system} or ( if stdenv.hostPlatform == stdenv.buildPlatform then "./config" From 4f99d8e7089a310436342b3554a8ee649fe1d296 Mon Sep 17 00:00:00 2001 From: Izorkin Date: Thu, 30 Jun 2022 23:46:40 +0300 Subject: [PATCH 3/3] quictls: disable ct feature in static mode cherry picked from commit cc60c24909a8b207a0a2dfc18082453ab85c46af --- pkgs/development/libraries/quictls/default.nix | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/pkgs/development/libraries/quictls/default.nix b/pkgs/development/libraries/quictls/default.nix index 72640989be6e..22981bfef7af 100644 --- a/pkgs/development/libraries/quictls/default.nix +++ b/pkgs/development/libraries/quictls/default.nix @@ -7,6 +7,7 @@ # This will cause c_rehash to refer to perl via the environment, but otherwise # will produce a perfectly functional openssl binary and library. , withPerl ? stdenv.hostPlatform == stdenv.buildPlatform +, removeReferencesTo }: stdenv.mkDerivation rec { @@ -51,7 +52,7 @@ stdenv.mkDerivation rec { !(stdenv.hostPlatform.useLLVM or false) && stdenv.cc.isGNU; - nativeBuildInputs = [ perl ]; + nativeBuildInputs = [ perl removeReferencesTo ]; buildInputs = lib.optional withCryptodev cryptodev # perl is included to allow the interpreter path fixup hook to set the # correct interpreter in c_rehash. @@ -111,7 +112,11 @@ stdenv.mkDerivation rec { # OpenSSL needs a specific `no-shared` configure flag. # See https://wiki.openssl.org/index.php/Compilation_and_Installation#Configure_Options # for a comprehensive list of configuration options. - ++ lib.optional static "no-shared"; + ++ lib.optional static "no-shared" + # This introduces a reference to the CTLOG_FILE which is undesired when + # trying to build binaries statically. + ++ lib.optional static "no-ct" + ; makeFlags = [ "MANDIR=$(man)/share/man" @@ -124,13 +129,16 @@ stdenv.mkDerivation rec { enableParallelBuilding = true; - postInstall = lib.optionalString (!static) '' + postInstall = (if static then '' + # OPENSSLDIR has a reference to self + ${removeReferencesTo}/bin/remove-references-to -t $out $out/lib/*.a + '' else '' # If we're building dynamic libraries, then don't install static # libraries. if [ -n "$(echo $out/lib/*.so $out/lib/*.dylib $out/lib/*.dll)" ]; then rm "$out/lib/"*.a fi - '' + lib.optionalString (!stdenv.hostPlatform.isWindows) + '') + lib.optionalString (!stdenv.hostPlatform.isWindows) # Fix bin/c_rehash's perl interpreter line # # - openssl 1_0_2: embeds a reference to buildPackages.perl