Skip to content

Commit

Permalink
Merge pull request #48276 from LnL7/darwin-nix-index
Browse files Browse the repository at this point in the history
nix-index: fix darwin build
  • Loading branch information
infinisil committed Oct 12, 2018
2 parents 5eb7ca4 + 5c14dec commit e2d857a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 deletions.
13 changes: 7 additions & 6 deletions pkgs/tools/package-management/nix-index/default.nix
@@ -1,8 +1,8 @@
{ lib, rustPlatform, fetchFromGitHub, pkgconfig, openssl, curl }:
{ stdenv, rustPlatform, fetchFromGitHub, pkgconfig, openssl, curl
, Security
}:

with rustPlatform;

buildRustPackage rec {
rustPlatform.buildRustPackage rec {
name = "nix-index-${version}";
version = "0.1.2";

Expand All @@ -14,7 +14,8 @@ buildRustPackage rec {
};
cargoSha256 = "045qm7cyg3sdvf22i8b9cz8gsvggs5bn9xz8k1pvn5gxb7zj24cx";
nativeBuildInputs = [ pkgconfig ];
buildInputs = [ openssl curl];
buildInputs = [ openssl curl ]
++ stdenv.lib.optional stdenv.isDarwin Security;

postInstall = ''
mkdir -p $out/etc/profile.d
Expand All @@ -23,7 +24,7 @@ buildRustPackage rec {
--replace "@out@" "$out"
'';

meta = with lib; {
meta = with stdenv.lib; {
description = "A files database for nixpkgs";
homepage = https://github.com/bennofs/nix-index;
license = with licenses; [ bsd3 ];
Expand Down
4 changes: 3 additions & 1 deletion pkgs/top-level/all-packages.nix
Expand Up @@ -21969,7 +21969,9 @@ with pkgs;
nix-info = callPackage ../tools/nix/info { };
nix-info-tested = nix-info.override { doCheck = true; };

nix-index = callPackage ../tools/package-management/nix-index { };
nix-index = callPackage ../tools/package-management/nix-index {
inherit (darwin.apple_sdk.frameworks) Security;
};

nix-pin = callPackage ../tools/package-management/nix-pin { };

Expand Down

0 comments on commit e2d857a

Please sign in to comment.