diff --git a/CMakeLists.txt b/CMakeLists.txt index 8a4521b7bd2294cd2af16ce6a7966de8cc8857b2..616402d5012a8bc50dc01a37b19cc3b32b724b52 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -31,10 +31,10 @@ ENDIF(WIN32) # ---------------------------------------------------- # --- DEPENDANCIES ----------------------------------- # ---------------------------------------------------- -ADD_REQUIRED_DEPENDENCY("eigenpy >= v1.0.1") +ADD_REQUIRED_DEPENDENCY("eigenpy >= v1.2.0") ADD_REQUIRED_DEPENDENCY("urdfdom >= v0.3.0") ADD_REQUIRED_DEPENDENCY("eigen3 >= v3.0.5") - + # ---------------------------------------------------- # --- BENCHMARKS ------------------------------------- # ---------------------------------------------------- @@ -141,29 +141,26 @@ FOREACH(python ${PYTHON_FILES}) ${${PROJECT_NAME}_BINARY_DIR}/lib/python/${PROJECT_NAME}/${pythonFile}) # Tag pyc file as generated. - #SET_SOURCE_FILES_PROPERTIES( - # "${CMAKE_CURRENT_BINARY_DIR}/lib/python/${pythonFile}c" - # PROPERTIES GENERATED TRUE) + SET_SOURCE_FILES_PROPERTIES( + "${CMAKE_CURRENT_BINARY_DIR}/lib/python/${PROJECT_NAME}/${pythonFile}c" + PROPERTIES GENERATED TRUE) - # Clean generated files. - #SET_PROPERTY( - # DIRECTORY APPEND PROPERTY - # ADDITIONAL_MAKE_CLEAN_FILES - # "${CMAKE_CURRENT_BINARY_DIR}/lib/python/${pythonFile}c") + EXECUTE_PROCESS(COMMAND + ${PYTHON_EXECUTABLE} -m py_compile + ${CMAKE_CURRENT_BINARY_DIR}/lib/python/${PROJECT_NAME}/${pythonFile} ) - #INSTALL(CODE - # "EXECUTE_PROCESS(COMMAND - # \"${PYTHON_EXECUTABLE}\" - # \"-m py_compile\" - # \"${CMAKE_CURRENT_BINARY_DIR}/lib/python/${pythonFile}\") ") + # Clean generated files. + SET_PROPERTY( + DIRECTORY APPEND PROPERTY + ADDITIONAL_MAKE_CLEAN_FILES + "${CMAKE_CURRENT_BINARY_DIR}/lib/python/${PROJECT_NAME}/${pythonFile}c") INSTALL(FILES "${CMAKE_CURRENT_BINARY_DIR}/lib/python/${PROJECT_NAME}/${pythonFile}" - # "${CMAKE_CURRENT_BINARY_DIR}/lib/python/${pythonFile}c" + "${CMAKE_CURRENT_BINARY_DIR}/lib/python/${PROJECT_NAME}/${pythonFile}c" DESTINATION ${PYTHON_SITELIB}/${PROJECT_NAME}) ENDFOREACH(python) - ADD_SUBDIRECTORY(unittest) IF (BUILD_BENCHMARK)