1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-12-15 00:54:46 +00:00
nixpkgs/pkgs/development/libraries/leveldb/default.nix
Vladimír Čunát 336bc8283b
Re-Revert "Merge #101508: libraw: 0.20.0 -> 0.20.2"
This reverts commit c778945806.

I believe this is exactly what brings the staging branch into
the right shape after the last merge from master (through staging-next);
otherwise part of staging changes would be lost
(due to being already reachable from master but reverted).
2020-10-26 08:19:17 +01:00

43 lines
972 B
Nix

{ stdenv, fetchFromGitHub, fixDarwinDylibNames, snappy }:
stdenv.mkDerivation rec {
pname = "leveldb";
version = "1.20";
src = fetchFromGitHub {
owner = "google";
repo = "leveldb";
rev = "v${version}";
sha256 = "01kxga1hv4wp94agx5vl3ybxfw5klqrdsrb6p6ywvnjmjxm8322y";
};
buildInputs = [ snappy ];
nativeBuildInputs = []
++ stdenv.lib.optional stdenv.isDarwin fixDarwinDylibNames;
buildPhase = ''
make all
'';
installPhase = "
mkdir -p $out/{bin,lib,include}
cp -r include $out
mkdir -p $out/include/leveldb/helpers
cp helpers/memenv/memenv.h $out/include/leveldb/helpers
cp out-shared/lib* $out/lib
cp out-static/lib* $out/lib
cp out-static/leveldbutil $out/bin
";
meta = with stdenv.lib; {
homepage = "https://github.com/google/leveldb";
description = "Fast and lightweight key/value database library by Google";
license = licenses.bsd3;
platforms = platforms.all;
};
}