X-Git-Url: https://git.reactos.org/?p=reactos.git;a=blobdiff_plain;f=msc.cmake;h=7ffb8663a003d9db11eb2a14d407c4f4147de8ee;hp=e36531953a5065eee4519b18a2968150a6d2e794;hb=e3d6ac205158b3bd0d80629120a7c4d1e038d352;hpb=8dc1f0eb0e70e1aee0af5af9bdec278a812ac170 diff --git a/msc.cmake b/msc.cmake index e36531953a5..7ffb8663a00 100644 --- a/msc.cmake +++ b/msc.cmake @@ -73,7 +73,6 @@ macro(set_module_type MODULE TYPE) message(STATUS "${MODULE} has no base address") endif() target_link_libraries(${MODULE} mingw_common mingw_dllmain) - add_importlibs(${MODULE} msvcrt kernel32) add_linkerflag(${MODULE} "/DLL") endif() @@ -148,18 +147,15 @@ macro(add_importlibs MODULE) endforeach() endmacro() -MACRO(spec2def _dllname _spec_file) +macro(spec2def _dllname _spec_file) get_filename_component(_file ${_spec_file} NAME_WE) add_custom_command( OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${_file}.def - COMMAND native-spec2def -n --dll ${_dllname} ${CMAKE_CURRENT_SOURCE_DIR}/${_spec_file} ${CMAKE_CURRENT_BINARY_DIR}/${_file}.def + COMMAND native-spec2def -n --dll ${_dllname} ${CMAKE_CURRENT_SOURCE_DIR}/${_spec_file} ${CMAKE_CURRENT_BINARY_DIR}/${_file}.def DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${_spec_file}) set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/${_file}.def PROPERTIES GENERATED TRUE) - add_custom_target( - ${_dllname}.def - DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${_file}.def) -ENDMACRO(spec2def _dllname _spec_file) +endmacro() # Optional 3rd parameter: dllname macro(set_export_spec _module _spec_file) @@ -170,8 +166,6 @@ macro(set_export_spec _module _spec_file) set(_dllname ${_file}.dll) endif() spec2def(${_dllname} ${_spec_file}) - add_linkerflag(${_module} "/DEF:${CMAKE_CURRENT_BINARY_DIR}/${_file}.def") - add_dependencies(${_module} ${_dllname}.def) endmacro() file(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/importlibs)