Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

openssl_1_1: use less #196906

Merged
merged 5 commits into from
Nov 10, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 4 additions & 9 deletions pkgs/development/interpreters/python/cpython/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
, mailcap, mimetypesSupport ? true
, ncurses
, openssl
, openssl_1_1
, readline
, sqlite
, tcl ? null, tk ? null, tix ? null, libX11 ? null, xorgproto ? null, x11Support ? false
Expand Down Expand Up @@ -77,10 +76,6 @@ assert lib.assertMsg (reproducibleBuild -> (!rebuildBytecode))
with lib;

let
# cpython does support/build with openssl 3.0, but some libraries using the ssl module seem to have issues with it
# null check for Minimal
openssl' = if openssl != null then openssl_1_1 else null;

buildPackages = pkgsBuildHost;
inherit (passthru) pythonForBuild;

Expand Down Expand Up @@ -121,7 +116,7 @@ let
];

buildInputs = filter (p: p != null) ([
zlib bzip2 expat xz libffi gdbm sqlite readline ncurses openssl' ]
zlib bzip2 expat xz libffi gdbm sqlite readline ncurses openssl ]
++ optionals x11Support [ tcl tk libX11 xorgproto ]
++ optionals (bluezSupport && stdenv.isLinux) [ bluez ]
++ optionals stdenv.isDarwin [ configd ])
Expand Down Expand Up @@ -327,8 +322,8 @@ in with passthru; stdenv.mkDerivation {
"--with-threads"
] ++ optionals (sqlite != null && isPy3k) [
"--enable-loadable-sqlite-extensions"
] ++ optionals (openssl' != null) [
"--with-openssl=${openssl'.dev}"
] ++ optionals (openssl != null) [
"--with-openssl=${openssl.dev}"
] ++ optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
"ac_cv_buggy_getaddrinfo=no"
# Assume little-endian IEEE 754 floating point when cross compiling
Expand Down Expand Up @@ -493,7 +488,7 @@ in with passthru; stdenv.mkDerivation {
# Enforce that we don't have references to the OpenSSL -dev package, which we
# explicitly specify in our configure flags above.
disallowedReferences =
lib.optionals (openssl' != null && !static) [ openssl'.dev ]
lib.optionals (openssl != null && !static) [ openssl.dev ]
++ lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
# Ensure we don't have references to build-time packages.
# These typically end up in shebangs.
Expand Down
7 changes: 6 additions & 1 deletion pkgs/development/libraries/cyrus-sasl/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{ lib, stdenv, fetchurl, openssl, openldap, libkrb5, db, gettext
{ lib, stdenv, fetchurl, fetchpatch, openssl, openldap, libkrb5, db, gettext
, pam, libxcrypt, fixDarwinDylibNames, autoreconfHook, enableLdap ? false
, buildPackages, pruneLibtoolFiles, nixosTests }:

Expand All @@ -19,6 +19,11 @@ stdenv.mkDerivation rec {
patches = [
# Fix cross-compilation
./cyrus-sasl-ac-try-run-fix.patch
# make compatible with openssl3. can probably be dropped with any release after 2.1.28
(fetchpatch {
url = "https://github.com/cyrusimap/cyrus-sasl/compare/cb549ef71c5bb646fe583697ebdcaba93267a237...c2bd3afbca57f176d8c650670ce371444bb7fcc0.patch";
hash = "sha256-bYeIkvle1Ms7Lnoob4eLd4RbPFHtPkKRZvfHNCBJY/s=";
})
];

outputs = [ "bin" "dev" "out" "man" "devdoc" ];
Expand Down
2 changes: 2 additions & 0 deletions pkgs/development/libraries/openldap/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,8 @@ stdenv.mkDerivation rec {
preCheck = ''
substituteInPlace tests/scripts/all \
--replace "/bin/rm" "rm"
# fails saying "SASL(-1): generic failure: internal error: failed to init cipher 'rc4'"
rm tests/scripts/test076-authid-rewrite
'';

doCheck = true;
Expand Down
5 changes: 1 addition & 4 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -18381,7 +18381,6 @@ with pkgs;

cyrus_sasl = callPackage ../development/libraries/cyrus-sasl {
libkrb5 = if stdenv.isFreeBSD then libheimdal else libkrb5;
openssl = openssl_1_1;
};

# Make bdb5 the default as it is the last release under the custom
Expand Down Expand Up @@ -21470,9 +21469,7 @@ with pkgs;

openexrid-unstable = callPackage ../development/libraries/openexrid-unstable { };

openldap = callPackage ../development/libraries/openldap {
openssl = openssl_1_1;
};
openldap = callPackage ../development/libraries/openldap { };

opencolorio = darwin.apple_sdk_11_0.callPackage ../development/libraries/opencolorio {
inherit (darwin.apple_sdk_11_0.frameworks) Carbon GLUT Cocoa;
Expand Down