mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-28 08:33:54 +00:00
4a7f99d55d
Part of: https://github.com/NixOS/nixpkgs/issues/108938 meta = with stdenv.lib; is a widely used pattern. We want to slowly remove the `stdenv.lib` indirection and encourage people to use `lib` directly. Thus let’s start with the meta field. This used a rewriting script to mostly automatically replace all occurances of this pattern, and add the `lib` argument to the package header if it doesn’t exist yet. The script in its current form is available at https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
38 lines
1019 B
Nix
38 lines
1019 B
Nix
{ lib, stdenv, fetchFromGitHub, rustPlatform, pkgconfig, openssl, libsodium
|
|
, llvmPackages, clang, lzma
|
|
, Security }:
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
pname = "rdedup";
|
|
version = "3.1.1";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "dpc";
|
|
repo = "rdedup";
|
|
rev = "rdedup-v${version}";
|
|
sha256 = "0y34a3mpghdmcb2rx4z62q0s351bfmy1287d75mm07ryfgglgsd7";
|
|
};
|
|
|
|
cargoSha256 = "0akwb7ak4h1i1zk4wcn27zyqjz6mrchs47014xbzw22rj8h8dx92";
|
|
|
|
cargoPatches = [
|
|
./v3.1.1-fix-Cargo.lock.patch
|
|
];
|
|
|
|
nativeBuildInputs = [ pkgconfig llvmPackages.libclang clang ];
|
|
buildInputs = [ openssl libsodium lzma ]
|
|
++ (stdenv.lib.optional stdenv.isDarwin Security);
|
|
|
|
configurePhase = ''
|
|
export LIBCLANG_PATH="${llvmPackages.libclang}/lib"
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "Data deduplication with compression and public key encryption";
|
|
homepage = "https://github.com/dpc/rdedup";
|
|
license = licenses.mpl20;
|
|
maintainers = with maintainers; [ dywedir ];
|
|
broken = stdenv.isDarwin;
|
|
};
|
|
}
|