[Cogl] [PATCH 5/5] Fix the GBM_MICRO macro
Neil Roberts
neil at linux.intel.com
Wed Jul 3 04:11:22 PDT 2013
The version of gbm can sometimes be suffixed with ‘-devel’. This was
making the GBM_MICRO define come out as 0-devel which was generating a
warning when it was used in a #if check. This patch makes it chop off
anything after a ‘-’ using sed.
---
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/configure.ac b/configure.ac
index 8d38d90..5d9094a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1075,7 +1075,7 @@ AS_IF([test "x$enable_kms_egl_platform" = "xyes"],
GBM_VERSION=`$PKG_CONFIG --modversion gbm`
GBM_MAJOR=`echo $GBM_VERSION | cut -d'.' -f1`
GBM_MINOR=`echo $GBM_VERSION | cut -d'.' -f2`
- GBM_MICRO=`echo $GBM_VERSION | cut -d'.' -f3`
+ GBM_MICRO=`echo $GBM_VERSION | cut -d'.' -f3 | sed 's/-.*//'`
AC_DEFINE_UNQUOTED([COGL_GBM_MAJOR], [$GBM_MAJOR], [The major version for libgbm])
AC_DEFINE_UNQUOTED([COGL_GBM_MINOR], [$GBM_MINOR], [The minor version for libgbm])
--
1.7.11.3.g3c3efa5
More information about the Cogl
mailing list