Last change
on this file since 1294 was 1294, checked in by rorothetroll, 14 years ago |
added the base for the new code for the smartreader. The code isn't called yet
|
File size:
1.2 KB
|
Rev | Line | |
---|
[102] | 1 | project (csctapi)
|
---|
| 2 |
|
---|
| 3 | file (GLOB csctapi_srcs "*.c")
|
---|
| 4 | file (GLOB csctapi_hdrs "*.h")
|
---|
| 5 |
|
---|
[1188] | 6 | check_include_file ("usb.h" HAVE_LIBUSB)
|
---|
| 7 | if (HAVE_LIBUSB)
|
---|
| 8 | add_definitions ("-DHAVE_LIBUSB")
|
---|
| 9 | endif (HAVE_LIBUSB)
|
---|
| 10 |
|
---|
| 11 | if (HAVE_LIBUSB)
|
---|
| 12 | target_link_libraries (${exe_name} usb)
|
---|
| 13 | endif (HAVE_LIBUSB)
|
---|
| 14 |
|
---|
[998] | 15 | if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
|
---|
[1188] | 16 | add_definitions ("-O2 -Winline -Werror -finline-functions -fomit-frame-pointer -s -m32")
|
---|
| 17 | SET( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -m32" )
|
---|
[1294] | 18 |
|
---|
[1188] | 19 | FIND_PATH( USB_INCLUDE usb.h)
|
---|
| 20 | if( ${USB_INCLUDE} MATCHES "USB_INCLUDE-NOTFOUND" )
|
---|
| 21 | set (HAVE_LIBUSB "0")
|
---|
| 22 | else ( ${USB_INCLUDE} MATCHES "USB_INCLUDE-NOTFOUND" )
|
---|
| 23 | FIND_LIBRARY (USB_LIBRARY usb)
|
---|
| 24 | target_link_libraries ( ${exe_name} ${USB_LIBRARY})
|
---|
[1294] | 25 | include_directories( SYSTEM ${USB_INCLUDE})
|
---|
[1188] | 26 | set (HAVE_LIBUSB "1")
|
---|
[1198] | 27 | add_definitions ("-DHAVE_LIBUSB")
|
---|
[1188] | 28 | endif ( ${USB_INCLUDE} MATCHES "USB_INCLUDE-NOTFOUND" )
|
---|
[998] | 29 | else (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
|
---|
[1188] | 30 | add_definitions ("-O2 -Winline -Werror -finline-functions -fomit-frame-pointer -s")
|
---|
[998] | 31 | endif (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
|
---|
[122] | 32 |
|
---|
[102] | 33 | set (lib_name "csctapi")
|
---|
| 34 | add_library (${lib_name} STATIC ${csctapi_srcs} ${csctapi_hdrs})
|
---|
| 35 |
|
---|
Note:
See
TracBrowser
for help on using the repository browser.