mirror of
https://github.com/reactos/reactos.git
synced 2025-01-02 12:32:47 +00:00
[CMAKE]
fix pch support, with proper dependancies. Use cmake built-in functions instead of doing weird "magic" with tabs and spaces. According to gcc doc, if header.h is precompiled, the output should be named "header.h.gch" and not anything else. svn path=/trunk/; revision=52058
This commit is contained in:
parent
f835168ac7
commit
989c121257
84 changed files with 207 additions and 258 deletions
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
||||
|
|
|
@ -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)
|
||||
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
||||
|
|
|
@ -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)
|
||||
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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" (
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
|
@ -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)
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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()
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -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)
|
||||
|
||||
|
|
Loading…
Reference in a new issue