aboutsummaryrefslogtreecommitdiff
path: root/cmake
diff options
context:
space:
mode:
Diffstat (limited to 'cmake')
-rw-r--r--cmake/Modules/FindOpenGLES2.cmake73
-rw-r--r--cmake/Modules/FindSQLite3.cmake2
-rw-r--r--cmake/Modules/FindVorbis.cmake17
-rw-r--r--cmake/Modules/MinetestFindIrrlichtHeaders.cmake26
4 files changed, 18 insertions, 100 deletions
diff --git a/cmake/Modules/FindOpenGLES2.cmake b/cmake/Modules/FindOpenGLES2.cmake
deleted file mode 100644
index ce04191dd..000000000
--- a/cmake/Modules/FindOpenGLES2.cmake
+++ /dev/null
@@ -1,73 +0,0 @@
-#-------------------------------------------------------------------
-# The contents of this file are placed in the public domain. Feel
-# free to make use of it in any way you like.
-#-------------------------------------------------------------------
-
-# - Try to find OpenGLES and EGL
-# Once done this will define
-#
-# OPENGLES2_FOUND - system has OpenGLES
-# OPENGLES2_INCLUDE_DIR - the GL include directory
-# OPENGLES2_LIBRARIES - Link these to use OpenGLES
-#
-# EGL_FOUND - system has EGL
-# EGL_INCLUDE_DIR - the EGL include directory
-# EGL_LIBRARIES - Link these to use EGL
-
-# Win32 and Apple are not tested!
-# Linux tested and works
-
-if(WIN32)
- find_path(OPENGLES2_INCLUDE_DIR GLES2/gl2.h)
- find_library(OPENGLES2_LIBRARY libGLESv2)
-elseif(APPLE)
- create_search_paths(/Developer/Platforms)
- findpkg_framework(OpenGLES2)
- set(OPENGLES2_LIBRARY "-framework OpenGLES")
-else()
- # Unix
- find_path(OPENGLES2_INCLUDE_DIR GLES2/gl2.h
- PATHS /usr/openwin/share/include
- /opt/graphics/OpenGL/include
- /usr/X11R6/include
- /usr/include
- )
-
- find_library(OPENGLES2_LIBRARY
- NAMES GLESv2
- PATHS /opt/graphics/OpenGL/lib
- /usr/openwin/lib
- /usr/X11R6/lib
- /usr/lib
- )
-
- include(FindPackageHandleStandardArgs)
- find_package_handle_standard_args(OpenGLES2 DEFAULT_MSG OPENGLES2_LIBRARY OPENGLES2_INCLUDE_DIR)
-
- find_path(EGL_INCLUDE_DIR EGL/egl.h
- PATHS /usr/openwin/share/include
- /opt/graphics/OpenGL/include
- /usr/X11R6/include
- /usr/include
- )
-
- find_library(EGL_LIBRARY
- NAMES EGL
- PATHS /opt/graphics/OpenGL/lib
- /usr/openwin/lib
- /usr/X11R6/lib
- /usr/lib
- )
-
- find_package_handle_standard_args(EGL DEFAULT_MSG EGL_LIBRARY EGL_INCLUDE_DIR)
-endif()
-
-set(OPENGLES2_LIBRARIES ${OPENGLES2_LIBRARY})
-set(EGL_LIBRARIES ${EGL_LIBRARY})
-
-mark_as_advanced(
- OPENGLES2_INCLUDE_DIR
- OPENGLES2_LIBRARY
- EGL_INCLUDE_DIR
- EGL_LIBRARY
-)
diff --git a/cmake/Modules/FindSQLite3.cmake b/cmake/Modules/FindSQLite3.cmake
index b23553a80..8a66cb241 100644
--- a/cmake/Modules/FindSQLite3.cmake
+++ b/cmake/Modules/FindSQLite3.cmake
@@ -1,4 +1,4 @@
-mark_as_advanced(SQLITE3_LIBRARY SQLITE3_INCLUDE_DIR)
+mark_as_advanced(SQLITE3_LIBRARY SQLITE3_INCLUDE_DIR)
find_path(SQLITE3_INCLUDE_DIR sqlite3.h)
diff --git a/cmake/Modules/FindVorbis.cmake b/cmake/Modules/FindVorbis.cmake
index e5fe7f25e..222ddd9d5 100644
--- a/cmake/Modules/FindVorbis.cmake
+++ b/cmake/Modules/FindVorbis.cmake
@@ -29,18 +29,17 @@ else(NOT GP2XWIZ)
find_package_handle_standard_args(Vorbis DEFAULT_MSG
VORBIS_INCLUDE_DIR VORBIS_LIBRARY)
endif(NOT GP2XWIZ)
-
+
if(VORBIS_FOUND)
- if(NOT GP2XWIZ)
- set(VORBIS_LIBRARIES ${VORBISFILE_LIBRARY} ${VORBIS_LIBRARY}
- ${OGG_LIBRARY})
- else(NOT GP2XWIZ)
- set(VORBIS_LIBRARIES ${VORBIS_LIBRARY})
- endif(NOT GP2XWIZ)
+ if(NOT GP2XWIZ)
+ set(VORBIS_LIBRARIES ${VORBISFILE_LIBRARY} ${VORBIS_LIBRARY}
+ ${OGG_LIBRARY})
+ else(NOT GP2XWIZ)
+ set(VORBIS_LIBRARIES ${VORBIS_LIBRARY})
+ endif(NOT GP2XWIZ)
else(VORBIS_FOUND)
- set(VORBIS_LIBRARIES)
+ set(VORBIS_LIBRARIES)
endif(VORBIS_FOUND)
mark_as_advanced(OGG_INCLUDE_DIR VORBIS_INCLUDE_DIR)
mark_as_advanced(OGG_LIBRARY VORBIS_LIBRARY VORBISFILE_LIBRARY)
-
diff --git a/cmake/Modules/MinetestFindIrrlichtHeaders.cmake b/cmake/Modules/MinetestFindIrrlichtHeaders.cmake
index d33b296d0..e434b582f 100644
--- a/cmake/Modules/MinetestFindIrrlichtHeaders.cmake
+++ b/cmake/Modules/MinetestFindIrrlichtHeaders.cmake
@@ -1,21 +1,13 @@
-# Locate Irrlicht or IrrlichtMt headers on system.
+# Locate IrrlichtMt headers on system.
-foreach(libname IN ITEMS IrrlichtMt Irrlicht)
- string(TOLOWER "${libname}" libname2)
-
- find_path(IRRLICHT_INCLUDE_DIR NAMES irrlicht.h
- DOC "Path to the directory with IrrlichtMt includes"
- PATHS
- /usr/local/include/${libname2}
- /usr/include/${libname2}
- /system/develop/headers/${libname2} #Haiku
- PATH_SUFFIXES "include/${libname2}"
- )
-
- if(IRRLICHT_INCLUDE_DIR)
- break()
- endif()
-endforeach()
+find_path(IRRLICHT_INCLUDE_DIR NAMES irrlicht.h
+ DOC "Path to the directory with IrrlichtMt includes"
+ PATHS
+ /usr/local/include/irrlichtmt
+ /usr/include/irrlichtmt
+ /system/develop/headers/irrlichtmt #Haiku
+ PATH_SUFFIXES "include/irrlichtmt"
+)
# Handholding for users
if(IRRLICHT_INCLUDE_DIR AND (NOT IS_DIRECTORY "${IRRLICHT_INCLUDE_DIR}" OR