Revision ebf5b65f

View differences:

.gitignore
12 12
CMakeFiles
13 13
core
14 14
.egg*
15
*.egg
client/CMakeLists.txt
1
CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
2

  
3
PROJECT("hlrc_client")
4

  
5
SET(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS TRUE)
6

  
7
#options
8
OPTION(BUILD_CPP "Decide whether to build the CPP bindings." ON)
9
OPTION(BUILD_JAVA "Decide whether to build the Java bindings." ON)
10
OPTION(BUILD_PYTHON "Decide whether to build the Python bindings." ON)
11

  
12

  
13

  
14
IF(BUILD_CPP)
15
    ADD_SUBDIRECTORY(cpp)
16
ENDIF()
17

  
18
IF(BUILD_JAVA)
19
    ADD_SUBDIRECTORY(java)
20
ENDIF()
21

  
22
IF(BUILD_PYTHON)
23
    ADD_SUBDIRECTORY(python)
24
ENDIF()
25

  
26

  
27

  
client/java/CMakeLists.txt
1
cmake_minimum_required(VERSION 2.8)
2

  
3
SET(JAR_FILE "${CMAKE_CURRENT_BINARY_DIR}/hlrc_client_java-0.1.jar" )
4

  
5
FIND_PROGRAM(MVN_EXECUTABLE mvn)
6
IF(MVN_EXECUTABLE)
7
    ADD_CUSTOM_COMMAND(OUTPUT  ${JAR_FILE}
8
                       COMMAND ${MVN_EXECUTABLE} install appassembler::assemble
9
                       WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
10
                       COMMENT "Creating jar files")
11

  
12
    ADD_CUSTOM_TARGET(java ALL DEPENDS ${JAR_FILE})
13

  
14
    INSTALL(FILES ${JAR_FILE} DESTINATION share/java)
15

  
16
ELSE()
17
    MESSAGE(STATUS "mvn not found. java bindings will not be created")
18
ENDIF()
19

  
client/python/CMakeLists.txt
1
cmake_minimum_required(VERSION 2.8)
2

  
3
install(CODE "execute_process(COMMAND python setup.py install -f --prefix=${CMAKE_INSTALL_PREFIX} WORKING_DIRECTORY ${PROJECT_SOURCE_DIR})")

Also available in: Unified diff