diff --git a/reactos/base/applications/cacls/CMakeLists.txt b/reactos/base/applications/cacls/CMakeLists.txt index cfb03ed2377..0378017b753 100644 --- a/reactos/base/applications/cacls/CMakeLists.txt +++ b/reactos/base/applications/cacls/CMakeLists.txt @@ -4,11 +4,9 @@ set_rc_compiler() list(APPEND SOURCE cacls.c cacls.rc) -add_executable(cacls - ${CMAKE_CURRENT_BINARY_DIR}/cacls_precomp.h.gch - ${SOURCE}) +add_executable(cacls ${SOURCE}) -add_pch(cacls ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(cacls precomp.h) set_module_type(cacls win32cui) add_importlibs(cacls advapi32 user32 shell32 msvcrt kernel32) diff --git a/reactos/base/applications/charmap/CMakeLists.txt b/reactos/base/applications/charmap/CMakeLists.txt index 5a053c4f042..902952cb935 100644 --- a/reactos/base/applications/charmap/CMakeLists.txt +++ b/reactos/base/applications/charmap/CMakeLists.txt @@ -9,11 +9,9 @@ list(APPEND SOURCE map.c charmap.rc) -add_executable(charmap - ${CMAKE_CURRENT_BINARY_DIR}/charmap_precomp.h.gch - ${SOURCE}) +add_executable(charmap ${SOURCE}) -add_pch(charmap ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(charmap precomp.h) set_module_type(charmap win32gui) diff --git a/reactos/base/applications/dxdiag/CMakeLists.txt b/reactos/base/applications/dxdiag/CMakeLists.txt index d234cc13f6a..bb69ffc702c 100644 --- a/reactos/base/applications/dxdiag/CMakeLists.txt +++ b/reactos/base/applications/dxdiag/CMakeLists.txt @@ -18,11 +18,9 @@ list(APPEND SOURCE d3dtest8.c d3dtest9.c) -add_executable(dxdiag - ${CMAKE_CURRENT_BINARY_DIR}/dxdiag_precomp.h.gch - ${SOURCE}) +add_executable(dxdiag ${SOURCE}) -add_pch(dxdiag ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(dxdiag precomp.h) set_module_type(dxdiag win32gui) diff --git a/reactos/base/applications/logoff/CMakeLists.txt b/reactos/base/applications/logoff/CMakeLists.txt index c560717531a..9a674b7e0d8 100644 --- a/reactos/base/applications/logoff/CMakeLists.txt +++ b/reactos/base/applications/logoff/CMakeLists.txt @@ -6,9 +6,9 @@ list(APPEND SOURCE logoff.c logoff.rc) -add_executable(logoff ${CMAKE_CURRENT_BINARY_DIR}/logoff_precomp.h.gch ${SOURCE}) +add_executable(logoff ${SOURCE}) -add_pch(logoff ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(logoff precomp.h) set_module_type(logoff win32cui) add_importlibs(logoff advapi32 user32 msvcrt kernel32) diff --git a/reactos/base/applications/mmc/CMakeLists.txt b/reactos/base/applications/mmc/CMakeLists.txt index 765cf2e2b3b..07591004998 100644 --- a/reactos/base/applications/mmc/CMakeLists.txt +++ b/reactos/base/applications/mmc/CMakeLists.txt @@ -8,9 +8,9 @@ list(APPEND SOURCE mmc.c mmc.rc) -add_executable(mmcclient ${CMAKE_CURRENT_BINARY_DIR}/mmcclient_precomp.h.gch ${SOURCE}) +add_executable(mmcclient ${SOURCE}) -add_pch(mmcclient ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(mmcclient precomp.h) set_module_type(mmcclient win32gui) add_importlibs(mmcclient user32 gdi32 comdlg32 advapi32 shell32 comctl32 msvcrt kernel32) diff --git a/reactos/base/applications/msconfig/CMakeLists.txt b/reactos/base/applications/msconfig/CMakeLists.txt index cf9c7e0d1ed..c9a2a53acdf 100644 --- a/reactos/base/applications/msconfig/CMakeLists.txt +++ b/reactos/base/applications/msconfig/CMakeLists.txt @@ -12,9 +12,9 @@ list(APPEND SOURCE msconfig.c msconfig.rc) -add_executable(msconfig ${CMAKE_CURRENT_BINARY_DIR}/msconfig_precomp.h.gch ${SOURCE}) +add_executable(msconfig ${SOURCE}) -add_pch(msconfig ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(msconfig precomp.h) set_module_type(msconfig win32gui) add_importlibs(msconfig user32 advapi32 version comctl32 shell32 shlwapi msvcrt kernel32) diff --git a/reactos/base/applications/mscutils/devmgmt/CMakeLists.txt b/reactos/base/applications/mscutils/devmgmt/CMakeLists.txt index 703c0e1dceb..0c8634db637 100644 --- a/reactos/base/applications/mscutils/devmgmt/CMakeLists.txt +++ b/reactos/base/applications/mscutils/devmgmt/CMakeLists.txt @@ -9,9 +9,9 @@ list(APPEND SOURCE misc.c devmgmt.rc) -add_executable(devmgmt ${CMAKE_CURRENT_BINARY_DIR}/devmgmt_precomp.h.gch ${SOURCE}) +add_executable(devmgmt ${SOURCE}) -add_pch(devmgmt ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(devmgmt precomp.h) set_module_type(devmgmt win32gui) add_importlibs(devmgmt setupapi gdi32 user32 comctl32 advapi32 devmgr msvcrt kernel32) diff --git a/reactos/base/applications/mscutils/servman/CMakeLists.txt b/reactos/base/applications/mscutils/servman/CMakeLists.txt index 87bd84b08d1..5836399d331 100644 --- a/reactos/base/applications/mscutils/servman/CMakeLists.txt +++ b/reactos/base/applications/mscutils/servman/CMakeLists.txt @@ -24,9 +24,9 @@ list(APPEND SOURCE stop_dependencies.c servman.rc) -add_executable(servman ${CMAKE_CURRENT_BINARY_DIR}/servman_precomp.h.gch ${SOURCE}) +add_executable(servman ${SOURCE}) -add_pch(servman ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(servman precomp.h) set_module_type(servman win32gui) diff --git a/reactos/base/applications/mstsc/CMakeLists.txt b/reactos/base/applications/mstsc/CMakeLists.txt index ef37c8fd823..06033650ed1 100644 --- a/reactos/base/applications/mstsc/CMakeLists.txt +++ b/reactos/base/applications/mstsc/CMakeLists.txt @@ -23,9 +23,9 @@ list(APPEND SOURCE win32.c rdc.rc) -add_executable(mstsc ${CMAKE_CURRENT_BINARY_DIR}/mstsc_precomp.h.gch ${SOURCE}) +add_executable(mstsc ${SOURCE}) -add_pch(mstsc ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(mstsc precomp.h) set_module_type(mstsc win32gui) diff --git a/reactos/base/applications/notepad/CMakeLists.txt b/reactos/base/applications/notepad/CMakeLists.txt index c59cd26f2bb..3423aa61c05 100644 --- a/reactos/base/applications/notepad/CMakeLists.txt +++ b/reactos/base/applications/notepad/CMakeLists.txt @@ -8,9 +8,9 @@ list(APPEND SOURCE set_rc_compiler() -add_pch(notepad ${CMAKE_CURRENT_SOURCE_DIR}/notepad.h ${SOURCE}) +add_executable(notepad ${SOURCE}) -add_executable(notepad ${CMAKE_CURRENT_BINARY_DIR}/notepad_notepad.h.gch ${SOURCE}) +add_pch(notepad notepad.h) set_module_type(notepad win32gui) add_importlibs(notepad user32 gdi32 comctl32 comdlg32 advapi32 shell32 msvcrt kernel32) diff --git a/reactos/base/applications/regedit/CMakeLists.txt b/reactos/base/applications/regedit/CMakeLists.txt index 4fb1946f698..b7125dd9389 100644 --- a/reactos/base/applications/regedit/CMakeLists.txt +++ b/reactos/base/applications/regedit/CMakeLists.txt @@ -22,9 +22,9 @@ list(APPEND SOURCE treeview.c regedit.rc) -add_pch(regedit ${CMAKE_CURRENT_SOURCE_DIR}/regedit.h ${SOURCE}) +add_executable(regedit ${SOURCE}) -add_executable(regedit ${CMAKE_CURRENT_BINARY_DIR}/regedit_regedit.h.gch ${SOURCE}) +add_pch(regedit regedit.h) set_module_type(regedit win32gui) diff --git a/reactos/base/applications/sc/CMakeLists.txt b/reactos/base/applications/sc/CMakeLists.txt index 0854d5b229c..d16c088c933 100644 --- a/reactos/base/applications/sc/CMakeLists.txt +++ b/reactos/base/applications/sc/CMakeLists.txt @@ -13,9 +13,9 @@ list(APPEND SOURCE usage.c sc.rc) -add_executable(sc ${CMAKE_CURRENT_BINARY_DIR}/sc_sc.h.gch ${SOURCE}) +add_executable(sc ${SOURCE}) -add_pch(sc ${CMAKE_CURRENT_SOURCE_DIR}/sc.h ${SOURCE}) +add_pch(sc sc.h) set_module_type(sc win32cui) add_importlibs(sc advapi32 msvcrt kernel32) diff --git a/reactos/base/applications/shutdown/CMakeLists.txt b/reactos/base/applications/shutdown/CMakeLists.txt index 196d558ce82..641904671ad 100644 --- a/reactos/base/applications/shutdown/CMakeLists.txt +++ b/reactos/base/applications/shutdown/CMakeLists.txt @@ -6,9 +6,9 @@ list(APPEND SOURCE shutdown.c shutdown.rc) -add_executable(shutdown ${CMAKE_CURRENT_BINARY_DIR}/shutdown_precomp.h.gch ${SOURCE}) +add_executable(shutdown ${SOURCE}) -add_pch(shutdown ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(shutdown precomp.h) set_module_type(shutdown win32cui) add_importlibs(shutdown advapi32 user32 msvcrt kernel32) diff --git a/reactos/base/applications/sndvol32/CMakeLists.txt b/reactos/base/applications/sndvol32/CMakeLists.txt index 9208072f08e..bcd79cbea49 100644 --- a/reactos/base/applications/sndvol32/CMakeLists.txt +++ b/reactos/base/applications/sndvol32/CMakeLists.txt @@ -10,9 +10,9 @@ list(APPEND SOURCE sndvol32.c sndvol32.rc) -add_executable(sndvol32 ${CMAKE_CURRENT_BINARY_DIR}/sndvol32_sndvol32.h.gch ${SOURCE}) +add_executable(sndvol32 ${SOURCE}) -add_pch(sndvol32 ${CMAKE_CURRENT_SOURCE_DIR}/sndvol32.h ${SOURCE}) +add_pch(sndvol32 sndvol32.h) set_module_type(sndvol32 win32gui) add_importlibs(sndvol32 user32 advapi32 gdi32 comctl32 shell32 winmm msvcrt kernel32 ntdll) diff --git a/reactos/base/applications/taskmgr/CMakeLists.txt b/reactos/base/applications/taskmgr/CMakeLists.txt index b36860362e5..6654f1098f2 100644 --- a/reactos/base/applications/taskmgr/CMakeLists.txt +++ b/reactos/base/applications/taskmgr/CMakeLists.txt @@ -23,9 +23,9 @@ list(APPEND SOURCE graphctl.c taskmgr.rc) -add_executable(taskmgr ${CMAKE_CURRENT_BINARY_DIR}/taskmgr_precomp.h.gch ${SOURCE}) +add_executable(taskmgr ${SOURCE}) -add_pch(taskmgr ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(taskmgr precomp.h) set_module_type(taskmgr win32gui) add_importlibs(taskmgr advapi32 user32 gdi32 shell32 comctl32 msvcrt kernel32 ntdll) diff --git a/reactos/base/services/eventlog/CMakeLists.txt b/reactos/base/services/eventlog/CMakeLists.txt index 424606205c4..9c864a42257 100644 --- a/reactos/base/services/eventlog/CMakeLists.txt +++ b/reactos/base/services/eventlog/CMakeLists.txt @@ -11,11 +11,11 @@ list(APPEND SOURCE rpc.c file.c) -add_executable(eventlog ${CMAKE_CURRENT_BINARY_DIR}/eventlog_eventlog.h.gch ${SOURCE}) +add_executable(eventlog ${SOURCE}) target_link_libraries(eventlog eventlogrpc ${PSEH_LIB}) -add_pch(eventlog ${CMAKE_CURRENT_SOURCE_DIR}/eventlog.h ${SOURCE}) +add_pch(eventlog eventlog.h) set_module_type(eventlog win32cui) add_importlibs(eventlog advapi32 rpcrt4 msvcrt kernel32 ntdll) diff --git a/reactos/base/services/tcpsvcs/CMakeLists.txt b/reactos/base/services/tcpsvcs/CMakeLists.txt index 02439ab483a..695c2e8112b 100644 --- a/reactos/base/services/tcpsvcs/CMakeLists.txt +++ b/reactos/base/services/tcpsvcs/CMakeLists.txt @@ -12,9 +12,9 @@ list(APPEND SOURCE tcpsvcs.rc log.c) -add_executable(tcpsvcs ${CMAKE_CURRENT_BINARY_DIR}/tcpsvcs_tcpsvcs.h.gch ${SOURCE}) +add_executable(tcpsvcs ${SOURCE}) -add_pch(tcpsvcs ${CMAKE_CURRENT_SOURCE_DIR}/tcpsvcs.h ${SOURCE}) +add_pch(tcpsvcs tcpsvcs.h) set_module_type(tcpsvcs win32cui) add_importlibs(tcpsvcs ws2_32 advapi32 msvcrt kernel32 ntdll) diff --git a/reactos/base/shell/cmd/CMakeLists.txt b/reactos/base/shell/cmd/CMakeLists.txt index 855d5fa458a..1242e670843 100644 --- a/reactos/base/shell/cmd/CMakeLists.txt +++ b/reactos/base/shell/cmd/CMakeLists.txt @@ -72,11 +72,11 @@ list(APPEND SOURCE where.c window.c) -add_executable(cmd ${CMAKE_CURRENT_BINARY_DIR}/cmd_precomp.h.gch ${SOURCE}) +add_executable(cmd ${SOURCE}) target_link_libraries(cmd wine) -add_pch(cmd ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h SOURCE) +add_pch(cmd precomp.h) set_module_type(cmd win32cui) add_importlibs(cmd advapi32 user32 msvcrt kernel32 ntdll) add_cd_file(TARGET cmd DESTINATION reactos/system32 FOR all) diff --git a/reactos/base/shell/explorer-new/CMakeLists.txt b/reactos/base/shell/explorer-new/CMakeLists.txt index 6066f89dc5a..eacd9fe6d51 100644 --- a/reactos/base/shell/explorer-new/CMakeLists.txt +++ b/reactos/base/shell/explorer-new/CMakeLists.txt @@ -18,11 +18,11 @@ list(APPEND SOURCE traywnd.c explorer.rc) -add_executable(explorer_new ${CMAKE_CURRENT_BINARY_DIR}/explorer_new_precomp.h.gch ${SOURCE}) +add_executable(explorer_new ${SOURCE}) target_link_libraries(explorer_new uuid) -add_pch(explorer_new ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(explorer_new precomp.h) set_module_type(explorer_new win32gui) add_importlibs(explorer_new advapi32 diff --git a/reactos/base/shell/explorer/CMakeLists.txt b/reactos/base/shell/explorer/CMakeLists.txt index 3cf6006f382..ded70541558 100644 --- a/reactos/base/shell/explorer/CMakeLists.txt +++ b/reactos/base/shell/explorer/CMakeLists.txt @@ -13,7 +13,7 @@ add_definitions( -D__WINDRES__ -D_DLL -D__USE_CRTIMP) -#add_pch(explorer ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h SOURCE) +#add_pch(explorer precomp.h) include_directories(${CMAKE_CURRENT_SOURCE_DIR}) list(APPEND SOURCE @@ -53,7 +53,7 @@ list(APPEND SOURCE utility/window.cpp utility/shellbrowserimpl.cpp) # utility/shelltests.cpp -add_executable(explorer ${SOURCE}) #${CMAKE_CURRENT_BINARY_DIR}/explorer_precomp.h.gch ${SOURCE}) +add_executable(explorer ${SOURCE}) set_subsystem(explorer windows) set_entrypoint(explorer WinMainCRTStartup) diff --git a/reactos/base/system/services/CMakeLists.txt b/reactos/base/system/services/CMakeLists.txt index 5384849da3c..5c7204b74f2 100644 --- a/reactos/base/system/services/CMakeLists.txt +++ b/reactos/base/system/services/CMakeLists.txt @@ -14,13 +14,13 @@ list(APPEND SOURCE services.c services.rc) -add_executable(services ${CMAKE_CURRENT_BINARY_DIR}/services_services.h.gch ${SOURCE}) +add_executable(services ${SOURCE}) target_link_libraries(services svcctlrpc ${PSEH_LIB}) -add_pch(services ${CMAKE_CURRENT_SOURCE_DIR}/services.h ${SOURCE}) +add_pch(services services.h) set_module_type(services win32cui) add_importlibs(services user32 advapi32 rpcrt4 msvcrt kernel32 ntdll) diff --git a/reactos/base/system/smss/CMakeLists.txt b/reactos/base/system/smss/CMakeLists.txt index d6c7b99873b..8a44d25e91e 100644 --- a/reactos/base/system/smss/CMakeLists.txt +++ b/reactos/base/system/smss/CMakeLists.txt @@ -23,7 +23,7 @@ list(APPEND SOURCE smss.c smss.rc) -add_executable(smss WIN32 ${CMAKE_CURRENT_BINARY_DIR}/smss_smss.h.gch ${SOURCE}) +add_executable(smss WIN32 ${SOURCE}) target_link_libraries(smss nt smlib) if(MSVC) @@ -31,7 +31,7 @@ if(MSVC) set_entrypoint(smss DllMainCRTStartup) endif() -add_pch(smss ${CMAKE_CURRENT_SOURCE_DIR}/smss.h ${SOURCE}) +add_pch(smss smss.h) set_module_type(smss nativecui) add_importlibs(smss ntdll) diff --git a/reactos/base/system/winlogon/CMakeLists.txt b/reactos/base/system/winlogon/CMakeLists.txt index 945de9935fa..e83182d106f 100644 --- a/reactos/base/system/winlogon/CMakeLists.txt +++ b/reactos/base/system/winlogon/CMakeLists.txt @@ -8,11 +8,11 @@ list(APPEND SOURCE wlx.c winlogon.rc) -add_executable(winlogon ${CMAKE_CURRENT_BINARY_DIR}/winlogon_winlogon.h.gch ${SOURCE}) +add_executable(winlogon ${SOURCE}) target_link_libraries(winlogon wine) -add_pch(winlogon ${CMAKE_CURRENT_SOURCE_DIR}/winlogon.h ${SOURCE}) +add_pch(winlogon winlogon.h) set_module_type(winlogon win32gui) add_importlibs(winlogon user32 advapi32 userenv secur32 msvcrt kernel32 ntdll) diff --git a/reactos/boot/freeldr/freeldr/CMakeLists.txt b/reactos/boot/freeldr/freeldr/CMakeLists.txt index a231c69e032..87902b5c38d 100644 --- a/reactos/boot/freeldr/freeldr/CMakeLists.txt +++ b/reactos/boot/freeldr/freeldr/CMakeLists.txt @@ -163,9 +163,7 @@ list(APPEND FREELDR_SOURCE ${FREELDR_BASE_SOURCE} ) -add_library(freeldr SHARED - ${CMAKE_CURRENT_BINARY_DIR}/freeldr_freeldr.h.gch - ${FREELDR_SOURCE}) +add_library(freeldr SHARED ${FREELDR_SOURCE}) if(NOT MSVC) set_target_properties(freeldr PROPERTIES LINK_FLAGS "-Wl,--strip-all -Wl,--exclude-all-symbols -Wl,--file-alignment,0x1000 -Wl,-T,${CMAKE_CURRENT_SOURCE_DIR}/freeldr_i386.lnk" SUFFIX ".sys") @@ -190,7 +188,7 @@ target_link_libraries(freeldr rtl libcntpr) -add_pch(freeldr ${CMAKE_CURRENT_SOURCE_DIR}/include/freeldr.h ${FREELDR_SOURCE}) +add_pch(freeldr include/freeldr.h) add_dependencies(freeldr asm) add_cd_file(TARGET freeldr DESTINATION loader NO_CAB FOR all) diff --git a/reactos/configure.cmd b/reactos/configure.cmd index f93b74ab14e..7a6db7f6977 100755 --- a/reactos/configure.cmd +++ b/reactos/configure.cmd @@ -116,7 +116,7 @@ if EXIST CMakeCache.txt ( ) if "%BUILD_ENVIRONMENT%" == "MinGW" ( - cmake -G "MinGW Makefiles" -DCMAKE_TOOLCHAIN_FILE=toolchain-mingw32.cmake -DARCH=%ARCH% -DREACTOS_BUILD_TOOLS_DIR:DIR="%REACTOS_BUILD_TOOLS_DIR%" %REACTOS_SOURCE_DIR% + cmake -G "MinGW Makefiles" -DCMAKE_TOOLCHAIN_FILE=toolchain-mingw32.cmake -DARCH=%ARCH% -DREACTOS_BUILD_TOOLS_DIR:DIR="%REACTOS_BUILD_TOOLS_DIR%" %REACTOS_SOURCE_DIR% -DENABLE_CCACHE=1 ) else if defined USE_NMAKE ( cmake -G "NMake Makefiles" -DCMAKE_TOOLCHAIN_FILE=toolchain-msvc.cmake -DARCH=%ARCH% -DREACTOS_BUILD_TOOLS_DIR:DIR="%REACTOS_BUILD_TOOLS_DIR%" %REACTOS_SOURCE_DIR% ) else if "%BUILD_ENVIRONMENT%" == "VS8" ( diff --git a/reactos/dll/cpl/console/CMakeLists.txt b/reactos/dll/cpl/console/CMakeLists.txt index a16f09aedb4..56a66ca628a 100644 --- a/reactos/dll/cpl/console/CMakeLists.txt +++ b/reactos/dll/cpl/console/CMakeLists.txt @@ -12,7 +12,7 @@ list(APPEND SOURCE console.rc ${CMAKE_CURRENT_BINARY_DIR}/console.def) -add_library(console SHARED ${CMAKE_CURRENT_BINARY_DIR}/console_console.h.gch ${SOURCE}) +add_library(console SHARED ${SOURCE}) set_module_type(console win32dll) @@ -23,5 +23,5 @@ add_importlibs(console comctl32 kernel32) -add_pch(console ${CMAKE_CURRENT_SOURCE_DIR}/console.h ${SOURCE}) +add_pch(console console.h) add_cd_file(TARGET console DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/cpl/sysdm/CMakeLists.txt b/reactos/dll/cpl/sysdm/CMakeLists.txt index 14c585c0044..fb98ed6fa25 100644 --- a/reactos/dll/cpl/sysdm/CMakeLists.txt +++ b/reactos/dll/cpl/sysdm/CMakeLists.txt @@ -18,7 +18,7 @@ list(APPEND SOURCE sysdm.rc ${CMAKE_CURRENT_BINARY_DIR}/sysdm.def) -add_library(sysdm SHARED ${CMAKE_CURRENT_BINARY_DIR}/sysdm_precomp.h.gch ${SOURCE}) +add_library(sysdm SHARED ${SOURCE}) set_module_type(sysdm cpl) @@ -37,5 +37,5 @@ add_importlibs(sysdm kernel32 ntdll) -add_pch(sysdm ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(sysdm precomp.h) add_cd_file(TARGET sysdm DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/ntdll/CMakeLists.txt b/reactos/dll/ntdll/CMakeLists.txt index 31090630436..a2b2c9da239 100644 --- a/reactos/dll/ntdll/CMakeLists.txt +++ b/reactos/dll/ntdll/CMakeLists.txt @@ -37,9 +37,7 @@ else() list(APPEND SOURCE dispatch/dispatch.c) endif(ARCH MATCHES i386) -add_library(ntdll SHARED - ${CMAKE_CURRENT_BINARY_DIR}/ntdll_ntdll.h.gch - ${SOURCE}) +add_library(ntdll SHARED ${SOURCE}) set_entrypoint(ntdll 0) @@ -55,7 +53,7 @@ target_link_libraries(ntdll ${PSEH_LIB}) set_image_base(ntdll ${baseaddress_ntdll}) -add_pch(ntdll ${CMAKE_CURRENT_SOURCE_DIR}/include/ntdll.h ${SOURCE}) +add_pch(ntdll include/ntdll.h) add_dependencies(ntdll ntstatus asm) add_cd_file(TARGET ntdll DESTINATION reactos/system32 NO_CAB FOR all) diff --git a/reactos/dll/shellext/deskadp/CMakeLists.txt b/reactos/dll/shellext/deskadp/CMakeLists.txt index 23306b9a197..05ec5af81bf 100644 --- a/reactos/dll/shellext/deskadp/CMakeLists.txt +++ b/reactos/dll/shellext/deskadp/CMakeLists.txt @@ -9,7 +9,7 @@ list(APPEND SOURCE deskadp.rc ${CMAKE_CURRENT_BINARY_DIR}/deskadp.def) -add_library(deskadp SHARED ${CMAKE_CURRENT_BINARY_DIR}/deskadp_precomp.h.gch ${SOURCE}) +add_library(deskadp SHARED ${SOURCE}) set_module_type(deskadp win32dll) @@ -24,6 +24,6 @@ add_importlibs(deskadp kernel32 ntdll) -add_pch(deskadp ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(deskadp precomp.h) add_cd_file(TARGET deskadp DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/shellext/deskmon/CMakeLists.txt b/reactos/dll/shellext/deskmon/CMakeLists.txt index c03afabbc07..9f358bc90f5 100644 --- a/reactos/dll/shellext/deskmon/CMakeLists.txt +++ b/reactos/dll/shellext/deskmon/CMakeLists.txt @@ -10,7 +10,7 @@ list(APPEND SOURCE deskmon.rc ${CMAKE_CURRENT_BINARY_DIR}/deskmon.def) -add_library(deskmon SHARED ${CMAKE_CURRENT_BINARY_DIR}/deskmon_precomp.h.gch ${SOURCE}) +add_library(deskmon SHARED ${SOURCE}) set_module_type(deskmon win32dll) @@ -25,6 +25,6 @@ add_importlibs(deskmon kernel32 ntdll) -add_pch(deskmon ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(deskmon precomp.h) add_cd_file(TARGET deskmon DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/shellext/slayer/CMakeLists.txt b/reactos/dll/shellext/slayer/CMakeLists.txt index 5830f4649a0..8c7d92a9d16 100644 --- a/reactos/dll/shellext/slayer/CMakeLists.txt +++ b/reactos/dll/shellext/slayer/CMakeLists.txt @@ -9,7 +9,7 @@ list(APPEND SOURCE slayer.rc ${CMAKE_CURRENT_BINARY_DIR}/slayer.def) -add_library(slayer SHARED ${CMAKE_CURRENT_BINARY_DIR}/slayer_precomp.h.gch ${SOURCE}) +add_library(slayer SHARED ${SOURCE}) set_module_type(slayer win32dll) @@ -25,6 +25,6 @@ add_importlibs(slayer kernel32 ntdll) -add_pch(slayer ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(slayer precomp.h) add_cd_file(TARGET slayer DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/aclui/CMakeLists.txt b/reactos/dll/win32/aclui/CMakeLists.txt index c41fcc3d89c..41f8009a3bb 100644 --- a/reactos/dll/win32/aclui/CMakeLists.txt +++ b/reactos/dll/win32/aclui/CMakeLists.txt @@ -14,9 +14,7 @@ list(APPEND SOURCE aclui.rc ${CMAKE_CURRENT_BINARY_DIR}/aclui.def) -add_library(aclui SHARED - ${CMAKE_CURRENT_BINARY_DIR}/aclui_precomp.h.gch - ${SOURCE}) +add_library(aclui SHARED ${SOURCE}) set_module_type(aclui win32dll) @@ -24,6 +22,6 @@ add_importlib_target(aclui.spec) add_importlibs(aclui user32 gdi32 comctl32 ole32 oleaut32 advapi32 uxtheme msvcrt kernel32 ntdll) -add_pch(aclui ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(aclui precomp.h) add_cd_file(TARGET aclui DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/advapi32/CMakeLists.txt b/reactos/dll/win32/advapi32/CMakeLists.txt index 114b75f0b2f..d250c718559 100644 --- a/reactos/dll/win32/advapi32/CMakeLists.txt +++ b/reactos/dll/win32/advapi32/CMakeLists.txt @@ -45,9 +45,7 @@ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/advapi32_stubs.c ${CMAKE_CURRENT_BINARY_DIR}/advapi32.def) -add_library(advapi32 SHARED - ${CMAKE_CURRENT_BINARY_DIR}/advapi32_advapi32.h.gch - ${SOURCE}) +add_library(advapi32 SHARED ${SOURCE}) set_module_type(advapi32 win32dll) @@ -60,6 +58,6 @@ target_link_libraries(advapi32 add_importlibs(advapi32 rpcrt4 kernel32 ntdll msvcrt) -add_pch(advapi32 ${CMAKE_CURRENT_SOURCE_DIR}/advapi32.h ${SOURCE}) +add_pch(advapi32 advapi32.h) add_cd_file(TARGET advapi32 DESTINATION reactos/system32 FOR all) add_importlib_target(advapi32.spec) diff --git a/reactos/dll/win32/authz/CMakeLists.txt b/reactos/dll/win32/authz/CMakeLists.txt index bb652abec05..9a677f218ad 100644 --- a/reactos/dll/win32/authz/CMakeLists.txt +++ b/reactos/dll/win32/authz/CMakeLists.txt @@ -11,13 +11,11 @@ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/authz_stubs.c ${CMAKE_CURRENT_BINARY_DIR}/authz.def) -add_library(authz SHARED - ${CMAKE_CURRENT_BINARY_DIR}/authz_precomp.h.gch - ${SOURCE}) +add_library(authz SHARED ${SOURCE}) set_module_type(authz win32dll) -add_pch(authz ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(authz precomp.h) add_importlibs(authz advapi32 msvcrt kernel32 ntdll) add_cd_file(TARGET authz DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/crtdll/CMakeLists.txt b/reactos/dll/win32/crtdll/CMakeLists.txt index f81cb48dc2f..26fffe761ec 100644 --- a/reactos/dll/win32/crtdll/CMakeLists.txt +++ b/reactos/dll/win32/crtdll/CMakeLists.txt @@ -17,9 +17,7 @@ list(APPEND SOURCE crtdll.rc ${CMAKE_CURRENT_BINARY_DIR}/crtdll.def) -add_library(crtdll SHARED - ${CMAKE_CURRENT_BINARY_DIR}/crtdll_precomp.h.gch - ${SOURCE}) +add_library(crtdll SHARED ${SOURCE}) set_module_type(crtdll win32dll) @@ -30,6 +28,6 @@ target_link_libraries(crtdll crt) add_importlibs(crtdll kernel32 ntdll) -add_pch(crtdll ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(crtdll precomp.h) add_cd_file(TARGET crtdll DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/devmgr/CMakeLists.txt b/reactos/dll/win32/devmgr/CMakeLists.txt index 024f8df3f2a..07959c66ad5 100644 --- a/reactos/dll/win32/devmgr/CMakeLists.txt +++ b/reactos/dll/win32/devmgr/CMakeLists.txt @@ -14,7 +14,7 @@ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/devmgr_stubs.c ${CMAKE_CURRENT_BINARY_DIR}/devmgr.def) -add_library(devmgr SHARED ${CMAKE_CURRENT_BINARY_DIR}/devmgr_precomp.h.gch ${SOURCE}) +add_library(devmgr SHARED ${SOURCE}) set_module_type(devmgr win32dll) @@ -29,7 +29,7 @@ add_importlibs(devmgr kernel32 ntdll) -add_pch(devmgr ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(devmgr precomp.h) add_cd_file(TARGET devmgr DESTINATION reactos/system32 FOR all) add_importlib_target(devmgr.spec) diff --git a/reactos/dll/win32/dhcpcsvc/CMakeLists.txt b/reactos/dll/win32/dhcpcsvc/CMakeLists.txt index 1d2323ab522..f82c89cdfc8 100644 --- a/reactos/dll/win32/dhcpcsvc/CMakeLists.txt +++ b/reactos/dll/win32/dhcpcsvc/CMakeLists.txt @@ -23,15 +23,13 @@ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/dhcpcsvc_stubs.c ${CMAKE_CURRENT_BINARY_DIR}/dhcpcsvc.def) -add_library(dhcpcsvc SHARED - ${CMAKE_CURRENT_BINARY_DIR}/dhcpcsvc_rosdhcp.h.gch - ${SOURCE}) +add_library(dhcpcsvc SHARED ${SOURCE}) set_module_type(dhcpcsvc win32dll) add_importlibs(dhcpcsvc ws2_32 iphlpapi advapi32 msvcrt kernel32 ntdll) add_importlib_target(dhcpcsvc.spec) -add_pch(dhcpcsvc ${CMAKE_CURRENT_SOURCE_DIR}/include/rosdhcp.h ${SOURCE}) +add_pch(dhcpcsvc include/rosdhcp.h) add_cd_file(TARGET dhcpcsvc DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/dnsapi/CMakeLists.txt b/reactos/dll/win32/dnsapi/CMakeLists.txt index 42141bdeee5..ffeea959187 100644 --- a/reactos/dll/win32/dnsapi/CMakeLists.txt +++ b/reactos/dll/win32/dnsapi/CMakeLists.txt @@ -21,15 +21,13 @@ list(APPEND SOURCE dnsapi.rc ${CMAKE_CURRENT_BINARY_DIR}/dnsapi.def) -add_library(dnsapi SHARED - ${CMAKE_CURRENT_BINARY_DIR}/dnsapi_precomp.h.gch - ${SOURCE}) +add_library(dnsapi SHARED ${SOURCE}) set_entrypoint(dnsapi 0) target_link_libraries(dnsapi adns) add_importlibs(dnsapi user32 ws2_32 iphlpapi msvcrt kernel32 ntdll) -add_pch(dnsapi ${CMAKE_CURRENT_SOURCE_DIR}/dnsapi/precomp.h ${SOURCE}) +add_pch(dnsapi dnsapi/precomp.h) add_dependencies(dnsapi psdk) add_cd_file(TARGET dnsapi DESTINATION reactos/system32 FOR all) add_importlib_target(dnsapi.spec) diff --git a/reactos/dll/win32/fmifs/CMakeLists.txt b/reactos/dll/win32/fmifs/CMakeLists.txt index 6595fcaf519..8773f74176b 100644 --- a/reactos/dll/win32/fmifs/CMakeLists.txt +++ b/reactos/dll/win32/fmifs/CMakeLists.txt @@ -14,8 +14,9 @@ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/fmifs_stubs.c ${CMAKE_CURRENT_BINARY_DIR}/fmifs.def) -add_pch(fmifs ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) -add_library(fmifs SHARED ${CMAKE_CURRENT_BINARY_DIR}/fmifs_precomp.h.gch ${SOURCE}) +add_library(fmifs SHARED ${SOURCE}) + +add_pch(fmifs precomp.h) set_entrypoint(fmifs InitializeFmIfs@12) diff --git a/reactos/dll/win32/gdi32/CMakeLists.txt b/reactos/dll/win32/gdi32/CMakeLists.txt index 3f679a14dfa..bf11f6a9419 100644 --- a/reactos/dll/win32/gdi32/CMakeLists.txt +++ b/reactos/dll/win32/gdi32/CMakeLists.txt @@ -47,9 +47,7 @@ list(APPEND SOURCE gdi32.rc ${CMAKE_CURRENT_BINARY_DIR}/gdi32.def) -add_library(gdi32 SHARED - ${CMAKE_CURRENT_BINARY_DIR}/gdi32_precomp.h.gch - ${SOURCE}) +add_library(gdi32 SHARED ${SOURCE}) set_module_type(gdi32 win32dll) @@ -59,6 +57,6 @@ target_link_libraries(gdi32 ${PSEH_LIB}) add_importlibs(gdi32 user32 advapi32 msvcrt kernel32 ntdll) -add_pch(gdi32 ${CMAKE_CURRENT_SOURCE_DIR}/include/precomp.h ${SOURCE}) +add_pch(gdi32 include/precomp.h) add_cd_file(TARGET gdi32 DESTINATION reactos/system32 FOR all) add_importlib_target(gdi32.spec) diff --git a/reactos/dll/win32/hid/CMakeLists.txt b/reactos/dll/win32/hid/CMakeLists.txt index 646fe86a22a..0a32561b58d 100644 --- a/reactos/dll/win32/hid/CMakeLists.txt +++ b/reactos/dll/win32/hid/CMakeLists.txt @@ -9,12 +9,10 @@ list(APPEND SOURCE spec2def(hid.dll hid.spec) -add_library(hid SHARED - ${CMAKE_CURRENT_BINARY_DIR}/hid_precomp.h.gch - ${SOURCE}) +add_library(hid SHARED ${SOURCE}) set_module_type(hid win32dll) add_importlibs(hid msvcrt kernel32 ntdll) -add_pch(hid ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(hid precomp.h) add_cd_file(TARGET hid DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/imagehlp/CMakeLists.txt b/reactos/dll/win32/imagehlp/CMakeLists.txt index d14eed603e5..157f91d5923 100644 --- a/reactos/dll/win32/imagehlp/CMakeLists.txt +++ b/reactos/dll/win32/imagehlp/CMakeLists.txt @@ -16,9 +16,7 @@ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/imagehlp_stubs.c ${CMAKE_CURRENT_BINARY_DIR}/imagehlp.def) -add_library(imagehlp SHARED - ${CMAKE_CURRENT_BINARY_DIR}/imagehlp_precomp.h.gch - ${SOURCE}) +add_library(imagehlp SHARED ${SOURCE}) set_module_type(imagehlp win32dll) @@ -27,6 +25,6 @@ target_link_libraries(imagehlp wine) add_importlibs(imagehlp dbghelp msvcrt kernel32 ntdll) add_importlib_target(imagehlp.spec) -add_pch(imagehlp ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(imagehlp precomp.h) add_cd_file(TARGET imagehlp DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/kernel32/CMakeLists.txt b/reactos/dll/win32/kernel32/CMakeLists.txt index e94f5134b7d..59d1b76359e 100644 --- a/reactos/dll/win32/kernel32/CMakeLists.txt +++ b/reactos/dll/win32/kernel32/CMakeLists.txt @@ -109,9 +109,7 @@ list(APPEND SOURCE thread/amd64/thread.S) endif(ARCH MATCHES i386) -add_library(kernel32 SHARED - ${CMAKE_CURRENT_BINARY_DIR}/kernel32_k32.h.gch - ${SOURCE}) +add_library(kernel32 SHARED ${SOURCE}) set_entrypoint(kernel32 DllMain@12) set_image_base(kernel32 ${baseaddress_kernel32}) @@ -119,7 +117,7 @@ set_image_base(kernel32 ${baseaddress_kernel32}) target_link_libraries(kernel32 ${PSEH_LIB}) add_importlibs(kernel32 ntdll) -add_pch(kernel32 ${CMAKE_CURRENT_SOURCE_DIR}/k32.h ${SOURCE}) +add_pch(kernel32 k32.h) add_dependencies(kernel32 psdk errcodes asm) add_cd_file(TARGET kernel32 DESTINATION reactos/system32 FOR all) add_importlib_target(kernel32.spec) diff --git a/reactos/dll/win32/msafd/CMakeLists.txt b/reactos/dll/win32/msafd/CMakeLists.txt index 7b87ac897a2..0b90e582447 100644 --- a/reactos/dll/win32/msafd/CMakeLists.txt +++ b/reactos/dll/win32/msafd/CMakeLists.txt @@ -16,13 +16,11 @@ list(APPEND SOURCE misc/stubs.c ${CMAKE_CURRENT_BINARY_DIR}/msafd.def) -add_library(msafd SHARED - ${CMAKE_CURRENT_BINARY_DIR}/msafd_msafd.h.gch - ${SOURCE}) +add_library(msafd SHARED ${SOURCE}) set_module_type(msafd win32dll) -add_pch(msafd ${CMAKE_CURRENT_SOURCE_DIR}/msafd.h ${SOURCE}) +add_pch(msafd msafd.h) add_importlibs(msafd advapi32 msvcrt kernel32 ntdll) add_cd_file(TARGET msafd DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/msvcrt/CMakeLists.txt b/reactos/dll/win32/msvcrt/CMakeLists.txt index 3cf63aa2234..6e614730c78 100644 --- a/reactos/dll/win32/msvcrt/CMakeLists.txt +++ b/reactos/dll/win32/msvcrt/CMakeLists.txt @@ -21,9 +21,7 @@ list(APPEND SOURCE msvcrt.rc ${CMAKE_CURRENT_BINARY_DIR}/msvcrt.def) -add_library(msvcrt SHARED - ${CMAKE_CURRENT_BINARY_DIR}/msvcrt_precomp.h.gch - ${SOURCE}) +add_library(msvcrt SHARED ${SOURCE}) if (NOT MSVC) set_target_properties(msvcrt PROPERTIES LINK_FLAGS "-u __seh_longjmp_unwind@4") @@ -38,7 +36,7 @@ target_link_libraries(msvcrt wine ${PSEH_LIB}) -add_pch(msvcrt ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(msvcrt precomp.h) add_importlibs(msvcrt kernel32 ntdll) add_cd_file(TARGET msvcrt DESTINATION reactos/system32 FOR all) add_importlib_target(msvcrt.spec) diff --git a/reactos/dll/win32/netshell/CMakeLists.txt b/reactos/dll/win32/netshell/CMakeLists.txt index 5e2890505bd..9dc74cc503f 100644 --- a/reactos/dll/win32/netshell/CMakeLists.txt +++ b/reactos/dll/win32/netshell/CMakeLists.txt @@ -17,9 +17,7 @@ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/netshell_stubs.c ${CMAKE_CURRENT_BINARY_DIR}/netshell.def) -add_library(netshell SHARED - ${CMAKE_CURRENT_BINARY_DIR}/netshell_precomp.h.gch - ${SOURCE}) +add_library(netshell SHARED ${SOURCE}) set_module_type(netshell win32dll) @@ -42,6 +40,6 @@ add_importlibs(netshell kernel32 ntdll) -add_pch(netshell ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(netshell precomp.h) add_cd_file(TARGET netshell DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/opengl32/CMakeLists.txt b/reactos/dll/win32/opengl32/CMakeLists.txt index a395c5afd7d..5b98cdc1aca 100644 --- a/reactos/dll/win32/opengl32/CMakeLists.txt +++ b/reactos/dll/win32/opengl32/CMakeLists.txt @@ -13,9 +13,7 @@ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/opengl32_stubs.c ${CMAKE_CURRENT_BINARY_DIR}/opengl32.def) -add_library(opengl32 SHARED - ${CMAKE_CURRENT_BINARY_DIR}/opengl32_opengl32.h.gch - ${SOURCE}) +add_library(opengl32 SHARED ${SOURCE}) set_module_type(opengl32 win32dll) @@ -28,7 +26,7 @@ add_importlibs(opengl32 kernel32 ntdll) -add_pch(opengl32 ${CMAKE_CURRENT_SOURCE_DIR}/opengl32.h ${SOURCE}) +add_pch(opengl32 opengl32.h) add_cd_file(TARGET opengl32 DESTINATION reactos/system32 FOR all) add_importlib_target(opengl32.spec) diff --git a/reactos/dll/win32/psapi/CMakeLists.txt b/reactos/dll/win32/psapi/CMakeLists.txt index f0666f0210f..dda730acbd0 100644 --- a/reactos/dll/win32/psapi/CMakeLists.txt +++ b/reactos/dll/win32/psapi/CMakeLists.txt @@ -7,13 +7,11 @@ list(APPEND SOURCE psapi.rc ${CMAKE_CURRENT_BINARY_DIR}/psapi.def) -add_library(psapi SHARED - ${CMAKE_CURRENT_BINARY_DIR}/psapi_precomp.h.gch - ${SOURCE}) +add_library(psapi SHARED ${SOURCE}) set_module_type(psapi win32dll) target_link_libraries(psapi epsapi ${PSEH_LIB}) add_importlibs(psapi msvcrt kernel32 ntdll) add_importlib_target(psapi.spec) -add_pch(psapi ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(psapi precomp.h) add_cd_file(TARGET psapi DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/secur32/CMakeLists.txt b/reactos/dll/win32/secur32/CMakeLists.txt index 04ca218a1c6..a460f046863 100644 --- a/reactos/dll/win32/secur32/CMakeLists.txt +++ b/reactos/dll/win32/secur32/CMakeLists.txt @@ -14,16 +14,14 @@ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/secur32.def ) -add_library(secur32 SHARED - ${CMAKE_CURRENT_BINARY_DIR}/secur32_precomp.h.gch - ${SOURCE}) +add_library(secur32 SHARED ${SOURCE}) set_module_type(secur32 win32dll) target_link_libraries(secur32 lsalib) add_importlibs(secur32 advapi32 msvcrt kernel32 ntdll) -add_pch(secur32 ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(secur32 precomp.h) add_cd_file(TARGET secur32 DESTINATION reactos/system32 FOR all) add_importlib_target(secur32.spec) diff --git a/reactos/dll/win32/sfc/CMakeLists.txt b/reactos/dll/win32/sfc/CMakeLists.txt index b01fe34b46c..7f5d5f92242 100644 --- a/reactos/dll/win32/sfc/CMakeLists.txt +++ b/reactos/dll/win32/sfc/CMakeLists.txt @@ -6,13 +6,11 @@ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/sfc_stubs.c ${CMAKE_CURRENT_BINARY_DIR}/sfc.def) -add_library(sfc SHARED - ${CMAKE_CURRENT_BINARY_DIR}/sfc_precomp.h.gch - ${SOURCE}) +add_library(sfc SHARED ${SOURCE}) set_module_type(sfc win32dll) add_importlibs(sfc msvcrt kernel32 ntdll) -add_pch(sfc ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(sfc precomp.h) add_cd_file(TARGET sfc DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/sfc_os/CMakeLists.txt b/reactos/dll/win32/sfc_os/CMakeLists.txt index c50b8f26494..d581aa7bae0 100644 --- a/reactos/dll/win32/sfc_os/CMakeLists.txt +++ b/reactos/dll/win32/sfc_os/CMakeLists.txt @@ -6,13 +6,11 @@ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/sfc_os_stubs.c ${CMAKE_CURRENT_BINARY_DIR}/sfc_os.def) -add_library(sfc_os SHARED - ${CMAKE_CURRENT_BINARY_DIR}/sfc_os_precomp.h.gch - ${SOURCE}) +add_library(sfc_os SHARED ${SOURCE}) set_module_type(sfc_os win32dll) add_importlibs(sfc_os msvcrt kernel32 ntdll) -add_pch(sfc_os ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(sfc_os precomp.h) add_cd_file(TARGET sfc_os DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/shell32/CMakeLists.txt b/reactos/dll/win32/shell32/CMakeLists.txt index 9bdd9f16463..a369e00e6ef 100644 --- a/reactos/dll/win32/shell32/CMakeLists.txt +++ b/reactos/dll/win32/shell32/CMakeLists.txt @@ -75,9 +75,9 @@ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/shell32_stubs.c ${CMAKE_CURRENT_BINARY_DIR}/shell32.def) -add_pch(shell32 ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_library(shell32 SHARED ${SOURCE}) -add_library(shell32 SHARED ${CMAKE_CURRENT_BINARY_DIR}/shell32_precomp.h.gch ${SOURCE}) +add_pch(shell32 precomp.h) set_module_type(shell32 win32dll) diff --git a/reactos/dll/win32/user32/CMakeLists.txt b/reactos/dll/win32/user32/CMakeLists.txt index c31d3554b0d..a0f76cc04f1 100644 --- a/reactos/dll/win32/user32/CMakeLists.txt +++ b/reactos/dll/win32/user32/CMakeLists.txt @@ -67,9 +67,7 @@ list(APPEND SOURCE user32.rc ${CMAKE_CURRENT_BINARY_DIR}/user32.def) -add_library(user32 SHARED - ${CMAKE_CURRENT_BINARY_DIR}/user32_user32.h.gch - ${SOURCE}) +add_library(user32 SHARED ${SOURCE}) set_module_type(user32 win32dll) @@ -79,7 +77,7 @@ target_link_libraries(user32 win32ksys ${PSEH_LIB}) -add_pch(user32 ${CMAKE_CURRENT_SOURCE_DIR}/include/user32.h ${SOURCE}) +add_pch(user32 include/user32.h) add_importlibs(user32 gdi32 advapi32 imm32 msvcrt kernel32 ntdll) add_cd_file(TARGET user32 DESTINATION reactos/system32 FOR all) add_importlib_target(user32.spec) diff --git a/reactos/dll/win32/userenv/CMakeLists.txt b/reactos/dll/win32/userenv/CMakeLists.txt index 32d3bd41711..f9327fedf99 100644 --- a/reactos/dll/win32/userenv/CMakeLists.txt +++ b/reactos/dll/win32/userenv/CMakeLists.txt @@ -17,16 +17,14 @@ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/userenv_stubs.c ${CMAKE_CURRENT_BINARY_DIR}/userenv.def) -add_library(userenv SHARED - ${CMAKE_CURRENT_BINARY_DIR}/userenv_precomp.h.gch - ${SOURCE}) +add_library(userenv SHARED ${SOURCE}) set_module_type(userenv win32dll) target_link_libraries(userenv uuid) add_importlibs(userenv advapi32 user32 msvcrt kernel32 ntdll) -add_pch(userenv ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(userenv precomp.h) add_cd_file(TARGET userenv DESTINATION reactos/system32 FOR all) add_importlib_target(userenv.spec) diff --git a/reactos/dll/win32/vdmdbg/CMakeLists.txt b/reactos/dll/win32/vdmdbg/CMakeLists.txt index a312742e646..81237307e95 100644 --- a/reactos/dll/win32/vdmdbg/CMakeLists.txt +++ b/reactos/dll/win32/vdmdbg/CMakeLists.txt @@ -7,11 +7,9 @@ list(APPEND SOURCE vdmdbg.c ${CMAKE_CURRENT_BINARY_DIR}/vdmdbg.def) -add_library(vdmdbg SHARED - ${CMAKE_CURRENT_BINARY_DIR}/vdmdbg_vdmdbg.h.gch - ${SOURCE}) +add_library(vdmdbg SHARED ${SOURCE}) set_module_type(vdmdbg win32dll) add_importlibs(vdmdbg msvcrt kernel32 ntdll) -add_pch(vdmdbg ${CMAKE_CURRENT_SOURCE_DIR}/vdmdbg.h ${SOURCE}) +add_pch(vdmdbg vdmdbg.h) add_cd_file(TARGET vdmdbg DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/winsta/CMakeLists.txt b/reactos/dll/win32/winsta/CMakeLists.txt index 2d46896145f..1b6ecef8477 100644 --- a/reactos/dll/win32/winsta/CMakeLists.txt +++ b/reactos/dll/win32/winsta/CMakeLists.txt @@ -12,12 +12,10 @@ list(APPEND SOURCE winsta.rc ${CMAKE_CURRENT_BINARY_DIR}/winsta.def) -add_library(winsta SHARED - ${CMAKE_CURRENT_BINARY_DIR}/winsta_winsta.h.gch - ${SOURCE}) +add_library(winsta SHARED ${SOURCE}) set_module_type(winsta win32dll) target_link_libraries(winsta wine) add_importlibs(winsta msvcrt kernel32 ntdll) -add_pch(winsta ${CMAKE_CURRENT_SOURCE_DIR}/winsta.h ${SOURCE}) +add_pch(winsta winsta.h) add_cd_file(TARGET winsta DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/ws2_32/CMakeLists.txt b/reactos/dll/win32/ws2_32/CMakeLists.txt index a39c061f7d5..b2fdb3f6c63 100644 --- a/reactos/dll/win32/ws2_32/CMakeLists.txt +++ b/reactos/dll/win32/ws2_32/CMakeLists.txt @@ -23,14 +23,14 @@ list(APPEND SOURCE ws2_32.rc ${CMAKE_CURRENT_BINARY_DIR}/ws2_32.def) -add_library(ws2_32 SHARED ${CMAKE_CURRENT_BINARY_DIR}/ws2_32_ws2_32.h.gch ${SOURCE}) +add_library(ws2_32 SHARED ${SOURCE}) set_module_type(ws2_32 win32dll) target_link_libraries(ws2_32 wine) add_importlibs(ws2_32 user32 advapi32 dnsapi ws2help msvcrt kernel32 ntdll) -add_pch(ws2_32 ${CMAKE_CURRENT_SOURCE_DIR}/include/ws2_32.h ${SOURCE}) +add_pch(ws2_32 include/ws2_32.h) add_cd_file(TARGET ws2_32 DESTINATION reactos/system32 FOR all) add_importlib_target(ws2_32.spec) diff --git a/reactos/drivers/base/bootvid/CMakeLists.txt b/reactos/drivers/base/bootvid/CMakeLists.txt index 3c23c82e2e0..ded06a8e48f 100644 --- a/reactos/drivers/base/bootvid/CMakeLists.txt +++ b/reactos/drivers/base/bootvid/CMakeLists.txt @@ -16,14 +16,14 @@ list(APPEND SOURCE arm/bootdata.c) endif(ARCH MATCHES i386 OR ARCH MATCHES amd64) -add_library(bootvid SHARED ${CMAKE_CURRENT_BINARY_DIR}/bootvid_precomp.h.gch ${SOURCE}) +add_library(bootvid SHARED ${SOURCE}) set_entrypoint(bootvid 0) set_subsystem(bootvid native) set_image_base(bootvid 0x00010000) add_importlibs(bootvid ntoskrnl hal) -add_pch(bootvid ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(bootvid precomp.h) add_dependencies(bootvid psdk bugcodes) add_cd_file(TARGET bootvid DESTINATION reactos/system32 NO_CAB FOR all) add_importlib_target(bootvid.spec) diff --git a/reactos/drivers/bus/acpi/cmbatt/CMakeLists.txt b/reactos/drivers/bus/acpi/cmbatt/CMakeLists.txt index 461adfeba51..afef8697887 100644 --- a/reactos/drivers/bus/acpi/cmbatt/CMakeLists.txt +++ b/reactos/drivers/bus/acpi/cmbatt/CMakeLists.txt @@ -6,12 +6,12 @@ list(APPEND SOURCE cmbwmi.c cmbatt.rc) -add_library(cmbatt SHARED ${CMAKE_CURRENT_BINARY_DIR}/cmbatt_cmbatt.h.gch ${SOURCE}) +add_library(cmbatt SHARED ${SOURCE}) set_module_type(cmbatt kernelmodedriver) add_importlibs(cmbatt ntoskrnl hal battc wmilib) -add_pch(cmbatt ${CMAKE_CURRENT_SOURCE_DIR}/cmbatt.h ${SOURCE}) +add_pch(cmbatt cmbatt.h) add_cd_file(TARGET cmbatt DESTINATION reactos/system32/drivers FOR all) \ No newline at end of file diff --git a/reactos/drivers/bus/acpi/compbatt/CMakeLists.txt b/reactos/drivers/bus/acpi/compbatt/CMakeLists.txt index 00f05b73271..a1a3b7bc7b1 100644 --- a/reactos/drivers/bus/acpi/compbatt/CMakeLists.txt +++ b/reactos/drivers/bus/acpi/compbatt/CMakeLists.txt @@ -5,11 +5,11 @@ list(APPEND SOURCE comppnp.c compbatt.rc) -add_library(compbatt SHARED ${CMAKE_CURRENT_BINARY_DIR}/compbatt_compbatt.h.gch ${SOURCE}) +add_library(compbatt SHARED ${SOURCE}) set_module_type(compbatt kernelmodedriver) add_importlibs(compbatt ntoskrnl hal battc) -add_pch(compbatt ${CMAKE_CURRENT_SOURCE_DIR}/compbatt.h ${SOURCE}) +add_pch(compbatt compbatt.h) add_cd_file(TARGET compbatt DESTINATION reactos/system32/drivers FOR all) \ No newline at end of file diff --git a/reactos/drivers/bus/pcix/CMakeLists.txt b/reactos/drivers/bus/pcix/CMakeLists.txt index a805c580883..af110680f0f 100644 --- a/reactos/drivers/bus/pcix/CMakeLists.txt +++ b/reactos/drivers/bus/pcix/CMakeLists.txt @@ -36,12 +36,12 @@ list(APPEND SOURCE utils.c pci.rc) -add_library(pcix SHARED ${CMAKE_CURRENT_BINARY_DIR}/pcix_pci.h.gch ${SOURCE}) +add_library(pcix SHARED ${SOURCE}) set_module_type(pcix kernelmodedriver) add_importlibs(pcix ntoskrnl hal) -add_pch(pcix ${CMAKE_CURRENT_SOURCE_DIR}/pci.h ${SOURCE}) +add_pch(pcix pci.h) add_dependencies(pcix pciclass) add_cd_file(TARGET pcix DESTINATION reactos/system32/drivers NO_CAB FOR all) diff --git a/reactos/drivers/filesystems/cdfs/CMakeLists.txt b/reactos/drivers/filesystems/cdfs/CMakeLists.txt index cc0fbc1b2f5..6aad25408bc 100644 --- a/reactos/drivers/filesystems/cdfs/CMakeLists.txt +++ b/reactos/drivers/filesystems/cdfs/CMakeLists.txt @@ -17,11 +17,11 @@ list(APPEND SOURCE volinfo.c cdfs.rc) -add_library(cdfs SHARED ${CMAKE_CURRENT_BINARY_DIR}/cdfs_cdfs.h.gch ${SOURCE}) +add_library(cdfs SHARED ${SOURCE}) set_module_type(cdfs kernelmodedriver) add_importlibs(cdfs ntoskrnl hal) -add_pch(cdfs ${CMAKE_CURRENT_SOURCE_DIR}/cdfs.h ${SOURCE}) +add_pch(cdfs cdfs.h) add_cd_file(TARGET cdfs DESTINATION reactos/system32/drivers NO_CAB FOR all) diff --git a/reactos/drivers/filesystems/fastfat/CMakeLists.txt b/reactos/drivers/filesystems/fastfat/CMakeLists.txt index 5d8dd934611..af6a263e2a0 100644 --- a/reactos/drivers/filesystems/fastfat/CMakeLists.txt +++ b/reactos/drivers/filesystems/fastfat/CMakeLists.txt @@ -23,11 +23,11 @@ list(APPEND SOURCE volume.c vfatfs.rc) -add_library(fastfat SHARED ${CMAKE_CURRENT_BINARY_DIR}/fastfat_vfat.h.gch ${SOURCE}) +add_library(fastfat SHARED ${SOURCE}) set_module_type(fastfat kernelmodedriver) add_importlibs(fastfat ntoskrnl hal) -add_pch(fastfat ${CMAKE_CURRENT_SOURCE_DIR}/vfat.h ${SOURCE}) +add_pch(fastfat vfat.h) add_cd_file(TARGET fastfat DESTINATION reactos/system32/drivers NO_CAB FOR all) diff --git a/reactos/drivers/filesystems/fastfat_new/CMakeLists.txt b/reactos/drivers/filesystems/fastfat_new/CMakeLists.txt index 57042c98d41..e25e5c853cc 100644 --- a/reactos/drivers/filesystems/fastfat_new/CMakeLists.txt +++ b/reactos/drivers/filesystems/fastfat_new/CMakeLists.txt @@ -24,7 +24,7 @@ list(APPEND SOURCE volume.c fastfat.rc) -add_library(fastfat_new SHARED ${CMAKE_CURRENT_BINARY_DIR}/fastfat_new_fastfat.h.gch ${SOURCE}) +add_library(fastfat_new SHARED ${SOURCE}) set_module_type(fastfat_new kernelmodedriver) @@ -34,4 +34,4 @@ target_link_libraries(fastfat_new add_importlibs(fastfat_new ntoskrnl hal) -add_pch(fastfat_new ${CMAKE_CURRENT_SOURCE_DIR}/fastfat.h ${SOURCE}) +add_pch(fastfat_new fastfat.h) diff --git a/reactos/drivers/filesystems/msfs/CMakeLists.txt b/reactos/drivers/filesystems/msfs/CMakeLists.txt index ddf2bf5b112..62f79d5f55b 100644 --- a/reactos/drivers/filesystems/msfs/CMakeLists.txt +++ b/reactos/drivers/filesystems/msfs/CMakeLists.txt @@ -7,11 +7,11 @@ list(APPEND SOURCE rw.c msfs.rc) -add_library(msfs SHARED ${CMAKE_CURRENT_BINARY_DIR}/msfs_msfs.h.gch ${SOURCE}) +add_library(msfs SHARED ${SOURCE}) set_module_type(msfs kernelmodedriver) add_importlibs(msfs ntoskrnl hal) -add_pch(msfs ${CMAKE_CURRENT_SOURCE_DIR}/msfs.h ${SOURCE}) +add_pch(msfs msfs.h) add_cd_file(TARGET msfs DESTINATION reactos/system32/drivers FOR all) diff --git a/reactos/drivers/filesystems/npfs/CMakeLists.txt b/reactos/drivers/filesystems/npfs/CMakeLists.txt index 8f960fc81f7..b1d4c044782 100644 --- a/reactos/drivers/filesystems/npfs/CMakeLists.txt +++ b/reactos/drivers/filesystems/npfs/CMakeLists.txt @@ -9,11 +9,11 @@ list(APPEND SOURCE volume.c npfs.rc) -add_library(npfs SHARED ${CMAKE_CURRENT_BINARY_DIR}/npfs_npfs.h.gch ${SOURCE}) +add_library(npfs SHARED ${SOURCE}) target_link_libraries(npfs ${PSEH_LIB}) set_module_type(npfs kernelmodedriver) add_importlibs(npfs ntoskrnl hal) -add_pch(npfs ${CMAKE_CURRENT_SOURCE_DIR}/npfs.h ${SOURCE}) +add_pch(npfs npfs.h) add_cd_file(TARGET npfs DESTINATION reactos/system32/drivers FOR all) diff --git a/reactos/drivers/filesystems/ntfs/CMakeLists.txt b/reactos/drivers/filesystems/ntfs/CMakeLists.txt index bef4973c8d9..172436e3bd8 100644 --- a/reactos/drivers/filesystems/ntfs/CMakeLists.txt +++ b/reactos/drivers/filesystems/ntfs/CMakeLists.txt @@ -17,11 +17,11 @@ list(APPEND SOURCE volinfo.c ntfs.rc) -add_library(ntfs SHARED ${CMAKE_CURRENT_BINARY_DIR}/ntfs_ntfs.h.gch ${SOURCE}) +add_library(ntfs SHARED ${SOURCE}) set_module_type(ntfs kernelmodedriver) add_importlibs(ntfs ntoskrnl hal) -add_pch(ntfs ${CMAKE_CURRENT_SOURCE_DIR}/ntfs.h ${SOURCE}) +add_pch(ntfs ntfs.h) add_cd_file(TARGET ntfs DESTINATION reactos/system32/drivers NO_CAB FOR all) diff --git a/reactos/drivers/network/afd/CMakeLists.txt b/reactos/drivers/network/afd/CMakeLists.txt index 22ef729c619..e0af27b0294 100644 --- a/reactos/drivers/network/afd/CMakeLists.txt +++ b/reactos/drivers/network/afd/CMakeLists.txt @@ -18,12 +18,12 @@ list(APPEND SOURCE afd/write.c afd.rc) -add_library(afd SHARED ${CMAKE_CURRENT_BINARY_DIR}/afd_afd.h.gch ${SOURCE}) +add_library(afd SHARED ${SOURCE}) target_link_libraries(afd ${PSEH_LIB}) set_module_type(afd kernelmodedriver) add_importlibs(afd ntoskrnl hal) -add_pch(afd ${CMAKE_CURRENT_SOURCE_DIR}/include/afd.h ${SOURCE}) +add_pch(afd include/afd.h) add_cd_file(TARGET afd DESTINATION reactos/system32/drivers FOR all) diff --git a/reactos/drivers/network/ndis/CMakeLists.txt b/reactos/drivers/network/ndis/CMakeLists.txt index 60b7bcc52f1..f548a1b17d9 100644 --- a/reactos/drivers/network/ndis/CMakeLists.txt +++ b/reactos/drivers/network/ndis/CMakeLists.txt @@ -35,12 +35,12 @@ list(APPEND SOURCE ndis.rc ${CMAKE_CURRENT_BINARY_DIR}/ndis.def) -add_library(ndis SHARED ${CMAKE_CURRENT_BINARY_DIR}/ndis_ndissys.h.gch ${SOURCE}) +add_library(ndis SHARED ${SOURCE}) set_module_type(ndis kernelmodedriver) add_importlibs(ndis ntoskrnl hal) -add_pch(ndis ${CMAKE_CURRENT_SOURCE_DIR}/include/ndissys.h ${SOURCE}) +add_pch(ndis include/ndissys.h) add_cd_file(TARGET ndis DESTINATION reactos/system32/drivers FOR all) add_importlib_target(ndis.spec) diff --git a/reactos/drivers/network/tcpip/CMakeLists.txt b/reactos/drivers/network/tcpip/CMakeLists.txt index e86a0d7fcec..988f0908492 100644 --- a/reactos/drivers/network/tcpip/CMakeLists.txt +++ b/reactos/drivers/network/tcpip/CMakeLists.txt @@ -26,7 +26,7 @@ list(APPEND SOURCE tcpip.rc ${CMAKE_CURRENT_BINARY_DIR}/tcpip.def) -add_library(tcpip SHARED ${CMAKE_CURRENT_BINARY_DIR}/tcpip_precomp.h.gch ${SOURCE}) +add_library(tcpip SHARED ${SOURCE}) target_link_libraries(tcpip ip @@ -37,6 +37,6 @@ target_link_libraries(tcpip set_module_type(tcpip kernelmodedriver) add_importlibs(tcpip ndis ntoskrnl hal) -add_pch(tcpip ${CMAKE_CURRENT_SOURCE_DIR}/include/precomp.h ${SOURCE}) +add_pch(tcpip include/precomp.h) add_cd_file(TARGET tcpip DESTINATION reactos/system32/drivers FOR all) diff --git a/reactos/drivers/usb/nt4compat/usbdriver/CMakeLists.txt b/reactos/drivers/usb/nt4compat/usbdriver/CMakeLists.txt index fcf92117880..2bf1365a6ee 100644 --- a/reactos/drivers/usb/nt4compat/usbdriver/CMakeLists.txt +++ b/reactos/drivers/usb/nt4compat/usbdriver/CMakeLists.txt @@ -25,11 +25,11 @@ list(APPEND SOURCE keyboard.c usbdriver.rc) -add_library(usbdriver SHARED ${CMAKE_CURRENT_BINARY_DIR}/usbdriver_usbdriver.h.gch ${SOURCE}) +add_library(usbdriver SHARED ${SOURCE}) set_module_type(usbdriver kernelmodedriver) add_importlibs(usbdriver ntoskrnl hal) -add_pch(usbdriver ${CMAKE_CURRENT_SOURCE_DIR}/usbdriver.h ${SOURCE}) +add_pch(usbdriver usbdriver.h) add_cd_file(TARGET usbdriver DESTINATION reactos/system32/drivers FOR all) diff --git a/reactos/drivers/video/displays/framebuf_new/CMakeLists.txt b/reactos/drivers/video/displays/framebuf_new/CMakeLists.txt index d78771398ae..8e7a39748f2 100644 --- a/reactos/drivers/video/displays/framebuf_new/CMakeLists.txt +++ b/reactos/drivers/video/displays/framebuf_new/CMakeLists.txt @@ -10,7 +10,7 @@ list(APPEND SOURCE framebuf_new.rc ${CMAKE_CURRENT_BINARY_DIR}/framebuf_new.def) -add_library(framebuf_new SHARED ${CMAKE_CURRENT_BINARY_DIR}/framebuf_new_driver.h.gch ${SOURCE}) +add_library(framebuf_new SHARED ${SOURCE}) if(ARCH MATCHES i386) if(MSVC) @@ -27,5 +27,5 @@ set_image_base(framebuf_new 0x00010000) target_link_libraries(framebuf_new libcntpr) add_importlibs(framebuf_new win32k) -add_pch(framebuf_new ${CMAKE_CURRENT_SOURCE_DIR}/driver.h ${SOURCE}) +add_pch(framebuf_new driver.h) add_dependencies(framebuf_new psdk bugcodes) diff --git a/reactos/drivers/video/miniport/vga/CMakeLists.txt b/reactos/drivers/video/miniport/vga/CMakeLists.txt index 52fe270c1d8..841879b3652 100644 --- a/reactos/drivers/video/miniport/vga/CMakeLists.txt +++ b/reactos/drivers/video/miniport/vga/CMakeLists.txt @@ -4,10 +4,10 @@ list(APPEND SOURCE vgamp.c vgamp.rc) -add_library(vgamp SHARED ${CMAKE_CURRENT_BINARY_DIR}/vgamp_vgamp.h.gch ${SOURCE}) +add_library(vgamp SHARED ${SOURCE}) set_module_type(vgamp kernelmodedriver) add_importlibs(vgamp videoprt) -add_pch(vgamp ${CMAKE_CURRENT_SOURCE_DIR}/vgamp.h ${SOURCE}) +add_pch(vgamp vgamp.h) add_cd_file(TARGET vgamp DESTINATION reactos/system32/drivers FOR all) diff --git a/reactos/drivers/video/miniport/vga_new/CMakeLists.txt b/reactos/drivers/video/miniport/vga_new/CMakeLists.txt index dba2632b9dc..3580a9cb701 100644 --- a/reactos/drivers/video/miniport/vga_new/CMakeLists.txt +++ b/reactos/drivers/video/miniport/vga_new/CMakeLists.txt @@ -7,7 +7,7 @@ list(APPEND SOURCE vbe.c vga.rc) -add_library(vga SHARED ${CMAKE_CURRENT_BINARY_DIR}/vga_vga.h.gch ${SOURCE}) +add_library(vga SHARED ${SOURCE}) target_link_libraries(vga libcntpr) @@ -20,6 +20,6 @@ endif() set_module_type(vga kernelmodedriver) add_importlibs(vga videoprt) -add_pch(vga ${CMAKE_CURRENT_SOURCE_DIR}/vga.h ${SOURCE}) +add_pch(vga vga.h) add_cd_file(TARGET vga DESTINATION reactos/system32/drivers FOR all) diff --git a/reactos/drivers/video/miniport/vmx_svga/CMakeLists.txt b/reactos/drivers/video/miniport/vmx_svga/CMakeLists.txt index 056fe513f51..3f97a72c218 100644 --- a/reactos/drivers/video/miniport/vmx_svga/CMakeLists.txt +++ b/reactos/drivers/video/miniport/vmx_svga/CMakeLists.txt @@ -1,9 +1,9 @@ list(APPEND SOURCE vmx_svga.c vmx_svga.rc) -add_library(vmx_svga SHARED ${CMAKE_CURRENT_BINARY_DIR}/vmx_svga_precomp.h.gch ${SOURCE}) +add_library(vmx_svga SHARED ${SOURCE}) set_module_type(vmx_svga kernelmodedriver) add_importlibs(vmx_svga ntoskrnl videoprt) -add_pch(vmx_svga ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${SOURCE}) +add_pch(vmx_svga precomp.h) diff --git a/reactos/drivers/video/videoprt/CMakeLists.txt b/reactos/drivers/video/videoprt/CMakeLists.txt index 2485ada6020..1eea498eb64 100644 --- a/reactos/drivers/video/videoprt/CMakeLists.txt +++ b/reactos/drivers/video/videoprt/CMakeLists.txt @@ -23,11 +23,11 @@ list(APPEND SOURCE videoprt.rc ${CMAKE_CURRENT_BINARY_DIR}/videoprt.def) -add_library(videoprt SHARED ${CMAKE_CURRENT_BINARY_DIR}/videoprt_videoprt.h.gch ${SOURCE}) +add_library(videoprt SHARED ${SOURCE}) set_module_type(videoprt kernelmodedriver) add_importlibs(videoprt ntoskrnl hal) -add_pch(videoprt ${CMAKE_CURRENT_SOURCE_DIR}/videoprt.h ${SOURCE}) +add_pch(videoprt videoprt.h) add_cd_file(TARGET videoprt DESTINATION reactos/system32/drivers FOR all) add_importlib_target(videoprt.spec) diff --git a/reactos/gcc.cmake b/reactos/gcc.cmake index cce35da157d..e370039acf0 100644 --- a/reactos/gcc.cmake +++ b/reactos/gcc.cmake @@ -93,45 +93,6 @@ else() set(ARCH2 ${ARCH}) endif() -# Macros -macro(_PCH_GET_COMPILE_FLAGS _target_name _out_compile_flags _header_filename) - # Add the precompiled header to the build - get_filename_component(FILE ${_header_filename} NAME) - set(_gch_filename "${_target_name}_${FILE}.gch") - list(APPEND ${_out_compile_flags} -c ${_header_filename} -o ${_gch_filename}) - - # This gets us our includes - get_directory_property(DIRINC INCLUDE_DIRECTORIES) - foreach(item ${DIRINC}) - list(APPEND ${_out_compile_flags} -I${item}) - endforeach() - - # This is a particular bit of undocumented/hacky magic I'm quite proud of - get_directory_property(_compiler_flags DEFINITIONS) - string(REPLACE "\ " "\t" _compiler_flags ${_compiler_flags}) - list(APPEND ${_out_compile_flags} ${_compiler_flags}) - - # This gets any specific definitions that were added with set-target-property - get_target_property(_target_defs ${_target_name} COMPILE_DEFINITIONS) - if (_target_defs) - foreach(item ${_target_defs}) - list(APPEND ${_out_compile_flags} -D${item}) - endforeach() - endif() -endmacro() - -macro(add_pch _target_name _header_filename _src_list) - get_filename_component(FILE ${_header_filename} NAME) - set(_gch_filename "${_target_name}_${FILE}.gch") - list(APPEND ${_src_list} ${_gch_filename}) - _PCH_GET_COMPILE_FLAGS(${_target_name} _args ${_header_filename}) - file(REMOVE ${_gch_filename}) - add_custom_command( - OUTPUT ${_gch_filename} - COMMAND ${CMAKE_C_COMPILER} ${CMAKE_C_COMPILER_ARG1} ${_args} - DEPENDS ${_header_filename}) -endmacro() - macro(add_linkerflag MODULE _flag) set(NEW_LINKER_FLAGS ${_flag}) get_target_property(LINKER_FLAGS ${MODULE} LINK_FLAGS) @@ -328,3 +289,46 @@ endmacro() #pseh lib, needed with mingw set(PSEH_LIB "pseh") + +# Macros +macro(_PCH_GET_COMPILE_FLAGS _target_name _out_compile_flags _header_filename) + # Add the precompiled header to the build + get_filename_component(_FILE ${_header_filename} NAME) + set(_gch_filename "${_target_name}_${_FILE}.gch") + list(APPEND ${_out_compile_flags} -c ${_header_filename} -o ${_gch_filename}) + + # This gets us our includes + get_directory_property(DIRINC INCLUDE_DIRECTORIES) + foreach(item ${DIRINC}) + list(APPEND ${_out_compile_flags} -I${item}) + endforeach() + + # This our definitions + get_directory_property(_compiler_flags DEFINITIONS) + list(APPEND ${_out_compile_flags} ${_compiler_flags}) + + # This gets any specific definitions that were added with set-target-property + get_target_property(_target_defs ${_target_name} COMPILE_DEFINITIONS) + if (_target_defs) + foreach(item ${_target_defs}) + list(APPEND ${_out_compile_flags} -D${item}) + endforeach() + endif() + + separate_arguments(${_out_compile_flags}) +endmacro() + +macro(add_pch _target_name _FILE) + set(_header_filename ${CMAKE_CURRENT_SOURCE_DIR}/${_FILE}) + get_filename_component(_basename ${_FILE} NAME) + set(_gch_filename ${_target_name}_${basename}.gch) + _PCH_GET_COMPILE_FLAGS(${_target_name} _args ${_header_filename}) + + add_custom_command( + OUTPUT ${_gch_filename} + COMMAND ${CMAKE_C_COMPILER} ${CMAKE_C_COMPILER_ARG1} ${_args} + DEPENDS ${_header_filename}) + get_target_property(_src_files ${_target_name} SOURCES) + set_source_files_properties(${_src_files} PROPERTIES COMPILE_FLAGS "-Winvalid-pch -fpch-preprocess" OBJECT_DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${_gch_filename}) + #add_linkerflag(${_target_name} "${_gch_filename}") +endmacro() diff --git a/reactos/hal/halx86/CMakeLists.txt b/reactos/hal/halx86/CMakeLists.txt index ebada96c389..13b14ccbc11 100644 --- a/reactos/hal/halx86/CMakeLists.txt +++ b/reactos/hal/halx86/CMakeLists.txt @@ -82,7 +82,6 @@ if(ARCH MATCHES i386) spec2def(hal.dll ../hal.spec) list(APPEND HAL_SOURCE - ${CMAKE_CURRENT_BINARY_DIR}/hal_hal.h.gch ${HAL_GENERIC_SOURCE} ${HAL_GENERIC_PCAT_SOURCE} ${HAL_GENERIC_UP_SOURCE} @@ -92,7 +91,7 @@ if(ARCH MATCHES i386) # hal add_library(hal SHARED ${HAL_SOURCE}) - add_pch(hal ${CMAKE_CURRENT_SOURCE_DIR}/include/hal.h ${HAL_SOURCE}) + add_pch(hal include/hal.h) add_dependencies(hal psdk bugcodes) set_entrypoint(hal HalInitSystem@8) diff --git a/reactos/lib/rtl/CMakeLists.txt b/reactos/lib/rtl/CMakeLists.txt index 64194389eac..da0f979d2dd 100644 --- a/reactos/lib/rtl/CMakeLists.txt +++ b/reactos/lib/rtl/CMakeLists.txt @@ -97,6 +97,6 @@ elseif(ARCH MATCHES powerpc) powerpc/thread.c) endif() -add_library(rtl ${CMAKE_CURRENT_BINARY_DIR}/rtl_rtl.h.gch ${SOURCE}) -add_pch(rtl ${CMAKE_CURRENT_SOURCE_DIR}/rtl.h ${SOURCE}) +add_library(rtl ${SOURCE}) +add_pch(rtl rtl.h) add_dependencies(rtl psdk asm) diff --git a/reactos/lib/sdk/crt/crt.cmake b/reactos/lib/sdk/crt/crt.cmake index 29c1dd97e41..738106fdfff 100644 --- a/reactos/lib/sdk/crt/crt.cmake +++ b/reactos/lib/sdk/crt/crt.cmake @@ -431,8 +431,8 @@ if(ARCH MATCHES amd64) math/amd64/tan.S) endif() -add_library(crt ${CMAKE_CURRENT_BINARY_DIR}/crt_precomp.h.gch ${CRT_SOURCE}) +add_library(crt ${CRT_SOURCE}) set_property(TARGET crt PROPERTY COMPILE_DEFINITIONS __MINGW_IMPORT=extern USE_MSVCRT_PREFIX _MSVCRT_LIB_ _MSVCRT_ _MT) -add_pch(crt ${CMAKE_CURRENT_SOURCE_DIR}/precomp.h ${CRT_SOURCE}) +add_pch(crt precomp.h) add_dependencies(crt psdk asm) diff --git a/reactos/ntoskrnl/CMakeLists.txt b/reactos/ntoskrnl/CMakeLists.txt index 4ad133b4a22..45c985e89ec 100644 --- a/reactos/ntoskrnl/CMakeLists.txt +++ b/reactos/ntoskrnl/CMakeLists.txt @@ -421,7 +421,7 @@ else() # _WINKD_ endif() -add_executable(ntoskrnl ${CMAKE_CURRENT_BINARY_DIR}/ntoskrnl_ntoskrnl.h.gch ${SOURCE}) +add_executable(ntoskrnl ${SOURCE}) set_entrypoint(ntoskrnl KiSystemStartup@4) set_subsystem(ntoskrnl native) @@ -445,7 +445,7 @@ target_link_libraries(ntoskrnl add_importlibs(ntoskrnl hal kdcom bootvid) -add_pch(ntoskrnl ${CMAKE_CURRENT_SOURCE_DIR}/include/ntoskrnl.h ${SOURCE}) +add_pch(ntoskrnl include/ntoskrnl.h) add_dependencies(ntoskrnl psdk bugcodes asm) add_cd_file(TARGET ntoskrnl DESTINATION reactos/system32 NO_CAB FOR all) diff --git a/reactos/subsystems/win32/csrss/csrsrv/CMakeLists.txt b/reactos/subsystems/win32/csrss/csrsrv/CMakeLists.txt index 34944902ed3..26989823cf9 100644 --- a/reactos/subsystems/win32/csrss/csrsrv/CMakeLists.txt +++ b/reactos/subsystems/win32/csrss/csrsrv/CMakeLists.txt @@ -13,7 +13,7 @@ list(APPEND SOURCE init.c ${CMAKE_CURRENT_BINARY_DIR}/csrsrv.def) -add_library(csrsrv SHARED ${CMAKE_CURRENT_BINARY_DIR}/csrsrv_srv.h.gch ${SOURCE}) +add_library(csrsrv SHARED ${SOURCE}) target_link_libraries(csrsrv ${PSEH_LIB}) @@ -26,7 +26,7 @@ endif() add_importlibs(csrsrv ntdll smdll) -add_pch(csrsrv ${CMAKE_CURRENT_SOURCE_DIR}/srv.h ${SOURCE}) +add_pch(csrsrv srv.h) add_dependencies(csrsrv psdk bugcodes) add_cd_file(TARGET csrsrv DESTINATION reactos/system32 FOR all) diff --git a/reactos/subsystems/win32/csrss/win32csr/CMakeLists.txt b/reactos/subsystems/win32/csrss/win32csr/CMakeLists.txt index 20f278a69e3..e42665df0b2 100644 --- a/reactos/subsystems/win32/csrss/win32csr/CMakeLists.txt +++ b/reactos/subsystems/win32/csrss/win32csr/CMakeLists.txt @@ -28,7 +28,7 @@ list(APPEND SOURCE win32csr.rc ${CMAKE_CURRENT_BINARY_DIR}/win32csr.def) -add_library(win32csr SHARED ${CMAKE_CURRENT_BINARY_DIR}/win32csr_w32csr.h.gch ${SOURCE}) +add_library(win32csr SHARED ${SOURCE}) target_link_libraries(win32csr win32ksys @@ -38,7 +38,7 @@ set_module_type(win32csr win32dll) add_importlibs(win32csr user32 gdi32 advapi32 psapi msvcrt kernel32 ntdll) -add_pch(win32csr ${CMAKE_CURRENT_SOURCE_DIR}/w32csr.h ${SOURCE}) +add_pch(win32csr w32csr.h) add_dependencies(win32csr bugcodes) add_cd_file(TARGET win32csr DESTINATION reactos/system32 FOR all) diff --git a/reactos/subsystems/win32/win32k/CMakeLists.txt b/reactos/subsystems/win32/win32k/CMakeLists.txt index 29ac47c6871..649880cf4b9 100644 --- a/reactos/subsystems/win32/win32k/CMakeLists.txt +++ b/reactos/subsystems/win32/win32k/CMakeLists.txt @@ -182,7 +182,6 @@ list(APPEND SOURCE endif() add_library(win32k SHARED - ${CMAKE_CURRENT_BINARY_DIR}/win32k_pch.h.gch ${CMAKE_CURRENT_BINARY_DIR}/win32k.def ${SOURCE}) @@ -194,7 +193,7 @@ target_link_libraries(win32k libcntpr) add_importlibs(win32k ntoskrnl hal ftfd) -add_pch(win32k ${CMAKE_CURRENT_SOURCE_DIR}/pch.h ${SOURCE}) +add_pch(win32k pch.h) add_cd_file(TARGET win32k DESTINATION reactos/system32 FOR all) add_importlib_target(win32k.spec)