[CMAKE]
[reactos.git] / reactos / drivers / usb / usbohci / CMakeLists.txt
1
2 set_cpp()
3
4 remove_definitions(-D_WIN32_WINNT=0x502)
5 add_definitions(-D_WIN32_WINNT=0x600)
6
7 include_directories(${REACTOS_SOURCE_DIR}/lib/drivers/libusb)
8
9 list(APPEND SOURCE
10 usbohci.cpp
11 usb_request.cpp
12 usb_queue.cpp
13 hardware.cpp)
14
15 add_library(usbohci SHARED
16 ${SOURCE}
17 usbohci.rc)
18
19 target_link_libraries(usbohci
20 libusb
21 libcntpr
22 ${PSEH_LIB})
23
24 # FIXME: http://www.cmake.org/Bug/view.php?id=12998
25 if(MSVC)
26 #add_target_compile_flags(usbohci "/GR-")
27 set_source_files_properties(${SOURCE} PROPERTIES COMPILE_FLAGS "/GR-")
28 else()
29 target_link_libraries(usbohci -lgcc)
30 #add_target_compile_flags(usbohci "-fno-exceptions -fno-rtti")
31 set_source_files_properties(${SOURCE} PROPERTIES COMPILE_FLAGS "-fno-exceptions -fno-rtti")
32 endif()
33
34 set_module_type(usbohci kernelmodedriver)
35 add_importlibs(usbohci ntoskrnl hal usbd)
36
37 add_cd_file(TARGET usbohci DESTINATION reactos/system32/drivers NO_CAB FOR all)