FRAT/Library: Difference between revisions
From KitwarePublic
< FRAT
Jump to navigationJump to search
Line 31: | Line 31: | ||
= FRAT Library = | = FRAT Library = | ||
In addition to command line executables, FRAT provides a C++ library that can be used in external projects. Since FRAT is currently only available as source code, you must first follow the instructions in the [[FRAT/Install_Guide | Installation Guide]] to build libFrat. Once built, the | In addition to command line executables, FRAT provides a C++ library that can be used in external projects. Since FRAT is currently only available as source code, you must first follow the instructions in the [[FRAT/Install_Guide | Installation Guide]] to build libFrat. Once built, the steps for using FRAT in your own CMake project are: | ||
* In your CMakeLists.txt file, find the FRAT project | * In your CMakeLists.txt file, find the FRAT project |
Revision as of 22:26, 11 August 2011
__NOTITLE__
|
FRAT LibraryIn addition to command line executables, FRAT provides a C++ library that can be used in external projects. Since FRAT is currently only available as source code, you must first follow the instructions in the Installation Guide to build libFrat. Once built, the steps for using FRAT in your own CMake project are:
find_package(FRAT REQUIRED) if(FRAT_FOUND) include(${FRAT_USE_FILE}) else(FRAT_FOUND) message(FATAL_ERROR "FRAT not found. Please set FRAT_DIR.") endif(FRAT_FOUND)
add_library(bar bar.cxx) target_link_libraries(bar ${FRAT_LIBRARIES}) add_executable(foo foo.cxx) target_link_libraries(foo bar ${FRAT_LIBRARIES})
|