Skip to content

Commit

Permalink
[Backport release-24.11] various packages: use new darwin sdk pattern (
Browse files Browse the repository at this point in the history
  • Loading branch information
wolfgangwalther authored Dec 4, 2024
2 parents 2d5ba66 + 2ea2b18 commit 0dad3a7
Show file tree
Hide file tree
Showing 12 changed files with 7 additions and 52 deletions.
4 changes: 0 additions & 4 deletions pkgs/by-name/ca/cargo-feature/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
lib,
rustPlatform,
fetchFromGitHub,
stdenv,
libiconv,
}:

rustPlatform.buildRustPackage rec {
Expand All @@ -19,8 +17,6 @@ rustPlatform.buildRustPackage rec {

cargoHash = "sha256-8qrpW/gU7BvxN3nSbFWhbgu5bwsdzYZTS3w3kcwsGbU=";

buildInputs = lib.optional stdenv.hostPlatform.isDarwin libiconv;

checkFlags = [
# The following tests require empty CARGO_BUILD_TARGET env variable, but we
# set it ever since https://github.com/NixOS/nixpkgs/pull/298108.
Expand Down
4 changes: 1 addition & 3 deletions pkgs/by-name/ca/cargo-fuzz/package.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{ lib, fetchFromGitHub, rustPlatform, stdenv, libiconv }:
{ lib, fetchFromGitHub, rustPlatform }:

rustPlatform.buildRustPackage rec {
pname = "cargo-fuzz";
Expand All @@ -13,8 +13,6 @@ rustPlatform.buildRustPackage rec {

cargoHash = "sha256-sfvepPpYtgA0TuUlu0CD50HX933AVQbUGzJBNAzFR94=";

buildInputs = lib.optional stdenv.hostPlatform.isDarwin libiconv;

doCheck = false;

meta = with lib; {
Expand Down
4 changes: 0 additions & 4 deletions pkgs/by-name/ca/cargo-limit/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
, rustPlatform
, fetchFromGitHub
, nix-update-script
, stdenv
, libiconv
}:

rustPlatform.buildRustPackage rec {
Expand All @@ -19,8 +17,6 @@ rustPlatform.buildRustPackage rec {

cargoHash = "sha256-dwqbG0UFeUQHa0K98ebHfjbcQuQOhK2s6ZxAT6r0cik=";

buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [ libiconv ];

passthru = {
updateScript = nix-update-script { };
};
Expand Down
5 changes: 0 additions & 5 deletions pkgs/by-name/ca/cargo-unfmt/package.nix
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
{ lib
, stdenv
, fetchFromGitHub
, rustPlatform
, darwin
, libiconv
}:

rustPlatform.buildRustPackage {
Expand All @@ -19,8 +16,6 @@ rustPlatform.buildRustPackage {

cargoHash = "sha256-mMeHTYCUIZR3jVvTxfyH4I9wGfUdCWcyn9djnksAY8k=";

buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [ libiconv darwin.apple_sdk.frameworks.Security ];

# Doc tests are broken on 0.3.3
doCheck = false;

Expand Down
6 changes: 1 addition & 5 deletions pkgs/by-name/ez/eza/package.nix
Original file line number Diff line number Diff line change
@@ -1,14 +1,11 @@
{ lib
, gitSupport ? true
, stdenv
, fetchFromGitHub
, rustPlatform
, cmake
, pandoc
, pkg-config
, zlib
, darwin
, libiconv
, installShellFiles
# once eza upstream gets support for setting up a compatibility symlink for exa, we should change
# the handling here from postInstall to passing the required argument to the builder.
Expand All @@ -29,8 +26,7 @@ rustPlatform.buildRustPackage rec {
cargoHash = "sha256-k9zSchHFF2t30ca15eadEhnO0aFH5KIc1i0uuBKZZtc=";

nativeBuildInputs = [ cmake pkg-config installShellFiles pandoc ];
buildInputs = [ zlib ]
++ lib.optionals stdenv.hostPlatform.isDarwin [ libiconv darwin.apple_sdk.frameworks.Security ];
buildInputs = [ zlib ];

buildNoDefaultFeatures = true;
buildFeatures = lib.optional gitSupport "git";
Expand Down
6 changes: 1 addition & 5 deletions pkgs/by-name/op/openpgp-card-tools/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
, dbus
, testers
, openpgp-card-tools
, darwin
}:

rustPlatform.buildRustPackage rec {
Expand All @@ -27,10 +26,7 @@ rustPlatform.buildRustPackage rec {

nativeBuildInputs = [ installShellFiles pkg-config rustPlatform.bindgenHook ];

buildInputs = [ pcsclite dbus ] ++ lib.optionals stdenv.hostPlatform.isDarwin [
darwin.apple_sdk.frameworks.PCSC
darwin.apple_sdk.frameworks.Security
];
buildInputs = [ pcsclite dbus ];

passthru = {
tests.version = testers.testVersion {
Expand Down
4 changes: 0 additions & 4 deletions pkgs/by-name/os/ostree-rs-ext/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
, zlib
, ostree
, stdenv
, darwin
, util-linux
, skopeo
, gnutar
Expand Down Expand Up @@ -44,9 +43,6 @@ rustPlatform.buildRustPackage rec {
openssl
zlib
ostree
] ++ lib.optionals stdenv.hostPlatform.isDarwin [
darwin.apple_sdk.frameworks.CoreFoundation
darwin.apple_sdk.frameworks.Security
];

checkFlags = [
Expand Down
11 changes: 2 additions & 9 deletions pkgs/by-name/re/reindeer/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
, fetchFromGitHub
, pkg-config
, openssl
, stdenv
, libiconv
, darwin
, nix-update-script
}:

Expand All @@ -23,12 +20,8 @@ rustPlatform.buildRustPackage rec {
cargoHash = "sha256-OjA0OKotAdRLGRkl8n3Gn2+Z8JVcGjQYHtOszWnnFdM=";

nativeBuildInputs = [ pkg-config ];
buildInputs =
[ openssl ] ++ lib.optionals stdenv.hostPlatform.isDarwin [
libiconv
darwin.apple_sdk.frameworks.Security
darwin.apple_sdk.frameworks.CoreServices
];

buildInputs = [ openssl ];

passthru.updateScript = nix-update-script { };

Expand Down
4 changes: 0 additions & 4 deletions pkgs/by-name/se/sequoia-chameleon-gnupg/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
, nettle
, openssl
, sqlite
, darwin
}:

rustPlatform.buildRustPackage rec {
Expand All @@ -31,9 +30,6 @@ rustPlatform.buildRustPackage rec {
nettle
openssl
sqlite
] ++ lib.optionals stdenv.hostPlatform.isDarwin [
darwin.apple_sdk.frameworks.Security
darwin.apple_sdk.frameworks.SystemConfiguration
];

# gpgconf: error creating socket directory
Expand Down
4 changes: 0 additions & 4 deletions pkgs/development/python-modules/cryptg/default.nix
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
{
lib,
stdenv,
buildPythonPackage,
fetchFromGitHub,
pythonOlder,
Expand All @@ -9,7 +8,6 @@
rustc,
setuptools,
setuptools-rust,
libiconv,
}:

buildPythonPackage rec {
Expand Down Expand Up @@ -42,8 +40,6 @@ buildPythonPackage rec {
cargo
];

buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [ libiconv ];

# has no tests
doCheck = false;

Expand Down
3 changes: 1 addition & 2 deletions pkgs/tools/filesystems/garage/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
, pkg-config
, protobuf
, cacert
, Security
, garage
, nixosTests
}:
Expand Down Expand Up @@ -35,7 +34,7 @@ let

buildInputs = [
openssl
] ++ lib.optional stdenv.hostPlatform.isDarwin Security;
];

checkInputs = [
cacert
Expand Down
4 changes: 1 addition & 3 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -3522,9 +3522,7 @@ with pkgs;

gaphor = python3Packages.callPackage ../tools/misc/gaphor { };

inherit (callPackages ../tools/filesystems/garage {
inherit (darwin.apple_sdk.frameworks) Security;
})
inherit (callPackages ../tools/filesystems/garage { })
garage
garage_0_8 garage_0_9
garage_0_8_7 garage_0_9_4
Expand Down

0 comments on commit 0dad3a7

Please sign in to comment.