xref: /reactos/dll/win32/vbscript/CMakeLists.txt (revision 94a413ae)
1
2add_definitions(-D__WINESRC__ -D__ROS_LONG64__)
3include_directories(${REACTOS_SOURCE_DIR}/sdk/include/reactos/wine)
4spec2def(vbscript.dll vbscript.spec)
5
6list(APPEND SOURCE
7    compile.c
8    global.c
9    interp.c
10    lex.c
11    regexp.c
12    utils.c
13    vbdisp.c
14    vbregexp.c
15    vbscript.c
16    vbscript_main.c)
17
18list(APPEND PCH_SKIP_SOURCE
19    parser.tab.c)
20
21# parser.tab.c has been generated with relative file paths...
22set_source_files_properties(parser.tab.c PROPERTIES COMPILE_FLAGS "-UREACTOS_SOURCE_DIR -DREACTOS_SOURCE_DIR=\"\\\".\\\"\"")
23
24list(APPEND vbscript_rc_deps
25    ${CMAKE_CURRENT_SOURCE_DIR}/vbscript_classes.rgs
26    ${CMAKE_CURRENT_SOURCE_DIR}/vbsglobal.rgs
27    ${CMAKE_CURRENT_SOURCE_DIR}/vbsregexp10.rgs
28    ${CMAKE_CURRENT_SOURCE_DIR}/vbsregexp55.rgs
29    ${CMAKE_CURRENT_BINARY_DIR}/vbsglobal.tlb
30    ${CMAKE_CURRENT_BINARY_DIR}/vbsregexp10.tlb
31    ${CMAKE_CURRENT_BINARY_DIR}/vbsregexp55.tlb)
32
33set_source_files_properties(vbscript.rc PROPERTIES OBJECT_DEPENDS "${vbscript_rc_deps}")
34add_idl_headers(vbscript_idlheader vbscript_classes.idl vbsglobal.idl vbsregexp55.idl)
35add_typelib(vbsglobal.idl vbsregexp10.idl vbsregexp55.idl)
36
37add_library(vbscript MODULE
38    ${SOURCE}
39    ${PCH_SKIP_SOURCE}
40    vbscript.rc
41    ${CMAKE_CURRENT_BINARY_DIR}/vbscript.def)
42
43set_module_type(vbscript win32dll)
44target_link_libraries(vbscript uuid wine)
45add_importlibs(vbscript oleaut32 ole32 user32 msvcrt kernel32 ntdll)
46add_dependencies(vbscript vbscript_idlheader stdole2)
47add_pch(vbscript precomp.h "${PCH_SKIP_SOURCE}")
48add_cd_file(TARGET vbscript DESTINATION reactos/system32 FOR all)
49