diff --git a/CMakeLists.txt b/CMakeLists.txt index b21d70a3e..761b78ef9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -749,16 +749,12 @@ add_subdirectory( "modules" ) add_subdirectory( "scripts" ) # Generate config file -if( CMAKE_SYSTEM_NAME MATCHES "Windows" ) - configure_file( src/tenacity_config.h.in src/private/configwin.h ) -elseif( CMAKE_SYSTEM_NAME MATCHES "Darwin" ) - set( HAVE_VISIBILITY 1 ) - configure_file( src/tenacity_config.h.in src/private/configmac.h ) -else() - set( HAVE_VISIBILITY 1 ) - configure_file( src/tenacity_config.h.in src/private/configunix.h ) +if (NOT CMAKE_SYSTEM_NAME MATCHES "Windows") + set(HAVE_VISIBILITY 1) endif() +configure_file(src/tenacity_config.h.in src/private/config.h) + # Generate a picture of module dependencies string( JOIN "\n" GRAPH_EDGES ${GRAPH_EDGES} ) # Choose edge attributes making it easy to hover at either end of edge diff --git a/cmake-proxies/cmake-modules/TenacityFunctions.cmake b/cmake-proxies/cmake-modules/TenacityFunctions.cmake index ac0de90de..14d64a3d5 100644 --- a/cmake-proxies/cmake-modules/TenacityFunctions.cmake +++ b/cmake-proxies/cmake-modules/TenacityFunctions.cmake @@ -163,9 +163,8 @@ function( tenacity_append_common_compiler_options var use_pch ) PRIVATE # include the correct config file; give absolute path to it, so # that this works whether in src, modules, libraries - $<$:/FI${CMAKE_BINARY_DIR}/src/private/configwin.h> - $<$:-include ${CMAKE_BINARY_DIR}/src/private/configmac.h> - $<$>:-include ${CMAKE_BINARY_DIR}/src/private/configunix.h> + $<$:/FI${CMAKE_BINARY_DIR}/src/private/config.h> + $<$>:-include ${CMAKE_BINARY_DIR}/src/private/config.h> ) endif() list( APPEND ${var} diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 9f9635ad3..c00d26fab 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -1280,9 +1280,7 @@ if( NOT CCACHE_PROGRAM AND NOT SCCACHE_PROGRAM ) if( PCH ) message( STATUS "Using precompiled headers" ) target_precompile_headers( ${TARGET} PRIVATE - $<$:${CMAKE_BINARY_DIR}/src/private/configwin.h> - $<$:${CMAKE_BINARY_DIR}/src/private/configmac.h> - $<$>:${CMAKE_BINARY_DIR}/src/private/configunix.h> + ${CMAKE_BINARY_DIR}/src/private/config.h AudacityHeaders.h ) else()