# Autogenerated file, run tools/build/setup_cmake.py to regenerate imp_get_process_exit_code("setup_application example_app" status ${PROJECT_BINARY_DIR} COMMAND ${PROJECT_SOURCE_DIR}/tools/build/setup_application.py --name=example_app --datapath=${IMP_DATAPATH} --source=${PROJECT_SOURCE_DIR}) if(${status} EQUAL 0) message("Application IMP.example_app ok") include_directories(${ANN_INCLUDE_PATH} ${BOOST.FILESYSTEM_INCLUDE_PATH} ${BOOST.PROGRAMOPTIONS_INCLUDE_PATH} ${BOOST.RANDOM_INCLUDE_PATH} ${BOOST.REGEX_INCLUDE_PATH} ${BOOST.SYSTEM_INCLUDE_PATH} ${CGAL_INCLUDE_PATH} ${GPERFTOOLS_INCLUDE_PATH} ${LOG4CXX_INCLUDE_PATH} ${TCMALLOC_HEAPCHECKER_INCLUDE_PATH} ${TCMALLOC_HEAPPROFILER_INCLUDE_PATH} ) link_directories(${ANN_LINK_PATH} ${BOOST.FILESYSTEM_LINK_PATH} ${BOOST.PROGRAMOPTIONS_LINK_PATH} ${BOOST.RANDOM_LINK_PATH} ${BOOST.REGEX_LINK_PATH} ${BOOST.SYSTEM_LINK_PATH} ${CGAL_LINK_PATH} ${GPERFTOOLS_LINK_PATH} ${LOG4CXX_LINK_PATH} ${TCMALLOC_HEAPCHECKER_LINK_PATH} ${TCMALLOC_HEAPPROFILER_LINK_PATH}) if(${IMP_SPLIT_PYTHON_TESTS}) imp_execute_process("get_python_tests example_app" ${PROJECT_BINARY_DIR} COMMAND ${PROJECT_SOURCE_DIR}/tools/build/get_python_tests.py --application=example_app ${PROJECT_SOURCE_DIR}) endif() add_executable("imp_example_app" ${PROJECT_SOURCE_DIR}/applications/example_app/imp_example_app.cpp) target_link_libraries(imp_example_app ${IMP_ATOM_LIBRARY} ${IMP_CONTAINER_LIBRARY} ${IMP_BASE_LIBRARY} ${IMP_CGAL_LIBRARY} ${IMP_ALGEBRA_LIBRARY} ${IMP_KERNEL_LIBRARY} ${IMP_DISPLAY_LIBRARY} ${IMP_SCORE_FUNCTOR_LIBRARY} ${IMP_CORE_LIBRARY} ${IMP_CONTAINER_LIBRARY} ${BOOST.FILESYSTEM_LIBRARIES} ${BOOST.REGEX_LIBRARIES} ${BOOST.PROGRAMOPTIONS_LIBRARIES} ${BOOST.SYSTEM_LIBRARIES} ${GPERFTOOLS_LIBRARIES} ${TCMALLOC_HEAPPROFILER_LIBRARIES} ${TCMALLOC_HEAPCHECKER_LIBRARIES} ${LOG4CXX_LIBRARIES} ${BOOST.RANDOM_LIBRARIES} ${CGAL_LIBRARIES} ${ANN_LIBRARIES}) set_target_properties(imp_example_app PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/bin") install(TARGETS imp_example_app DESTINATION ${CMAKE_INSTALL_BINDIR}) set(bins ${bins} imp_example_app) add_custom_target("IMP.example_app" ALL DEPENDS ${bins}) set(pybins ${PROJECT_SOURCE_DIR}/applications/example_app/dependencies.py) foreach (pybin ${pybins}) install(PROGRAMS ${pybin} DESTINATION ${CMAKE_INSTALL_BINDIR}) endforeach(pybin) set(pytests ${PROJECT_SOURCE_DIR}/applications/example_app/test/test_example.py) foreach (test ${pytests}) GET_FILENAME_COMPONENT(name ${test} NAME_WE) if(EXISTS "${PROJECT_BINARY_DIR}/test/example_app/${name}.pytests") FILE(READ "${PROJECT_BINARY_DIR}/test/example_app/${name}.pytests" contents) STRING(REGEX REPLACE ";" "\\\\;" contents "${contents}") STRING(REGEX REPLACE "\n" ";" contents "${contents}") foreach(testline ${contents}) string(REGEX REPLACE "([A-Za-z0-9_]+\\.[A-Za-z0-9_]+) (.*)" "\\1;\\2" split "${testline}") list(GET split 0 methname) list(GET split 1 docstring) add_test("example_app.${name}.${methname}" ${IMP_TEST_SETUP} python ${test} "${methname}") set_tests_properties("example_app.${name}.${methname}" PROPERTIES LABELS "IMP.example_app;test") set_tests_properties("example_app.${name}.${methname}" PROPERTIES MEASUREMENT "docstring=${docstring}") endforeach() else() add_test("example_app.${name}" ${IMP_TEST_SETUP} python ${test}) set_tests_properties("example_app.${name}" PROPERTIES LABELS "IMP.example_app;test") endif() endforeach(test) elseif(${status} EQUAL 1) message("Application example_app disabled") else() message(FATAL_ERROR "setup_application failed ${status}") endif()