aboutsummaryrefslogtreecommitdiffstats
path: root/cmake/Modules/FindLibFec.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'cmake/Modules/FindLibFec.cmake')
-rw-r--r--cmake/Modules/FindLibFec.cmake24
1 files changed, 24 insertions, 0 deletions
diff --git a/cmake/Modules/FindLibFec.cmake b/cmake/Modules/FindLibFec.cmake
new file mode 100644
index 000000000..f8b33ad6b
--- /dev/null
+++ b/cmake/Modules/FindLibFec.cmake
@@ -0,0 +1,24 @@
+set(LIBFEC_SEARCH_PATH_LIST
+ ${LIBFEC_HOME}
+ $ENV{DEPENDENCIES}
+ $ENV{LIBFEC_HOME}
+ /usr/local
+ /opt
+ /usr
+ )
+
+find_path(LIBFEC_INCLUDE_DIR fec/version.h
+ HINTS ${LIBFEC_SEARCH_PATH_LIST}
+ PATH_SUFFIXES include
+ DOC "Find the LibFec includes" )
+
+find_library(LIBFEC_LIBRARY NAMES fec
+ HINTS ${LIBFEC_SEARCH_PATH_LIST}
+ PATH_SUFFIXES lib
+ DOC "Find the LibFec libraries" )
+
+set(LIBFEC_LIBRARIES ${LIBFEC_LIBRARY})
+set(LIBFEC_INCLUDE_DIRS ${LIBFEC_INCLUDE_DIR})
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(LibFec DEFAULT_MSG LIBFEC_LIBRARY LIBFEC_INCLUDE_DIR) \ No newline at end of file