From 562db4bbf9c6a92c72646ebc5ba998178d58b6ca Mon Sep 17 00:00:00 2001 From: Pulkit Sinha Date: Fri, 29 Nov 2019 13:17:59 -0500 Subject: [PATCH] boost : extra arguments to b2 Certain boost features require compile time flags. For example - https://www.boost.org/doc/libs/1_71_0/libs/test/doc/html/boost_test/adv_scenarios/obsolete_init_func.html https://www.boost.org/doc/libs/1_71_0/libs/test/doc/html/boost_test/utf_reference/link_references/link_boost_test_no_main.html https://www.boost.org/doc/libs/1_71_0/libs/test/doc/html/boost_test/utf_reference/link_references/link_boost_test_dyn_link.html This commit add the ability to specify arbitrary extra arguments to b2's arguments. --- pkgs/development/libraries/boost/generic.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkgs/development/libraries/boost/generic.nix b/pkgs/development/libraries/boost/generic.nix index f7bd189022f8..2d0a5a63d6f7 100644 --- a/pkgs/development/libraries/boost/generic.nix +++ b/pkgs/development/libraries/boost/generic.nix @@ -14,6 +14,7 @@ , taggedLayout ? ((enableRelease && enableDebug) || (enableSingleThreaded && enableMultiThreaded) || (enableShared && enableStatic)) , patches ? [] , mpi ? null +, extraB2Args ? [] # Attributes inherit from specific versions , version, src @@ -92,7 +93,8 @@ let ++ optional (mpi != null || stdenv.hostPlatform != stdenv.buildPlatform) "--user-config=user-config.jam" ++ optionals (stdenv.hostPlatform.libc == "msvcrt") [ "threadapi=win32" - ]); + ] ++ extraB2Args + ); in