summaryrefslogtreecommitdiffstats
path: root/FindUECC.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'FindUECC.cmake')
-rw-r--r--FindUECC.cmake16
1 files changed, 16 insertions, 0 deletions
diff --git a/FindUECC.cmake b/FindUECC.cmake
new file mode 100644
index 0000000..269c8f7
--- /dev/null
+++ b/FindUECC.cmake
@@ -0,0 +1,16 @@
+FIND_PATH(UECC_INCLUDE_DIR libuecc/ecc.h)
+FIND_LIBRARY(UECC_LIBRARY NAMES uecc)
+
+IF (UECC_INCLUDE_DIR AND UECC_LIBRARY)
+ SET(UECC_FOUND TRUE)
+ENDIF (UECC_INCLUDE_DIR AND UECC_LIBRARY)
+
+IF (UECC_FOUND)
+ IF (NOT UECC_FIND_QUIETLY)
+ MESSAGE(STATUS "Found libuecc: ${UECC_LIBRARY}; include path: ${UECC_INCLUDE_DIR}")
+ ENDIF (NOT UECC_FIND_QUIETLY)
+ELSE (UECC_FOUND)
+ IF (UECC_FIND_REQUIRED)
+ MESSAGE(FATAL_ERROR "Could not find libuecc")
+ ENDIF (UECC_FIND_REQUIRED)
+ENDIF (UECC_FOUND)