aboutsummaryrefslogtreecommitdiff
path: root/CMake/FindFDIP.cmake
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2018-03-12 09:48:00 +0100
committerThomas White <taw@physics.org>2018-03-12 10:17:49 +0100
commit753ceccfb4517ae0aa4445c18ae34ca52171f28d (patch)
treea2928d9de6f10813b97363ea401cc72625ed3ce2 /CMake/FindFDIP.cmake
parent95bb73d90fed58f61dddc0d1d3e8afeb9879daaa (diff)
Add CMake
Diffstat (limited to 'CMake/FindFDIP.cmake')
-rw-r--r--CMake/FindFDIP.cmake27
1 files changed, 27 insertions, 0 deletions
diff --git a/CMake/FindFDIP.cmake b/CMake/FindFDIP.cmake
new file mode 100644
index 00000000..fb38e0db
--- /dev/null
+++ b/CMake/FindFDIP.cmake
@@ -0,0 +1,27 @@
+# - Find FDIP
+# Find the native FDIP includes and library
+#
+# FDIP_INCLUDES - where to find streakFinder.h
+# FDIP_LIBRARIES - List of libraries when using FDIP.
+# FDIP_FOUND - True if FDIP found.
+
+if (FDIP_INCLUDES)
+ # Already in cache, be silent
+ set (FDIP_FIND_QUIETLY TRUE)
+endif (FDIP_INCLUDES)
+
+find_path (FDIP_INCLUDES streakFinder.h
+ PATHS
+ ${CMAKE_INSTALL_PREFIX}/include
+ PATH_SUFFIXES fastDiffractionImageProcessing)
+
+find_library (FDIP_LIBRARIES fastDiffractionImageProcessing
+ PATHS
+ ${CMAKE_INSTALL_PREFIX}/lib)
+
+# handle the QUIETLY and REQUIRED arguments and set FDIP_FOUND to TRUE if
+# all listed variables are TRUE
+include (FindPackageHandleStandardArgs)
+find_package_handle_standard_args (FDIP DEFAULT_MSG FDIP_LIBRARIES FDIP_INCLUDES)
+
+mark_as_advanced (FDIP_LIBRARIES FDIP_INCLUDES)