[CMAKE]
authorAmine Khaldi <amine.khaldi@reactos.org>
Tue, 31 Aug 2010 13:25:10 +0000 (13:25 +0000)
committerAmine Khaldi <amine.khaldi@reactos.org>
Tue, 31 Aug 2010 13:25:10 +0000 (13:25 +0000)
- Improve handling buildno.h

svn path=/branches/cmake-bringup/; revision=48663

CMakeLists.txt
dll/win32/acledit/CMakeLists.txt

index 3a645e6..b8450cd 100644 (file)
@@ -21,11 +21,12 @@ include_directories(${REACTOS_SOURCE_DIR}/tools/unicode)
 include_directories(include)
 include_directories(include/reactos)
 include_directories(include/reactos/wine)
+include_directories(${REACTOS_BINARY_DIR}/include)
 
 add_subdirectory(tools)
 add_subdirectory(lib)
 
-export(TARGETS widl winebuild nci FILE ${CMAKE_BINARY_DIR}/ImportExecutables.cmake NAMESPACE native- )
+export(TARGETS widl winebuild nci buildno FILE ${CMAKE_BINARY_DIR}/ImportExecutables.cmake NAMESPACE native- )
 
 else()
 
@@ -143,5 +144,11 @@ ADD_CUSTOM_TARGET(kernel_napi ALL DEPENDS ${REACTOS_BINARY_DIR}/ntoskrnl/include
 ADD_CUSTOM_TARGET(subsystem_napi ALL DEPENDS ${REACTOS_BINARY_DIR}/subsystems/win32/win32k/include/napi.h)
 ADD_CUSTOM_TARGET(kernel_zw ALL DEPENDS ${REACTOS_BINARY_DIR}/ntoskrnl/ex/zw.S)
 
+file(MAKE_DIRECTORY ${REACTOS_BINARY_DIR}/include/reactos)
+ADD_CUSTOM_COMMAND(OUTPUT ${REACTOS_BINARY_DIR}/include/reactos/buildno.h
+                   COMMAND native-buildno ${REACTOS_BINARY_DIR}/include/reactos/buildno.h
+                   DEPENDS ${REACTOS_SOURCE_DIR}/include/reactos/version.h) 
+ADD_CUSTOM_TARGET(buildno_header ALL DEPENDS ${REACTOS_BINARY_DIR}/include/reactos/buildno.h)
+
 endif()
 
index 216bc05..1a45ff5 100644 (file)
@@ -17,4 +17,4 @@ target_link_libraries(acledit
     ${CMAKE_CURRENT_BINARY_DIR}/acledit.def
     ${REACTOS_SOURCE_DIR}/dll/ntdll/libntdll.a)
 
-add_dependencies(acledit acledit_def psdk)
+add_dependencies(acledit acledit_def psdk buildno_header)