mirror of https://github.com/encounter/SDL.git
Fix CMake script on FreeBSD
This commit is contained in:
parent
dacf6cfbaa
commit
34de3b57a1
|
@ -795,11 +795,18 @@ macro(CheckOpenGLX11)
|
||||||
endif()
|
endif()
|
||||||
endmacro()
|
endmacro()
|
||||||
|
|
||||||
|
# Requires:
|
||||||
|
# - PkgCheckModules
|
||||||
|
macro(CheckEGL)
|
||||||
|
pkg_check_modules(EGL egl)
|
||||||
|
string(REPLACE "-D_THREAD_SAFE;" "-D_THREAD_SAFE=1;" EGL_CFLAGS ${EGL_CFLAGS})
|
||||||
|
endmacro()
|
||||||
|
|
||||||
# Requires:
|
# Requires:
|
||||||
# - PkgCheckModules
|
# - PkgCheckModules
|
||||||
macro(CheckEGLKMSDRM)
|
macro(CheckEGLKMSDRM)
|
||||||
if (HAVE_VIDEO_OPENGLES OR HAVE_VIDEO_OPENGL)
|
if (HAVE_VIDEO_OPENGLES OR HAVE_VIDEO_OPENGL)
|
||||||
pkg_check_modules(EGL egl)
|
CheckEGL()
|
||||||
set(CMAKE_REQUIRED_FLAGS "${CMAKE_REQUIRED_FLAGS} ${EGL_CFLAGS}")
|
set(CMAKE_REQUIRED_FLAGS "${CMAKE_REQUIRED_FLAGS} ${EGL_CFLAGS}")
|
||||||
check_c_source_compiles("
|
check_c_source_compiles("
|
||||||
#define EGL_API_FB
|
#define EGL_API_FB
|
||||||
|
@ -817,7 +824,7 @@ endmacro()
|
||||||
# Requires:
|
# Requires:
|
||||||
# - PkgCheckModules
|
# - PkgCheckModules
|
||||||
macro(CheckOpenGLESX11)
|
macro(CheckOpenGLESX11)
|
||||||
pkg_check_modules(EGL egl)
|
CheckEGL()
|
||||||
set(CMAKE_REQUIRED_FLAGS "${CMAKE_REQUIRED_FLAGS} ${EGL_CFLAGS}")
|
set(CMAKE_REQUIRED_FLAGS "${CMAKE_REQUIRED_FLAGS} ${EGL_CFLAGS}")
|
||||||
if(VIDEO_OPENGLES)
|
if(VIDEO_OPENGLES)
|
||||||
check_c_source_compiles("
|
check_c_source_compiles("
|
||||||
|
|
Loading…
Reference in New Issue