CMake: Don't compile PrecompiledHeader.cpp

This commit is contained in:
Stenzek 2023-12-25 01:22:40 +10:00 committed by Connor McLaughlin
parent 4608579c31
commit 59949c50d3
3 changed files with 4 additions and 0 deletions

View File

@ -131,6 +131,8 @@ target_sources(common PRIVATE
Darwin/DarwinMisc.h Darwin/DarwinMisc.h
) )
set_source_files_properties(PrecompiledHeader.cpp PROPERTIES HEADER_FILE_ONLY TRUE)
if(USE_VTUNE) if(USE_VTUNE)
target_link_libraries(common PUBLIC Vtune::Vtune) target_link_libraries(common PUBLIC Vtune::Vtune)
endif() endif()

View File

@ -179,6 +179,7 @@ target_sources(pcsx2-qt PRIVATE
file(GLOB TS_FILES ${CMAKE_CURRENT_SOURCE_DIR}/Translations/*.ts) file(GLOB TS_FILES ${CMAKE_CURRENT_SOURCE_DIR}/Translations/*.ts)
target_precompile_headers(pcsx2-qt PRIVATE PrecompiledHeader.h) target_precompile_headers(pcsx2-qt PRIVATE PrecompiledHeader.h)
set_source_files_properties(PrecompiledHeader.cpp PROPERTIES HEADER_FILE_ONLY TRUE)
target_include_directories(pcsx2-qt PRIVATE target_include_directories(pcsx2-qt PRIVATE
${Qt6Gui_PRIVATE_INCLUDE_DIRS} ${Qt6Gui_PRIVATE_INCLUDE_DIRS}

View File

@ -1188,6 +1188,7 @@ target_compile_definitions(PCSX2_FLAGS INTERFACE
XBYAK_NO_EXCEPTION XBYAK_NO_EXCEPTION
) )
set_source_files_properties(PrecompiledHeader.cpp PROPERTIES HEADER_FILE_ONLY TRUE)
if(COMMAND target_precompile_headers) if(COMMAND target_precompile_headers)
message("Using precompiled headers.") message("Using precompiled headers.")
target_precompile_headers(PCSX2_FLAGS INTERFACE PrecompiledHeader.h) target_precompile_headers(PCSX2_FLAGS INTERFACE PrecompiledHeader.h)