From b01fde82ba1e70af68ac78607daf421334f60cc7 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Fri, 9 Jun 2017 17:55:06 +0200 Subject: Only enable modules for GCC from the cxx-modules branch --- build2/cxx/init.cxx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/build2/cxx/init.cxx b/build2/cxx/init.cxx index 89c7c11..32ba8b6 100644 --- a/build2/cxx/init.cxx +++ b/build2/cxx/init.cxx @@ -150,12 +150,13 @@ namespace build2 } case compiler_id::gcc: { - // Enable starting with GCC 8.0.0. + // Enable starting with GCC 8.0.0 (currently the c++-modules + // branch). // - if (mj >= 8) + if (mj >= 8 && + ci.version.build.find ("cxx-modules") != string::npos) { r.push_back ("-fmodules"); - //r.push_back ("-D__cpp_modules=201704"); // p0629r0 modules = true; } break; -- cgit v1.1