Revert "openssl: add custom build of 1.0.2 for steam"

No longer necessary. See https://github.com/NixOS/nixpkgs/pull/23034#issuecomment-291005754

This reverts commit a50784b34e771aa4a6c5f4eeb8c25295c15e4ed4.

authored by David McFarland and committed by Frederik Rietdijk 2c006ca8 398823da

+3 -121
+2 -13
pkgs/development/libraries/openssl/default.nix
··· 9 opensslCrossSystem = stdenv.cross.openssl.system or 10 (throw "openssl needs its platform name cross building"); 11 12 - common = args@{ version, sha256, patches ? [], configureFlags ? [], makeDepend ? false }: stdenv.mkDerivation rec { 13 name = "openssl-${version}"; 14 15 src = fetchurl { ··· 47 ] ++ stdenv.lib.optionals withCryptodev [ 48 "-DHAVE_CRYPTODEV" 49 "-DUSE_CRYPTODEV_DIGESTS" 50 - ] ++ stdenv.lib.optional enableSSL2 "enable-ssl2" 51 - ++ args.configureFlags or []; 52 - 53 - postConfigure = if makeDepend then "make depend" else null; 54 55 makeFlags = [ "MANDIR=$(man)/share/man" ]; 56 ··· 119 openssl_1_1_0 = common { 120 version = "1.1.0e"; 121 sha256 = "0k47sdd9gs6yxfv6ldlgpld2lyzrkcv9kz4cf88ck04xjwc8dgjp"; 122 - }; 123 - 124 - openssl_1_0_2-steam = common { 125 - version = "1.0.2k"; 126 - sha256 = "1h6qi35w6hv6rd73p4cdgdzg732pdrfgpp37cgwz1v9a3z37ffbb"; 127 - configureFlags = [ "no-engine" ]; 128 - makeDepend = true; 129 - patches = [ ./openssl-fix-cpuid_setup.patch ]; 130 }; 131 132 }
··· 9 opensslCrossSystem = stdenv.cross.openssl.system or 10 (throw "openssl needs its platform name cross building"); 11 12 + common = args@{ version, sha256, patches ? [] }: stdenv.mkDerivation rec { 13 name = "openssl-${version}"; 14 15 src = fetchurl { ··· 47 ] ++ stdenv.lib.optionals withCryptodev [ 48 "-DHAVE_CRYPTODEV" 49 "-DUSE_CRYPTODEV_DIGESTS" 50 + ] ++ stdenv.lib.optional enableSSL2 "enable-ssl2"; 51 52 makeFlags = [ "MANDIR=$(man)/share/man" ]; 53 ··· 116 openssl_1_1_0 = common { 117 version = "1.1.0e"; 118 sha256 = "0k47sdd9gs6yxfv6ldlgpld2lyzrkcv9kz4cf88ck04xjwc8dgjp"; 119 }; 120 121 }
-105
pkgs/development/libraries/openssl/openssl-fix-cpuid_setup.patch
··· 1 - diff --git a/crypto/cryptlib.c b/crypto/cryptlib.c 2 - index 1925428..d2e42d2 100644 3 - --- a/crypto/cryptlib.c 4 - +++ b/crypto/cryptlib.c 5 - @@ -676,10 +676,15 @@ typedef unsigned __int64 IA32CAP; 6 - # else 7 - typedef unsigned long long IA32CAP; 8 - # endif 9 - + 10 - +/* Compat function for STEAM */ 11 - +extern IA32CAP OPENSSL_ia32_cpuid_new(unsigned int*); 12 - +IA32CAP OPENSSL_ia32_cpuid(void) { return OPENSSL_ia32_cpuid_new(OPENSSL_ia32cap_P); } 13 - + 14 - void OPENSSL_cpuid_setup(void) 15 - { 16 - static int trigger = 0; 17 - - IA32CAP OPENSSL_ia32_cpuid(unsigned int *); 18 - + IA32CAP OPENSSL_ia32_cpuid_new(unsigned int *); 19 - IA32CAP vec; 20 - char *env; 21 - 22 - @@ -697,9 +702,9 @@ void OPENSSL_cpuid_setup(void) 23 - vec = strtoul(env + off, NULL, 0); 24 - # endif 25 - if (off) 26 - - vec = OPENSSL_ia32_cpuid(OPENSSL_ia32cap_P) & ~vec; 27 - + vec = OPENSSL_ia32_cpuid_new(OPENSSL_ia32cap_P) & ~vec; 28 - else if (env[0] == ':') 29 - - vec = OPENSSL_ia32_cpuid(OPENSSL_ia32cap_P); 30 - + vec = OPENSSL_ia32_cpuid_new(OPENSSL_ia32cap_P); 31 - 32 - OPENSSL_ia32cap_P[2] = 0; 33 - if ((env = strchr(env, ':'))) { 34 - @@ -713,7 +718,7 @@ void OPENSSL_cpuid_setup(void) 35 - OPENSSL_ia32cap_P[2] = vecx; 36 - } 37 - } else 38 - - vec = OPENSSL_ia32_cpuid(OPENSSL_ia32cap_P); 39 - + vec = OPENSSL_ia32_cpuid_new(OPENSSL_ia32cap_P); 40 - 41 - /* 42 - * |(1<<10) sets a reserved bit to signal that variable 43 - diff --git a/crypto/cryptlib.h b/crypto/cryptlib.h 44 - index fba180a..b927c79 100644 45 - --- a/crypto/cryptlib.h 46 - +++ b/crypto/cryptlib.h 47 - @@ -99,6 +99,9 @@ extern "C" { 48 - # define HEX_SIZE(type) (sizeof(type)*2) 49 - 50 - void OPENSSL_cpuid_setup(void); 51 - +#pragma GCC visibility push(hidden) 52 - +unsigned long long OPENSSL_ia32_cpuid(void); 53 - +#pragma GCC visibility pop 54 - extern unsigned int OPENSSL_ia32cap_P[]; 55 - void OPENSSL_showfatal(const char *fmta, ...); 56 - void *OPENSSL_stderr(void); 57 - diff --git a/crypto/x86_64cpuid.pl b/crypto/x86_64cpuid.pl 58 - index d208d02..d4c0b24 100644 59 - --- a/crypto/x86_64cpuid.pl 60 - +++ b/crypto/x86_64cpuid.pl 61 - @@ -52,10 +52,10 @@ OPENSSL_rdtsc: 62 - ret 63 - .size OPENSSL_rdtsc,.-OPENSSL_rdtsc 64 - 65 - -.globl OPENSSL_ia32_cpuid 66 - -.type OPENSSL_ia32_cpuid,\@function,1 67 - +.globl OPENSSL_ia32_cpuid_new 68 - +.type OPENSSL_ia32_cpuid_new,\@function,1 69 - .align 16 70 - -OPENSSL_ia32_cpuid: 71 - +OPENSSL_ia32_cpuid_new: 72 - mov %rbx,%r8 # save %rbx 73 - 74 - xor %eax,%eax 75 - @@ -181,7 +181,7 @@ OPENSSL_ia32_cpuid: 76 - mov %r8,%rbx # restore %rbx 77 - or %r9,%rax 78 - ret 79 - -.size OPENSSL_ia32_cpuid,.-OPENSSL_ia32_cpuid 80 - +.size OPENSSL_ia32_cpuid_new,.-OPENSSL_ia32_cpuid_new 81 - 82 - .globl OPENSSL_cleanse 83 - .type OPENSSL_cleanse,\@abi-omnipotent 84 - diff --git a/crypto/x86cpuid.pl b/crypto/x86cpuid.pl 85 - index e95f627..0781010 100644 86 - --- a/crypto/x86cpuid.pl 87 - +++ b/crypto/x86cpuid.pl 88 - @@ -8,7 +8,7 @@ require "x86asm.pl"; 89 - 90 - for (@ARGV) { $sse2=1 if (/-DOPENSSL_IA32_SSE2/); } 91 - 92 - -&function_begin("OPENSSL_ia32_cpuid"); 93 - +&function_begin("OPENSSL_ia32_cpuid_new"); 94 - &xor ("edx","edx"); 95 - &pushf (); 96 - &pop ("eax"); 97 - @@ -153,7 +153,7 @@ for (@ARGV) { $sse2=1 if (/-DOPENSSL_IA32_SSE2/); } 98 - &mov ("eax","esi"); 99 - &mov ("edx","ebp"); 100 - &set_label("nocpuid"); 101 - -&function_end("OPENSSL_ia32_cpuid"); 102 - +&function_end("OPENSSL_ia32_cpuid_new"); 103 - 104 - &external_label("OPENSSL_ia32cap_P"); 105 -
···
+1 -3
pkgs/top-level/all-packages.nix
··· 9240 wolfssl = callPackage ../development/libraries/wolfssl { }; 9241 9242 openssl = openssl_1_0_2; 9243 - openssl-steam = openssl_1_0_2-steam; 9244 9245 inherit (callPackages ../development/libraries/openssl { 9246 fetchurl = fetchurlBoot; ··· 9250 }; 9251 }) 9252 openssl_1_0_2 9253 - openssl_1_1_0 9254 - openssl_1_0_2-steam; 9255 9256 openssl-chacha = callPackage ../development/libraries/openssl/chacha.nix { 9257 cryptodevHeaders = linuxPackages.cryptodev.override {
··· 9240 wolfssl = callPackage ../development/libraries/wolfssl { }; 9241 9242 openssl = openssl_1_0_2; 9243 9244 inherit (callPackages ../development/libraries/openssl { 9245 fetchurl = fetchurlBoot; ··· 9249 }; 9250 }) 9251 openssl_1_0_2 9252 + openssl_1_1_0; 9253 9254 openssl-chacha = callPackage ../development/libraries/openssl/chacha.nix { 9255 cryptodevHeaders = linuxPackages.cryptodev.override {