[CMAKE]
[reactos.git] / reactos / dll / directx / wine / ddraw / CMakeLists.txt
1
2 add_definitions(
3 -D__WINESRC__
4 -DUSE_WIN32_OPENGL)
5
6 include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine)
7
8 set_rc_compiler()
9
10 spec2def(ddraw.dll ddraw.spec ADD_IMPORTLIB)
11
12 list(APPEND SOURCE
13 clipper.c
14 ddraw.c
15 device.c
16 executebuffer.c
17 light.c
18 main.c
19 material.c
20 palette.c
21 stubs.c
22 surface.c
23 utils.c
24 vertexbuffer.c
25 viewport.c
26 ${CMAKE_CURRENT_BINARY_DIR}/ddraw_stubs.c
27 ${CMAKE_CURRENT_BINARY_DIR}/ddraw.def)
28
29 add_library(ddraw SHARED
30 ${SOURCE}
31 ddraw.rc)
32
33 if(MSVC)
34 # FIXME: http://www.cmake.org/Bug/view.php?id=12998
35 #add_target_compile_flags(ddraw "/FIwine/typeof.h")
36 set_source_files_properties(${SOURCE} PROPERTIES COMPILE_FLAGS "/FIwine/typeof.h")
37 endif()
38
39 set_module_type(ddraw win32dll)
40
41 target_link_libraries(ddraw
42 wine
43 uuid
44 dxguid
45 ${PSEH_LIB})
46
47 add_importlibs(ddraw
48 advapi32
49 gdi32
50 ole32
51 user32
52 wined3d
53 msvcrt
54 kernel32
55 ntdll)
56
57 add_dependencies(ddraw wineheaders)
58 add_pch(ddraw ddraw_private.h)
59 add_cd_file(TARGET ddraw DESTINATION reactos/system32 FOR all)