Author: spetreolle
Date: Thu Dec 2 12:36:16 2010
New Revision: 49893
URL:
http://svn.reactos.org/svn/reactos?rev=49893&view=rev
Log:
[CMAKE]
Add stubs file to source automatically.
Gcc: fix set_rc_compiler() so that it doesn't conflict with custom_incdefs().
Modified:
branches/cmake-bringup/drivers/storage/classpnp/CMakeLists.txt
branches/cmake-bringup/gcc.cmake
branches/cmake-bringup/msc.cmake
Modified: branches/cmake-bringup/drivers/storage/classpnp/CMakeLists.txt
URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/drivers/storage/c…
==============================================================================
--- branches/cmake-bringup/drivers/storage/classpnp/CMakeLists.txt [iso-8859-1]
(original)
+++ branches/cmake-bringup/drivers/storage/classpnp/CMakeLists.txt [iso-8859-1] Thu Dec 2
12:36:16 2010
@@ -13,6 +13,9 @@
add_definitions(-mrtd -fno-builtin -w)
endif()
+spec2def(classpnp.sys class.spec)
+
+list(REMOVE_ITEM SOURCE ${CMAKE_CURRENT_BINARY_DIR}/class_stubs.c)
list(APPEND SOURCE
autorun.c
class.c
@@ -31,8 +34,6 @@
class.rc
${CMAKE_CURRENT_BINARY_DIR}/class.def)
-spec2def(classpnp.sys class.spec)
-
add_library(classpnp SHARED ${SOURCE})
target_link_libraries(classpnp ${PSEH_LIB} libcntpr)
Modified: branches/cmake-bringup/gcc.cmake
URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/gcc.cmake?rev=498…
==============================================================================
--- branches/cmake-bringup/gcc.cmake [iso-8859-1] (original)
+++ branches/cmake-bringup/gcc.cmake [iso-8859-1] Thu Dec 2 12:36:16 2010
@@ -173,14 +173,14 @@
get_directory_property(includes INCLUDE_DIRECTORIES)
foreach(arg ${defines})
- set(result_defs "${result_defs} -D${arg}")
+ set(rc_result_defs "${rc_result_defs} -D${arg}")
endforeach(arg ${defines})
foreach(arg ${includes})
- set(result_incs "-I${arg} ${result_incs}")
+ set(rc_result_incs "-I${arg} ${rc_result_incs}")
endforeach(arg ${includes})
- set(CMAKE_RC_COMPILE_OBJECT "<CMAKE_RC_COMPILER> ${result_defs}
${result_incs} -i <SOURCE> -O coff -o <OBJECT>")
+ set(CMAKE_RC_COMPILE_OBJECT "<CMAKE_RC_COMPILER> ${rc_result_defs}
${rc_result_incs} -i <SOURCE> -O coff -o <OBJECT>")
endmacro()
#idl files support
@@ -206,6 +206,7 @@
set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/${_file}.def
PROPERTIES GENERATED TRUE EXTERNAL_OBJECT TRUE)
set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/${_file}_stubs.c PROPERTIES
GENERATED TRUE)
+ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/${_file}_stubs.c)
endmacro()
# Optional 3rd parameter: dllname
Modified: branches/cmake-bringup/msc.cmake
URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/msc.cmake?rev=498…
==============================================================================
--- branches/cmake-bringup/msc.cmake [iso-8859-1] (original)
+++ branches/cmake-bringup/msc.cmake [iso-8859-1] Thu Dec 2 12:36:16 2010
@@ -200,6 +200,7 @@
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${_spec_file})
set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/${_file}.def
${CMAKE_CURRENT_BINARY_DIR}/${_file}_stubs.c
PROPERTIES GENERATED TRUE)
+ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/${_file}_stubs.c)
endmacro()
# Optional 3rd parameter: dllname