Skip to content

Commit

Permalink
cxxopts: set C++ std to 17 to fix building with icu4c-76.1
Browse files Browse the repository at this point in the history
  • Loading branch information
builtbyvys committed Feb 23, 2025
1 parent 7b0e8a5 commit 0e29080
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions pkgs/by-name/cx/cxxopts/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
pkg-config,
enableUnicodeHelp ? true,
}:

stdenv.mkDerivation rec {
pname = "cxxopts";
version = "3.2.1";
Expand All @@ -19,11 +18,14 @@ stdenv.mkDerivation rec {
sha256 = "sha256-aOF3owz7SIV4trJY0PnMtIcwqoUpDbB3tNxZcsl9dzM=";
};

buildInputs = lib.optionals enableUnicodeHelp [ icu74.dev ];
cmakeFlags = [
"-DCXXOPTS_BUILD_EXAMPLES=OFF"
] ++ lib.optional enableUnicodeHelp "-DCXXOPTS_USE_UNICODE_HELP=TRUE";
nativeBuildInputs = [ cmake ] ++ lib.optionals enableUnicodeHelp [ pkg-config ];
buildInputs = lib.optionals enableUnicodeHelp [icu74.dev];
cmakeFlags =
[
"-DCXXOPTS_BUILD_EXAMPLES=OFF"
"-DCMAKE_CXX_STANDARD=17"
]
++ lib.optional enableUnicodeHelp "-DCXXOPTS_USE_UNICODE_HELP=TRUE";
nativeBuildInputs = [cmake] ++ lib.optionals enableUnicodeHelp [pkg-config];

doCheck = true;

Expand All @@ -40,7 +42,7 @@ stdenv.mkDerivation rec {
homepage = "https://github.com/jarro2783/cxxopts";
description = "Lightweight C++ GNU-style option parser library";
license = licenses.mit;
maintainers = [ maintainers.spease ];
maintainers = [maintainers.spease];
platforms = platforms.all;
};
}

0 comments on commit 0e29080

Please sign in to comment.