diff options
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/sexpp')
-rw-r--r-- | nixpkgs/pkgs/development/libraries/sexpp/default.nix | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/libraries/sexpp/default.nix b/nixpkgs/pkgs/development/libraries/sexpp/default.nix new file mode 100644 index 000000000000..dd41d520d28c --- /dev/null +++ b/nixpkgs/pkgs/development/libraries/sexpp/default.nix @@ -0,0 +1,48 @@ +{ lib +, stdenv +, bzip2 +, cmake +, fetchFromGitHub +, gtest +, pkg-config +, zlib +}: + +stdenv.mkDerivation (finalAttrs: { + pname = "sexpp"; + version = "0.8.7"; + + src = fetchFromGitHub { + owner = "rnpgp"; + repo = "sexpp"; + rev = "v${finalAttrs.version}"; + hash = "sha256-E1ESN3JKCWYBt1o37d7EVcgARnwGKS6mxua+0m1RMlM="; + }; + + buildInputs = [ zlib bzip2 ]; + + cmakeFlags = [ + "-DCMAKE_INSTALL_PREFIX=${placeholder "out"}" + "-DBUILD_SHARED_LIBS=on" + "-DWITH_SEXP_TESTS=on" + "-DDOWNLOAD_GTEST=off" + "-DWITH_SEXP_CLI=on" + "-DWITH_SANITIZERS=off" + ]; + + nativeBuildInputs = [ cmake gtest pkg-config ]; + + outputs = [ "out" "lib" "dev" ]; + + preConfigure = '' + echo "v${finalAttrs.version}" > version.txt + ''; + + meta = with lib; { + homepage = "https://github.com/rnpgp/sexp"; + description = "S-expressions parser and generator C++ library, fully compliant to [https://people.csail.mit.edu/rivest/Sexp.txt]"; + license = licenses.mit; + platforms = platforms.all; + maintainers = with maintainers; [ ribose-jeffreylau ]; + }; +}) |