diff options
author | figsoda <figsoda@pm.me> | 2023-09-01 12:07:37 -0400 |
---|---|---|
committer | Anderson Torres <torres.anderson.85@protonmail.com> | 2023-09-01 18:35:02 +0000 |
commit | da2da3adce343a29fa41f2ec7fa907e74284a6df (patch) | |
tree | 79e48b5778317b725620c814627953f17781ce05 /pkgs/tools/nix/fh | |
parent | 48da6eb9c1126893773d86d142fe306332867ff7 (diff) | |
download | nixpkgs-da2da3adce343a29fa41f2ec7fa907e74284a6df.tar nixpkgs-da2da3adce343a29fa41f2ec7fa907e74284a6df.tar.gz nixpkgs-da2da3adce343a29fa41f2ec7fa907e74284a6df.tar.bz2 nixpkgs-da2da3adce343a29fa41f2ec7fa907e74284a6df.tar.lz nixpkgs-da2da3adce343a29fa41f2ec7fa907e74284a6df.tar.xz nixpkgs-da2da3adce343a29fa41f2ec7fa907e74284a6df.tar.zst nixpkgs-da2da3adce343a29fa41f2ec7fa907e74284a6df.zip |
fh: init at 0.1.1
https://github.com/DeterminateSystems/fh
Diffstat (limited to 'pkgs/tools/nix/fh')
-rw-r--r-- | pkgs/tools/nix/fh/default.nix | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/pkgs/tools/nix/fh/default.nix b/pkgs/tools/nix/fh/default.nix new file mode 100644 index 00000000000..03c14ccadd6 --- /dev/null +++ b/pkgs/tools/nix/fh/default.nix @@ -0,0 +1,48 @@ +{ lib +, rustPlatform +, fetchFromGitHub +, stdenv +, darwin +, gcc +, libcxx +}: + +rustPlatform.buildRustPackage rec { + pname = "fh"; + version = "0.1.1"; + + src = fetchFromGitHub { + owner = "DeterminateSystems"; + repo = "fh"; + rev = "v${version}"; + hash = "sha256-lTm4C06FtlaIJyhqZ4POubiR4qc0fPHawLS4cpneACg="; + }; + + cargoHash = "sha256-CvuQeS+g9bdpYzop63BL0UKQsdOELGt1tR2Xz4FLxpE="; + + nativeBuildInputs = [ + rustPlatform.bindgenHook + ]; + + buildInputs = lib.optionals stdenv.isDarwin [ + darwin.apple_sdk.frameworks.Security + gcc.cc.lib + ]; + + env = lib.optionalAttrs stdenv.isDarwin { + NIX_CFLAGS_COMPILE = "-I${lib.getDev libcxx}/include/c++/v1"; + }; + + # Cargo.lock is outdated + postConfigure = '' + cargo metadata --offline + ''; + + meta = with lib; { + description = "The official FlakeHub CLI"; + homepage = "https://github.com/DeterminateSystems/fh"; + license = licenses.asl20; + maintainers = with maintainers; [ figsoda ]; + mainProgram = "fh"; + }; +} |