- Rename ncitool to nci and mark it as an exported native tool.
- Add nci generated intermediate files to build.

svn path=/branches/cmake-bringup/; revision=48325
This commit is contained in:
Amine Khaldi 2010-07-28 10:13:27 +00:00
parent 4455372650
commit a7d2ad6334
2 changed files with 40 additions and 1 deletions

View file

@ -16,7 +16,7 @@ include_directories(./include/reactos/wine)
add_subdirectory(tools)
add_subdirectory(lib)
export(TARGETS widl wmc FILE ${CMAKE_BINARY_DIR}/ImportExecutables.cmake NAMESPACE native- )
export(TARGETS widl wmc nci FILE ${CMAKE_BINARY_DIR}/ImportExecutables.cmake NAMESPACE native- )
else()
@ -70,5 +70,42 @@ add_subdirectory(include/reactos/mc)
add_subdirectory(lib)
# nci generated intermediate files
set(nci_output
${REACTOS_BINARY_DIR}/ntoskrnl/include/internal/napi.h
${REACTOS_BINARY_DIR}/subsystems/win32/win32k/include/napi.h
${REACTOS_BINARY_DIR}/lib/ntdllsys/ntdll.S
${REACTOS_BINARY_DIR}/ntoskrnl/ex/zw.S
${REACTOS_BINARY_DIR}/lib/win32ksys/win32k.S
${REACTOS_BINARY_DIR}/dll/ntdll/def/ntsys.pspec
)
# stupid nci tool can't create folders itself, se we're gonna create them for it
set(nci_folders
dll\\ntdll\\def
lib\\ntdllsys\\ntdll
lib\\win32ksys
ntoskrnl\\include\\internal
ntoskrnl\\ex
subsystems\\win32\\win32k\\include
)
ADD_CUSTOM_COMMAND(
OUTPUT ${nci_folders}
COMMAND mkdir ${MKDIR_ARG} ${nci_folders}
WORKING_DIRECTORY ${REACTOS_BINARY_DIR}
)
ADD_CUSTOM_COMMAND(
OUTPUT ${nci_output}
COMMAND native-nci -arch ${ARCH} ${REACTOS_SOURCE_DIR}/ntoskrnl/sysfuncs.lst ${REACTOS_SOURCE_DIR}/subsystems/win32/win32k/w32ksvc.db ${nci_output}
DEPENDS native-nci ${nci_folders}
)
SET_SOURCE_FILES_PROPERTIES(${nci_output} PROPERTIES GENERATED TRUE)
ADD_CUSTOM_TARGET(nci_resources ALL DEPENDS ${nci_output})
endif()

View file

@ -4,8 +4,10 @@ SET(ARCH i386)
# Choose the right MinGW prefix
if (CMAKE_HOST_SYSTEM_NAME MATCHES Windows)
set(MINGW_PREFIX "")
set(MKDIR_ARG "")
else()
set(MINGW_PREFIX "mingw32-")
set(MKDIR_ARG "-p")
endif()
# the name of the target operating system