aboutsummaryrefslogtreecommitdiffstats
path: root/cmake/FindOSS.cmake
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2014-04-19 06:35:14 -0700
committerChris Robinson <[email protected]>2014-04-19 06:35:14 -0700
commit887763e41c953b91105bba119da7a7265815f5e0 (patch)
tree8443332ee06bf28e78fe5e34baf66e55b18b42a5 /cmake/FindOSS.cmake
parent1d266aa8347fadfb0db34ae27df7b728c0ab2171 (diff)
Use find cmake modules for more backends
Diffstat (limited to 'cmake/FindOSS.cmake')
-rw-r--r--cmake/FindOSS.cmake21
1 files changed, 21 insertions, 0 deletions
diff --git a/cmake/FindOSS.cmake b/cmake/FindOSS.cmake
new file mode 100644
index 00000000..88ee66ad
--- /dev/null
+++ b/cmake/FindOSS.cmake
@@ -0,0 +1,21 @@
+# - Find OSS includes
+#
+# OSS_FOUND - True if OSS_INCLUDE_DIR is found
+# OSS_INCLUDE_DIRS - Set when OSS_INCLUDE_DIR is found
+#
+# OSS_INCLUDE_DIR - where to find sys/soundcard.h, etc.
+#
+
+find_path(OSS_INCLUDE_DIR
+ NAMES sys/soundcard.h
+ DOC "The OSS include directory"
+)
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(OSS REQUIRED_VARS OSS_INCLUDE_DIR)
+
+if(OSS_FOUND)
+ set(OSS_INCLUDE_DIRS ${OSS_INCLUDE_DIR})
+endif()
+
+mark_as_advanced(OSS_INCLUDE_DIR)