Commit 583bb272 authored by Philipp Schäfer's avatar Philipp Schäfer
Browse files

CMake - TBB: Now overwrite all output directories, also for debug / release

parent d8e29929
......@@ -26,15 +26,31 @@ CPMAddPackage (
if (tbb_ADDED)
set_target_properties (tbb tbbmalloc tbbmalloc_proxy PROPERTIES FOLDER "external_libs")
#TBB sets all output directories for debug/release so we must overwrite them
if (WIN32)
if (CMAKE_PDB_OUTPUT_DIRECTORY)
set( _pdb_dir ${CMAKE_PDB_OUTPUT_DIRECTORY} )
else()
set( _pdb_dir ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} )
endif()
set_target_properties (
tbb tbbmalloc tbbmalloc_proxy PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
)
set_target_properties (
tbb tbbmalloc tbbmalloc_proxy PROPERTIES ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
)
set_target_properties (
tbb tbbmalloc tbbmalloc_proxy PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
tbb tbbmalloc tbbmalloc_proxy PROPERTIES
RUNTIME_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
RUNTIME_OUTPUT_DIRECTORY_DEBUG ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
RUNTIME_OUTPUT_DIRECTORY_RELEASE ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
ARCHIVE_OUTPUT_DIRECTORY_DEBUG ${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
ARCHIVE_OUTPUT_DIRECTORY_RELEASE ${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
LIBRARY_OUTPUT_DIRECTORY_DEBUG ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
LIBRARY_OUTPUT_DIRECTORY_RELEASE ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
PDB_OUTPUT_DIRECTORY ${_pdb_dir}
PDB_OUTPUT_DIRECTORY_DEBUG ${_pdb_dir}
PDB_OUTPUT_DIRECTORY_RELEASE ${_pdb_dir}
)
unset( _pdb_dir )
endif ()
endif ()
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment