mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-24 06:31:02 +00:00
abseil-cpp: add cxxStandard input
This commit is contained in:
parent
7053541084
commit
af3444ffc5
|
@ -1,4 +1,4 @@
|
|||
{ lib, stdenv, fetchFromGitHub, fetchpatch, cmake, static ? stdenv.hostPlatform.isStatic }:
|
||||
{ lib, stdenv, fetchFromGitHub, fetchpatch, cmake, static ? stdenv.hostPlatform.isStatic, cxxStandard ? null }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "abseil-cpp";
|
||||
|
@ -21,8 +21,9 @@ stdenv.mkDerivation rec {
|
|||
];
|
||||
|
||||
cmakeFlags = [
|
||||
"-DCMAKE_CXX_STANDARD=17"
|
||||
"-DBUILD_SHARED_LIBS=${if static then "OFF" else "ON"}"
|
||||
] ++ lib.optionals (cxxStandard != null) [
|
||||
"-DCMAKE_CXX_STANDARD=${toString cxxStandard}"
|
||||
];
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
|
|
Loading…
Reference in a new issue