Skip to content
Snippets Groups Projects
Commit 35505fef authored by Dmitry Popov's avatar Dmitry Popov
Browse files

Merge branch 'use-lhcb-compile-flags' into 'master'

Do not override LHCb compilation flags

Closes #3

See merge request lhcb/Geant4!83
parents 7401a6dd ea32717b
No related branches found
No related tags found
1 merge request!83Do not override LHCb compilation flags
...@@ -21,8 +21,8 @@ cmake_minimum_required(VERSION 3.8 FATAL_ERROR) ...@@ -21,8 +21,8 @@ cmake_minimum_required(VERSION 3.8 FATAL_ERROR)
# - Any policy requirements should go here # - Any policy requirements should go here
# - Make overrides for default flags, so they appear in interfaces # - Make overrides for default flags, so they appear in interfaces
set(CMAKE_USER_MAKE_RULES_OVERRIDE_CXX # set(CMAKE_USER_MAKE_RULES_OVERRIDE_CXX
${CMAKE_SOURCE_DIR}/cmake/Modules/Geant4MakeRules_cxx.cmake) # ${CMAKE_SOURCE_DIR}/cmake/Modules/Geant4MakeRules_cxx.cmake)
#----------------------------------------------------------------------- #-----------------------------------------------------------------------
# - Project definition and basic configuration # - Project definition and basic configuration
...@@ -43,6 +43,25 @@ set(CMAKE_MODULE_PATH ...@@ -43,6 +43,25 @@ set(CMAKE_MODULE_PATH
${PROJECT_SOURCE_DIR}/cmake/Modules ${PROJECT_SOURCE_DIR}/cmake/Modules
${CMAKE_MODULE_PATH}) ${CMAKE_MODULE_PATH})
# FIXME: code copied from cmake/Modules/Geant4MakeRules_cxx.cmake waiting for proper refactoring
if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang|Intel")
# available models, default first
set(_TLSMODELS initial-exec local-exec global-dynamic local-dynamic)
foreach(_s ${_TLSMODELS})
set(${_s}_TLSMODEL_FLAGS "-ftls-model=${_s}")
endforeach()
list(APPEND _TLSMODELS auto)
set(auto_TLSMODEL_FLAGS "")
set(TLSMODEL_IS_AVAILABLE ${_TLSMODELS})
# FIXME: this is not the right way of enabling threads
# (see https://cmake.org/cmake/help/latest/module/FindThreads.html)
set(GEANT4_MULTITHREADED_CXX_FLAGS "-pthread")
endif()
#----------------------------------------------------------------------- #-----------------------------------------------------------------------
# - Include CMake category main module # - Include CMake category main module
# Factored into category for convenience in tagging # Factored into category for convenience in tagging
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment