cbe9003f46758b954cbbe5e92452a33cc65047b4
[reactos.git] / dll / apisets / CMakeLists.txt.in
1
2 # This file is generated by update.py, please edit CMakeLists.txt.in instead
3 # Generated from %WINE_GIT_VERSION%
4
5 project(apisets)
6
7 function (add_apiset apiset_name baseaddress)
8 spec2def(${apiset_name}.dll ${apiset_name}.spec ADD_IMPORTLIB)
9
10 add_definitions(
11 -D_CTYPE_DISABLE_MACROS
12 -D_NO_INLINING
13 -D__CRT__NO_INLINE
14 -D__STDC_WANT_SECURE_LIB__=0
15 -D_INC_STRING
16 -D_CTYPE_DEFINED
17 -D_WCTYPE_DEFINED
18 -D_CRT_ERRNO_DEFINED)
19
20 add_library(${apiset_name} SHARED
21 ${CMAKE_CURRENT_BINARY_DIR}/${apiset_name}_stubs.c
22 ${CMAKE_CURRENT_BINARY_DIR}/${apiset_name}.def)
23
24 add_dependencies(${apiset_name} xdk)
25 set_module_type(${apiset_name} win32dll ENTRYPOINT 0 UNICODE IMAGEBASE ${baseaddress})
26
27 if(NOT MSVC)
28 add_target_compile_flags(${apiset_name} "-fno-builtin")
29 else()
30 add_target_compile_flags(${apiset_name} "/wd4026 /wd4273")
31 endif()
32
33 add_importlibs(${apiset_name} ${ARGN} kernel32 ntdll)
34
35 add_cd_file(TARGET ${apiset_name} DESTINATION reactos/winsxs/x86_reactos.apisets_6595b64144ccf1df_1.0.0.0_none_deadbeef FOR all)
36 endfunction()
37
38 add_cd_file(FILE ${CMAKE_CURRENT_SOURCE_DIR}/x86_reactos.apisets_6595b64144ccf1df_1.0.0.0_none_deadbeef.manifest DESTINATION reactos/winsxs/manifests FOR all)
39
40 # Apisets will be appended
41