Author: tkreuzer Date: Thu Dec 2 22:16:59 2010 New Revision: 49904
URL: http://svn.reactos.org/svn/reactos?rev=49904&view=rev Log: [CMAKE] Invoke spec2def only once to generate asm stub and def file.
Modified: branches/cmake-bringup/msc.cmake
Modified: branches/cmake-bringup/msc.cmake URL: http://svn.reactos.org/svn/reactos/branches/cmake-bringup/msc.cmake?rev=4990... ============================================================================== --- branches/cmake-bringup/msc.cmake [iso-8859-1] (original) +++ branches/cmake-bringup/msc.cmake [iso-8859-1] Thu Dec 2 22:16:59 2010 @@ -142,15 +142,13 @@ macro(add_importlib_target _spec_file) get_filename_component(_name ${_spec_file} NAME_WE)
+ # Generate the asm stub file and the export def file add_custom_command( OUTPUT ${CMAKE_BINARY_DIR}/importlibs/lib${_name}_stubs.asm ${CMAKE_BINARY_DIR}/importlibs/lib${_name}_exp.def - # Generate the asm stub file - COMMAND native-spec2def -l=${CMAKE_BINARY_DIR}/importlibs/lib${_name}_stubs.asm ${CMAKE_CURRENT_SOURCE_DIR}/${_spec_file} - # Generate a the export def file - COMMAND native-spec2def -@ -r -d=${CMAKE_BINARY_DIR}/importlibs/lib${_name}_exp.def ${CMAKE_CURRENT_SOURCE_DIR}/${_spec_file} + COMMAND native-spec2def -@ -r -d=${CMAKE_BINARY_DIR}/importlibs/lib${_name}_exp.def -l=${CMAKE_BINARY_DIR}/importlibs/lib${_name}_stubs.asm ${CMAKE_CURRENT_SOURCE_DIR}/${_spec_file} DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${_spec_file})
- # Assemble the file + # Assemble the stub file add_custom_command( OUTPUT ${CMAKE_BINARY_DIR}/importlibs/lib${_name}_stubs.obj COMMAND ${CMAKE_ASM_COMPILER} /nologo /Fo${CMAKE_BINARY_DIR}/importlibs/lib${_name}_stubs.obj /c /Ta ${CMAKE_BINARY_DIR}/importlibs/lib${_name}_stubs.asm