nixpkgs/pkgs/development/libraries/soci/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

47 lines
1 KiB
Nix
Raw Normal View History

2020-03-20 14:50:33 +01:00
{ cmake
, fetchFromGitHub
, fetchpatch
2020-03-20 14:50:33 +01:00
, sqlite
, postgresql
, boost
, lib, stdenv
2020-03-20 14:50:33 +01:00
}:
stdenv.mkDerivation rec {
pname = "soci";
version = "4.0.2";
2020-03-20 14:50:33 +01:00
src = fetchFromGitHub {
owner = "SOCI";
repo = pname;
rev = "v${version}";
sha256 = "sha256-NE0ApbX8HG2VAQ9cg9+kX3kJQ4PR1XvWL9BlT8NphmE=";
2020-03-20 14:50:33 +01:00
};
patches = [
(fetchpatch {
name = "fix-backend-search-path.patch";
url = "https://github.com/SOCI/soci/commit/56c93afc467bdba8ffbe68739eea76059ea62f7a.patch";
sha256 = "sha256-nC/39pn3Cv5e65GgIfF3l64/AbCsfZHPUPIWETZFZAY=";
})
];
2020-03-20 14:50:33 +01:00
# Do not build static libraries
cmakeFlags = [ "-DSOCI_STATIC=OFF" "-DCMAKE_CXX_STANDARD=11" "-DSOCI_TESTS=off" ];
2020-03-20 14:50:33 +01:00
nativeBuildInputs = [ cmake ];
buildInputs = [
sqlite
postgresql
boost
];
2020-03-20 14:50:33 +01:00
meta = with lib; {
2020-03-20 14:50:33 +01:00
description = "Database access library for C++";
homepage = "http://soci.sourceforge.net/";
license = licenses.boost;
platforms = platforms.all;
maintainers = with maintainers; [ jluttine ];
};
}