source: trunk/components/bio-formats-jace/CMakeLists.txt @ 4766

Revision 4766, 1.4 KB checked in by curtis, 11 years ago (diff)

Move Bio-Formats includes into separate header file.

Line 
1#
2# CMakeLists.txt
3#
4
5# CMake build file for bfjace, the Bio-Formats Jace C++ bindings.
6
7cmake_minimum_required(VERSION 2.6)
8
9project(bio-formats-jace)
10
11### determine configuration ###
12
13find_package(JNI)
14
15set(Boost_USE_STATIC_LIBS OFF)
16set(Boost_USE_MULTITHREAD ON)
17find_package(Boost COMPONENTS thread)
18
19include_directories(include jace/include proxies/include
20  ${JAVA_INCLUDE_PATH} ${JAVA_INCLUDE_PATH2} ${Boost_INCLUDE_DIR})
21
22### build Jace C++ library ###
23
24add_subdirectory(jace)
25
26### build Bio-Formats Jace C++ bindings (bfjace) ###
27
28message("-- Bio-Formats Jace source files:")
29file(GLOB_RECURSE BFJACE_SRC proxies/source/*.cpp)
30message("  bfjace source : ${BFJACE_SRC}")
31
32message("")
33
34add_library(bfjace SHARED ${BFJACE_SRC})
35
36set_target_properties(bfjace PROPERTIES
37  COMPILE_FLAGS "-pthread -Wall -fpermissive"
38  LINK_FLAGS "-pthread")
39
40target_link_libraries(bfjace jace)
41
42### build showinf example for testing bfjace ###
43
44add_executable(showinf source/showinf.cpp)
45
46target_link_libraries(showinf bfjace jace
47  ${JAVA_JVM_LIBRARY} ${Boost_LIBRARIES})
48
49### TEMP - build some Jace examples for testing ###
50
51add_executable(example1 source/example1.cpp)
52
53target_link_libraries(example1 bfjace jace
54  ${JAVA_JVM_LIBRARY} ${Boost_LIBRARIES})
55
56add_executable(array_example source/array_example.cpp)
57
58target_link_libraries(array_example bfjace jace
59  ${JAVA_JVM_LIBRARY} ${Boost_LIBRARIES})
Note: See TracBrowser for help on using the repository browser.