diff options
author | Neil Roberts <neil@linux.intel.com> | 2013-03-20 16:36:58 +0000 |
---|---|---|
committer | Neil Roberts <neil@linux.intel.com> | 2013-03-22 00:13:36 +0000 |
commit | 13675ab440f87176bf324ddf39edf94b24fe2114 (patch) | |
tree | 71a34cd3bdde0e4801aed048e96fc1f106cecef3 | |
parent | 5334547c005ebf6f3b19d528248882cd346f4dd8 (diff) | |
download | cogl-13675ab440f87176bf324ddf39edf94b24fe2114.tar.gz |
configure: Add a minimum required version for the wayland package
Previously Cogl would accept any version of Wayland when building the
Wayland backend. Seeing as there is now a stable API we might as well
specify that we require at least version 1.0.0. This is now also
mentioned in the README. This patch also changes it to use
PKG_CHECK_MODULES instead of PKG_CHECK_EXISTS because it does need to
abort if it fails and it shouldn't be checking it silently.
Reviewed-by: Robert Bragg <robert@linux.intel.com>
(cherry picked from commit d899955b714e5ed50c6c89b9fde4b341bcf80558)
-rw-r--r-- | README.in | 3 | ||||
-rw-r--r-- | configure.ac | 20 |
2 files changed, 12 insertions, 11 deletions
@@ -52,6 +52,9 @@ On X11, Cogl depends on the following extensions • XExt • XFixes ≥ @XFIXES_REQ_VERSION@ +For the Wayland backend, Cogl requires: + • Wayland ≥ @WAYLAND_REQ_VERSION@ + When running with OpenGL, Cogl requires at least version 1.3 or 1.2 with the multitexturing extension. However to build Cogl you will need the latest GL headers which can be obtained from: diff --git a/configure.ac b/configure.ac index e0f7f96a..ed33dacd 100644 --- a/configure.ac +++ b/configure.ac @@ -92,6 +92,7 @@ m4_define([xfixes_req_version], [3]) m4_define([xcomposite_req_version], [0.4]) m4_define([xrandr_req_version], [1.2]) m4_define([cairo_req_version], [1.10]) +m4_define([wayland_req_version], [1.0.0]) dnl These variables get copied into the generated README AC_SUBST([GLIB_REQ_VERSION], [glib_req_version]) @@ -103,6 +104,7 @@ AC_SUBST([XFIXES_REQ_VERSION], [xfixes_req_version]) AC_SUBST([GTK_DOC_REQ_VERSION], [gtk_doc_req_version]) AC_SUBST([GI_REQ_VERSION], [gi_req_version]) AC_SUBST([UPROF_REQ_VERSION], [uprof_req_version]) +AC_SUBST([WAYLAND_REQ_VERSION], [wayland_req_version]) # Save this value here, since automake will set cflags later and we # want to know if the user specified custom cflags or not. @@ -915,12 +917,10 @@ AS_IF([test "x$enable_wayland_egl_platform" = "xyes"], NEED_EGL=yes EGL_PLATFORMS="$EGL_PLATFORMS wayland" - PKG_CHECK_EXISTS([wayland-egl], - [ - COGL_PKG_REQUIRES="$COGL_PKG_REQUIRES wayland-egl" - COGL_PKG_REQUIRES="$COGL_PKG_REQUIRES wayland-client" - ], - [AC_MSG_ERROR([Unable to locate required wayland libraries])]) + PKG_CHECK_MODULES(WAYLAND_CLIENT, + [wayland-egl >= wayland_req_version wayland-client >= wayland_req_version]) + COGL_PKG_REQUIRES="$COGL_PKG_REQUIRES wayland-egl >= wayland_req_version" + COGL_PKG_REQUIRES="$COGL_PKG_REQUIRES wayland-client >= wayland_req_version" COGL_DEFINES_SYMBOLS="$COGL_DEFINES_SYMBOLS COGL_HAS_EGL_PLATFORM_WAYLAND_SUPPORT" ]) @@ -971,11 +971,9 @@ AS_IF([test "x$enable_wayland_egl_server" = "xyes"], [ NEED_EGL=yes - PKG_CHECK_EXISTS([wayland-server], - [ - COGL_PKG_REQUIRES="$COGL_PKG_REQUIRES wayland-server" - ], - [AC_MSG_ERROR([Unable to locate required wayland-server library])]) + PKG_CHECK_MODULES(WAYLAND_SERVER, + [wayland-server >= wayland_req_version]) + COGL_PKG_REQUIRES="$COGL_PKG_REQUIRES wayland-server >= wayland_req_version" COGL_DEFINES_SYMBOLS="$COGL_DEFINES_SYMBOLS COGL_HAS_WAYLAND_EGL_SERVER_SUPPORT" ]) |