diff options
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/uthash')
-rw-r--r-- | nixpkgs/pkgs/development/libraries/uthash/default.nix | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/libraries/uthash/default.nix b/nixpkgs/pkgs/development/libraries/uthash/default.nix new file mode 100644 index 000000000000..b80984303d76 --- /dev/null +++ b/nixpkgs/pkgs/development/libraries/uthash/default.nix @@ -0,0 +1,31 @@ +{ stdenv, fetchurl, perl }: + +let + version = "2.1.0"; +in +stdenv.mkDerivation rec { + name = "uthash-${version}"; + + src = fetchurl { + url = "https://github.com/troydhanson/uthash/archive/v${version}.tar.gz"; + sha256 = "17k6k97n20jpi9zj3lzvqfw8pv670r6rdqrjf8vrbx6hcj7csb0m"; + }; + + dontBuild = false; + + doCheck = true; + checkInputs = [ perl ]; + checkTarget = "-C tests/"; + + installPhase = '' + mkdir -p "$out/include" + cp ./src/* "$out/include/" + ''; + + meta = with stdenv.lib; { + description = "A hash table for C structures"; + homepage = http://troydhanson.github.io/uthash; + license = licenses.bsd2; # it's one-clause, actually, as it's source-only + platforms = platforms.all; + }; +} |