diff --git a/CMakeLists.txt b/CMakeLists.txt index 3e8f903c60a64dcd652528c229fd52fdbdbbfd17..f0a789677effe0f53cb3965371a0b48f1c3c9f9d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -150,8 +150,11 @@ get_property(__clingetcpch GLOBAL PROPERTY CLINGETCPCH) string(REGEX REPLACE "[ ]-" ";-" CMAKE_CXX_FLAGS_SEPARATE ${CMAKE_CXX_FLAGS}) if(cxxmodules) - # rootcling doesn't know what to do with these flags. - # FIXME: Disable until until somebody teaches it. + # rootcling uses our internal version of clang. Passing the modules flags here + # would allow rootcling to find module files built by the external compiler + # (eg. $CXX or $CC). This, in turn, would cause problems if we are using + # different clang version (even different commit revision) as the modules files + # are not guaranteed to be compatible among clang revisions. string(REPLACE "${ROOT_CXXMODULES_FLAGS}" "" CMAKE_CXX_FLAGS_SEPARATE ${CMAKE_CXX_FLAGS_SEPARATE}) endif(cxxmodules) add_custom_command(OUTPUT etc/dictpch/allLinkDefs.h diff --git a/Makefile b/Makefile index 29278e9d35e0a181f221c8c870841ec76cf72791..592a2fb1e9bba9a6f12fa0325d571798f5d32bb7 100644 --- a/Makefile +++ b/Makefile @@ -1137,8 +1137,11 @@ changelog: releasenotes: @$(MAKERELNOTES) ROOTCLING_CXXFLAGS := $(CXXFLAGS) -# rootcling doesn't know what to do with these flags. -# FIXME: Disable until until somebody teaches it. +# rootcling uses our internal version of clang. Passing the modules flags here +# would allow rootcling to find module files built by the external compiler +# (eg. $CXX or $CC). This, in turn, would cause problems if we are using +# different clang version (even different commit revision) as the modules files +# are not guaranteed to be compatible among clang revisions. ifeq ($(CXXMODULES),yes) ROOTCLING_CXXFLAGS := $(filter-out $(ROOT_CXXMODULES_CXXFLAGS),$(CXXFLAGS)) endif