mirror of
https://github.com/reactos/reactos.git
synced 2025-01-10 16:18:16 +00:00
[CMAKE]
- Revert back to including the definition files into the source files list. svn path=/branches/cmake-bringup/; revision=49637
This commit is contained in:
parent
478a5435a9
commit
77c6616d62
3 changed files with 7 additions and 16 deletions
|
@ -4,7 +4,8 @@ set_unicode()
|
||||||
list(APPEND SOURCE
|
list(APPEND SOURCE
|
||||||
acledit.c
|
acledit.c
|
||||||
stubs.c
|
stubs.c
|
||||||
acledit.rc)
|
acledit.rc
|
||||||
|
${CMAKE_CURRENT_BINARY_DIR}/acledit.def)
|
||||||
|
|
||||||
add_library(acledit SHARED ${SOURCE})
|
add_library(acledit SHARED ${SOURCE})
|
||||||
|
|
||||||
|
|
|
@ -154,7 +154,7 @@ macro(add_importlib_target _def_file)
|
||||||
# empty for now, while import libs are shipped
|
# empty for now, while import libs are shipped
|
||||||
endmacro()
|
endmacro()
|
||||||
|
|
||||||
MACRO(spec2def _dllname _spec_file)
|
macro(spec2def _dllname _spec_file)
|
||||||
get_filename_component(_file ${_spec_file} NAME_WE)
|
get_filename_component(_file ${_spec_file} NAME_WE)
|
||||||
add_custom_command(
|
add_custom_command(
|
||||||
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${_file}.def
|
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${_file}.def
|
||||||
|
@ -162,10 +162,7 @@ MACRO(spec2def _dllname _spec_file)
|
||||||
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${_spec_file})
|
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${_spec_file})
|
||||||
set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/${_file}.def
|
set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/${_file}.def
|
||||||
PROPERTIES GENERATED TRUE EXTERNAL_OBJECT TRUE)
|
PROPERTIES GENERATED TRUE EXTERNAL_OBJECT TRUE)
|
||||||
add_custom_target(
|
endmacro()
|
||||||
${_dllname}.def
|
|
||||||
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${_file}.def)
|
|
||||||
ENDMACRO(spec2def _dllname _spec_file)
|
|
||||||
|
|
||||||
# Optional 3rd parameter: dllname
|
# Optional 3rd parameter: dllname
|
||||||
macro(set_export_spec _module _spec_file)
|
macro(set_export_spec _module _spec_file)
|
||||||
|
@ -176,8 +173,6 @@ macro(set_export_spec _module _spec_file)
|
||||||
set(_dllname ${_file}.dll)
|
set(_dllname ${_file}.dll)
|
||||||
endif()
|
endif()
|
||||||
spec2def(${_dllname} ${_spec_file})
|
spec2def(${_dllname} ${_spec_file})
|
||||||
target_link_libraries(${_module} "${CMAKE_CURRENT_BINARY_DIR}/${_file}.def")
|
|
||||||
add_dependencies(${_module} ${_dllname}.def)
|
|
||||||
endmacro()
|
endmacro()
|
||||||
|
|
||||||
#pseh lib, needed with mingw
|
#pseh lib, needed with mingw
|
||||||
|
|
11
msc.cmake
11
msc.cmake
|
@ -148,18 +148,15 @@ macro(add_importlibs MODULE)
|
||||||
endforeach()
|
endforeach()
|
||||||
endmacro()
|
endmacro()
|
||||||
|
|
||||||
MACRO(spec2def _dllname _spec_file)
|
macro(spec2def _dllname _spec_file)
|
||||||
get_filename_component(_file ${_spec_file} NAME_WE)
|
get_filename_component(_file ${_spec_file} NAME_WE)
|
||||||
add_custom_command(
|
add_custom_command(
|
||||||
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${_file}.def
|
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})
|
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${_spec_file})
|
||||||
set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/${_file}.def
|
set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/${_file}.def
|
||||||
PROPERTIES GENERATED TRUE)
|
PROPERTIES GENERATED TRUE)
|
||||||
add_custom_target(
|
endmacro()
|
||||||
${_dllname}.def
|
|
||||||
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${_file}.def)
|
|
||||||
ENDMACRO(spec2def _dllname _spec_file)
|
|
||||||
|
|
||||||
# Optional 3rd parameter: dllname
|
# Optional 3rd parameter: dllname
|
||||||
macro(set_export_spec _module _spec_file)
|
macro(set_export_spec _module _spec_file)
|
||||||
|
@ -170,8 +167,6 @@ macro(set_export_spec _module _spec_file)
|
||||||
set(_dllname ${_file}.dll)
|
set(_dllname ${_file}.dll)
|
||||||
endif()
|
endif()
|
||||||
spec2def(${_dllname} ${_spec_file})
|
spec2def(${_dllname} ${_spec_file})
|
||||||
add_linkerflag(${_module} "/DEF:${CMAKE_CURRENT_BINARY_DIR}/${_file}.def")
|
|
||||||
add_dependencies(${_module} ${_dllname}.def)
|
|
||||||
endmacro()
|
endmacro()
|
||||||
|
|
||||||
file(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/importlibs)
|
file(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/importlibs)
|
||||||
|
|
Loading…
Reference in a new issue