nixpkgs/pkgs/development/libraries/abseil-cpp/202111.nix

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

37 lines
839 B
Nix
Raw Normal View History

2021-10-31 10:02:34 +00:00
{ lib
, stdenv
, fetchFromGitHub
, fetchpatch
, cmake
, static ? stdenv.hostPlatform.isStatic
, cxxStandard ? null
}:
stdenv.mkDerivation rec {
pname = "abseil-cpp";
2022-02-05 21:41:23 +00:00
version = "20211102.0";
src = fetchFromGitHub {
owner = "abseil";
repo = "abseil-cpp";
rev = version;
2022-02-05 21:41:23 +00:00
sha256 = "sha256-sSXT6D4JSrk3dA7kVaxfKkzOMBpqXQb0WbMYWG+nGwk=";
};
2021-02-13 19:58:22 +00:00
cmakeFlags = [
2021-03-20 04:20:00 +00:00
"-DBUILD_SHARED_LIBS=${if static then "OFF" else "ON"}"
2021-10-31 10:02:08 +00:00
] ++ lib.optionals (cxxStandard != null) [
"-DCMAKE_CXX_STANDARD=${cxxStandard}"
2021-02-13 19:58:22 +00:00
];
nativeBuildInputs = [ cmake ];
meta = with lib; {
description = "An open-source collection of C++ code designed to augment the C++ standard library";
homepage = "https://abseil.io/";
license = licenses.asl20;
platforms = platforms.all;
maintainers = [ maintainers.andersk ];
};
}