summaryrefslogtreecommitdiff
path: root/CMake
diff options
context:
space:
mode:
authorbsegovia <devnull@localhost>2011-07-14 01:27:08 +0000
committerKeith Packard <keithp@keithp.com>2012-08-10 16:14:34 -0700
commit5173febb3d88b6c38709d390c3b30c79442afd7b (patch)
tree1f3cdd7f6254f8c22787376b9bbda2cf133e97f7 /CMake
parent27d817aabaedebd2b2601d65e34c3ad1364e6101 (diff)
Added all miniCL files
Diffstat (limited to 'CMake')
-rw-r--r--CMake/CMakeConfigTemplate.hpp28
-rw-r--r--CMake/FindCPP.cmake25
-rw-r--r--CMake/FindDRM.cmake34
-rw-r--r--CMake/FindDRMIntel.cmake28
-rw-r--r--CMake/FindFlex.cmake27
-rw-r--r--CMake/FindXLib.cmake34
-rw-r--r--CMake/FindXext.cmake27
-rw-r--r--CMake/FindXfixes.cmake27
8 files changed, 230 insertions, 0 deletions
diff --git a/CMake/CMakeConfigTemplate.hpp b/CMake/CMakeConfigTemplate.hpp
new file mode 100644
index 00000000..7702c54d
--- /dev/null
+++ b/CMake/CMakeConfigTemplate.hpp
@@ -0,0 +1,28 @@
+/*
+ * Copyright © 2012 Intel Corporation
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library. If not, see <http://www.gnu.org/licenses/>.
+ *
+ * Author: Benjamin Segovia <benjamin.segovia@intel.com>
+ */
+
+#ifndef CMAKE_CONFIG_HPP
+#define CMAKE_CONFIG_HPP
+
+#define ON true
+#define OFF false
+#define GEN_INSTALLATION_PATH "${CMAKE_INSTALL_PREFIX}/lib/i965/"
+
+#endif /* CMAKE_CONFIG_HPP */
+
diff --git a/CMake/FindCPP.cmake b/CMake/FindCPP.cmake
new file mode 100644
index 00000000..be05064e
--- /dev/null
+++ b/CMake/FindCPP.cmake
@@ -0,0 +1,25 @@
+#
+# Try to find c preprocessor
+# Once done this will define
+#
+# CPP_FOUND
+# CPP_PATH
+#
+
+FIND_PROGRAM(CPP_PATH cpp
+ /bin/
+ /usr/bin/
+ /usr/local/bin
+ ~/bin
+ /opt/local/bin/
+ DOC "The directory where cpp is")
+
+IF(CPP_PATH)
+ SET(CPP_FOUND 1 CACHE STRING "Set to 1 if CPP is found, 0 otherwise")
+ELSE(CPP_PATH)
+ SET(CPP_FOUND 0 CACHE STRING "Set to 1 if CPP is found, 0 otherwise")
+ENDIF(CPP_PATH)
+
+MARK_AS_ADVANCED(CPP_FOUND)
+
+
diff --git a/CMake/FindDRM.cmake b/CMake/FindDRM.cmake
new file mode 100644
index 00000000..87639b6e
--- /dev/null
+++ b/CMake/FindDRM.cmake
@@ -0,0 +1,34 @@
+#
+# Try to find X library and include path.
+# Once done this will define
+#
+# DRM_FOUND
+# DRM_INCLUDE_PATH
+# DRM_LIBRARY
+#
+
+FIND_PATH(DRM_INCLUDE_PATH drm.h
+ /usr/include/libdrm/
+ /usr/local/include/libdrm/
+ /sw/include/libdrm/
+ /opt/local/include/libdrm/
+ DOC "The directory where drm.h resides")
+FIND_LIBRARY(DRM_LIBRARY
+ NAMES DRM drm
+ PATHS
+ /usr/lib64
+ /usr/lib
+ /usr/local/lib64
+ /usr/local/lib
+ /sw/lib
+ /opt/local/lib
+ DOC "The DRM library")
+
+IF(DRM_INCLUDE_PATH)
+ SET(DRM_FOUND 1 CACHE STRING "Set to 1 if DRM is found, 0 otherwise")
+ELSE(DRM_INCLUDE_PATH)
+ SET(DRM_FOUND 0 CACHE STRING "Set to 1 if DRM is found, 0 otherwise")
+ENDIF(DRM_INCLUDE_PATH)
+
+MARK_AS_ADVANCED(DRM_FOUND)
+
diff --git a/CMake/FindDRMIntel.cmake b/CMake/FindDRMIntel.cmake
new file mode 100644
index 00000000..7c5be425
--- /dev/null
+++ b/CMake/FindDRMIntel.cmake
@@ -0,0 +1,28 @@
+#
+# Try to find X library and include path.
+# Once done this will define
+#
+# DRM_INTEL_FOUND
+# DRM_INTEL_INCLUDE_PATH
+#
+
+FIND_LIBRARY(DRM_INTEL_LIBRARY
+ NAMES DRM_INTEL drm_intel
+ PATHS
+ /usr/lib64
+ /usr/lib
+ /usr/local/lib64
+ /usr/local/lib
+ /sw/lib
+ /opt/local/lib
+ /usr/lib/i386-linux-gnu/
+ DOC "The DRM_INTEL library")
+
+IF(DRM_INTEL_INCLUDE_PATH)
+ SET(DRM_INTEL_FOUND 1 CACHE STRING "Set to 1 if DRM_INTEL is found, 0 otherwise")
+ELSE(DRM_INTEL_INCLUDE_PATH)
+ SET(DRM_INTEL_FOUND 0 CACHE STRING "Set to 1 if DRM_INTEL is found, 0 otherwise")
+ENDIF(DRM_INTEL_INCLUDE_PATH)
+
+MARK_AS_ADVANCED(DRM_INTEL_FOUND)
+
diff --git a/CMake/FindFlex.cmake b/CMake/FindFlex.cmake
new file mode 100644
index 00000000..f7972ebe
--- /dev/null
+++ b/CMake/FindFlex.cmake
@@ -0,0 +1,27 @@
+#
+# Try to find X library and include path.
+# Once done this will define
+#
+# FLEX_FOUND
+# FLEX_LIBRARY
+#
+
+FIND_LIBRARY(FLEX_LIBRARY
+ NAMES FLEX fl
+ PATHS
+ /usr/lib64
+ /usr/lib
+ /usr/local/lib64
+ /usr/local/lib
+ /sw/lib
+ /opt/local/lib
+ DOC "The FLEX library")
+
+IF(FLEX_INCLUDE_PATH)
+ SET(FLEX_FOUND 1 CACHE STRING "Set to 1 if FLEX is found, 0 otherwise")
+ELSE(FLEX_INCLUDE_PATH)
+ SET(FLEX_FOUND 0 CACHE STRING "Set to 1 if FLEX is found, 0 otherwise")
+ENDIF(FLEX_INCLUDE_PATH)
+
+MARK_AS_ADVANCED(FLEX_FOUND)
+
diff --git a/CMake/FindXLib.cmake b/CMake/FindXLib.cmake
new file mode 100644
index 00000000..5047a0f3
--- /dev/null
+++ b/CMake/FindXLib.cmake
@@ -0,0 +1,34 @@
+#
+# Try to find X library and include path.
+# Once done this will define
+#
+# XLIB_FOUND
+# XLIB_INCLUDE_PATH
+# XLIB_LIBRARY
+#
+
+FIND_PATH(XLIB_INCLUDE_PATH X11/Xlib.h
+ /usr/include
+ /usr/local/include
+ /sw/include
+ /opt/local/include
+ DOC "The directory where X11/Xlib.h resides")
+FIND_LIBRARY(XLIB_LIBRARY
+ NAMES XLIB X11
+ PATHS
+ /usr/lib64
+ /usr/lib
+ /usr/local/lib64
+ /usr/local/lib
+ /sw/lib
+ /opt/local/lib
+ DOC "The XLIB library")
+
+IF(XLIB_INCLUDE_PATH)
+ SET(XLIB_FOUND 1 CACHE STRING "Set to 1 if XLIB is found, 0 otherwise")
+ELSE(XLIB_INCLUDE_PATH)
+ SET(XLIB_FOUND 0 CACHE STRING "Set to 1 if XLIB is found, 0 otherwise")
+ENDIF(XLIB_INCLUDE_PATH)
+
+MARK_AS_ADVANCED(XLIB_FOUND)
+
diff --git a/CMake/FindXext.cmake b/CMake/FindXext.cmake
new file mode 100644
index 00000000..3f913706
--- /dev/null
+++ b/CMake/FindXext.cmake
@@ -0,0 +1,27 @@
+#
+# Try to find Xext library path.
+# Once done this will define
+#
+# XEXT_FOUND
+# XEXT_LIBRARY
+#
+
+FIND_LIBRARY(XEXT_LIBRARY
+ NAMES XEXT Xext
+ PATHS
+ /usr/lib64
+ /usr/lib
+ /usr/local/lib64
+ /usr/local/lib
+ /sw/lib
+ /opt/local/lib
+ DOC "The XEXT library")
+
+IF(XEXT_INCLUDE_PATH)
+ SET(XEXT_FOUND 1 CACHE STRING "Set to 1 if XEXT is found, 0 otherwise")
+ELSE(XEXT_INCLUDE_PATH)
+ SET(XEXT_FOUND 0 CACHE STRING "Set to 1 if XEXT is found, 0 otherwise")
+ENDIF(XEXT_INCLUDE_PATH)
+
+MARK_AS_ADVANCED(XEXT_FOUND)
+
diff --git a/CMake/FindXfixes.cmake b/CMake/FindXfixes.cmake
new file mode 100644
index 00000000..8bce1d60
--- /dev/null
+++ b/CMake/FindXfixes.cmake
@@ -0,0 +1,27 @@
+#
+# Try to find Xfixes library path.
+# Once done this will define
+#
+# XFIXES_FOUND
+# XFIXES_LIBRARY
+#
+
+FIND_LIBRARY(XFIXES_LIBRARY
+ NAMES XFIXES Xfixes
+ PATHS
+ /usr/lib64
+ /usr/lib
+ /usr/local/lib64
+ /usr/local/lib
+ /sw/lib
+ /opt/local/lib
+ DOC "The XFIXES library")
+
+IF(XFIXES_INCLUDE_PATH)
+ SET(XFIXES_FOUND 1 CACHE STRING "Set to 1 if XFIXES is found, 0 otherwise")
+ELSE(XFIXES_INCLUDE_PATH)
+ SET(XFIXES_FOUND 0 CACHE STRING "Set to 1 if XFIXES is found, 0 otherwise")
+ENDIF(XFIXES_INCLUDE_PATH)
+
+MARK_AS_ADVANCED(XFIXES_FOUND)
+