8a41972e7ddbda2fd687f50132e3a010f01fcafa
[reactos.git] / include / asm / CMakeLists.txt
1
2 add_library(genincdata SHARED genincdata.c)
3
4 set_entrypoint(genincdata DummyEntry)
5 add_dependencies(genincdata bugcodes)
6
7 if(MSVC)
8 set(OPT_MS "-ms")
9 else()
10 set(OPT_MS "")
11 endif()
12
13 if(ARCH MATCHES i386)
14 set(_filename ks386)
15 elseif(ARCH MATCHES amd64)
16 set(_filename ksamd64)
17 endif()
18
19 add_custom_command(
20 OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${_filename}.inc
21 COMMAND native-geninc ${CMAKE_CURRENT_BINARY_DIR}/genincdata.dll ${CMAKE_CURRENT_BINARY_DIR}/${_filename}.inc ${OPT_MS}
22 DEPENDS genincdata)
23
24 add_custom_target(asm
25 DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${_filename}.inc)