Skip to content

Commit

Permalink
fix inline-treshold compile flag
Browse files Browse the repository at this point in the history
  • Loading branch information
PeterPetrik committed Jun 7, 2021
1 parent 2dabe3f commit c37b6c1
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 8 deletions.
7 changes: 0 additions & 7 deletions CMakeLists.txt
Expand Up @@ -47,13 +47,6 @@ if (APPLE)
if ( QGIS_MAC_DEPS_DIR )
set(ENV{LIB_DIR} ${QGIS_MAC_DEPS_DIR})
list(APPEND CMAKE_PREFIX_PATH ${QGIS_MAC_DEPS_DIR})

# o2/o3 optimization with clang12 uses too much memory
# see https://github.com/qgis/QGIS-Mac-Packager/issues/132
if ( CMAKE_CXX_COMPILER_ID MATCHES "Clang" )
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -fno-inline")
set(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} -fno-inline")
endif()
endif()
endif()

Expand Down
2 changes: 1 addition & 1 deletion src/core/CMakeLists.txt
Expand Up @@ -1698,7 +1698,7 @@ endif()
if(NOT MSVC)
if ("${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang" AND (CMAKE_BUILD_TYPE MATCHES Release OR CMAKE_BUILD_TYPE MATCHES RelWithDebInfo))
set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/qgsexpression_texts.cpp PROPERTIES COMPILE_FLAGS "-O1")
set_source_files_properties(qgscoordinatereferencesystem.cpp PROPERTIES COMPILE_FLAGS "-mllvm -inline-threshold=128")
set_source_files_properties(proj/qgscoordinatereferencesystem.cpp PROPERTIES COMPILE_FLAGS "-mllvm -inline-threshold=128")
endif()
endif()

Expand Down

0 comments on commit c37b6c1

Please sign in to comment.