df2a5577c7b21d56f74258ce275f18bea22594b2
[reactos.git] / reactos / drivers / storage / classpnp / CMakeLists.txt
1
2 include_directories(../inc)
3
4 add_definitions(
5 -DCLASS_GLOBAL_BREAK_ON_LOST_IRPS=0
6 -DCLASS_GLOBAL_SECONDS_TO_WAIT_FOR_SYNCHRONOUS_SRB=100
7 -DCLASS_GLOBAL_USE_DELAYED_RETRY=1
8 -DCLASS_GLOBAL_BUFFERED_DEBUG_PRINT=0
9 -DCLASS_GLOBAL_BUFFERED_DEBUG_PRINT_BUFFER_SIZE=512
10 -DCLASS_GLOBAL_BUFFERED_DEBUG_PRINT_BUFFERS=512)
11
12 spec2def(classpnp.sys classpnp.spec ADD_IMPORTLIB)
13
14 list(APPEND SOURCE
15 autorun.c
16 class.c
17 classwmi.c
18 clntirp.c
19 create.c
20 data.c
21 debug.c
22 dictlib.c
23 lock.c
24 obsolete.c
25 power.c
26 retry.c
27 utils.c
28 xferpkt.c
29 ${CMAKE_CURRENT_BINARY_DIR}/classpnp.def)
30
31 add_library(classpnp SHARED
32 ${SOURCE}
33 class.rc)
34
35 if(ARCH MATCHES i386)
36 if(MSVC)
37 add_target_compile_flags(classpnp "/Gz")
38 else()
39 # FIXME: http://www.cmake.org/Bug/view.php?id=12998
40 #add_target_compile_flags(classpnp "-mrtd -fno-builtin -w")
41 set_source_files_properties(${SOURCE} PROPERTIES COMPILE_FLAGS "-mrtd -fno-builtin -w")
42 endif()
43 endif()
44
45 add_pch(classpnp classp.h)
46 target_link_libraries(classpnp ${PSEH_LIB} libcntpr)
47 set_module_type(classpnp kernelmodedriver)
48 add_importlibs(classpnp hal ntoskrnl)
49
50 add_cd_file(TARGET classpnp DESTINATION reactos/system32/drivers NO_CAB FOR all)