aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Oberritter <obi@opendreambox.org>2017-02-24 13:28:40 +0100
committerAndreas Oberritter <obi@opendreambox.org>2017-02-24 13:28:40 +0100
commitd58be1c4cbbfe8e34f79bd59c215bfe14bf0ae2d (patch)
tree512d484e18c814ae0ab9731550bfff552f3de564
parentf4dda3ee1d64103cde3e5e0e59c90e23d7e3fc81 (diff)
downloadmeta-openembedded-contrib-d58be1c4cbbfe8e34f79bd59c215bfe14bf0ae2d.tar.gz
libsdl2-ttf: fix build with GLES2-enabled SDL2
Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
-rw-r--r--meta-oe/recipes-support/libsdl-ttf/libsdl2-ttf/0001-Make-sure-we-can-link-with-OpenGL-libraries-in-the-O.patch41
-rw-r--r--meta-oe/recipes-support/libsdl-ttf/libsdl2-ttf_2.0.14.bb1
2 files changed, 42 insertions, 0 deletions
diff --git a/meta-oe/recipes-support/libsdl-ttf/libsdl2-ttf/0001-Make-sure-we-can-link-with-OpenGL-libraries-in-the-O.patch b/meta-oe/recipes-support/libsdl-ttf/libsdl2-ttf/0001-Make-sure-we-can-link-with-OpenGL-libraries-in-the-O.patch
new file mode 100644
index 0000000000..cee12cb75e
--- /dev/null
+++ b/meta-oe/recipes-support/libsdl-ttf/libsdl2-ttf/0001-Make-sure-we-can-link-with-OpenGL-libraries-in-the-O.patch
@@ -0,0 +1,41 @@
+Upstream-Status: backport [hg]
+
+Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
+
+From 36ebb6865e420014bf039ea63f2259af14e2e941 Mon Sep 17 00:00:00 2001
+From: Sam Lantinga <slouken@libsdl.org>
+Date: Fri, 27 Jan 2017 17:54:34 -0800
+Subject: [PATCH] Make sure we can link with OpenGL libraries in the OpenGL
+ configure test
+
+---
+ configure.in | 7 +++++--
+ 1 files changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/configure.in b/configure.in
+index 9b36e15..9db85a6 100644
+--- a/configure.in
++++ b/configure.in
+@@ -164,14 +164,17 @@ case "$host" in
+ esac
+ AC_MSG_CHECKING(for OpenGL support)
+ have_opengl=no
+-AC_TRY_COMPILE([
++save_LIBS="$LIBS"
++LIBS="$LIBS $SYS_GL_LIBS"
++AC_TRY_LINK([
+ #include "SDL_opengl.h"
+ ],[
+- GLuint texture;
++ glOrtho( -2.0, 2.0, -2.0, 2.0, -20.0, 20.0 );
+ ],[
+ have_opengl=yes
+ ])
+ AC_MSG_RESULT($have_opengl)
++LIBS="$save_LIBS"
+ if test x$have_opengl = xyes; then
+ CFLAGS="$CFLAGS -DHAVE_OPENGL"
+ GL_LIBS="$SYS_GL_LIBS"
+--
+2.7.4
+
diff --git a/meta-oe/recipes-support/libsdl-ttf/libsdl2-ttf_2.0.14.bb b/meta-oe/recipes-support/libsdl-ttf/libsdl2-ttf_2.0.14.bb
index af5a55c170..5715173cd2 100644
--- a/meta-oe/recipes-support/libsdl-ttf/libsdl2-ttf_2.0.14.bb
+++ b/meta-oe/recipes-support/libsdl-ttf/libsdl2-ttf_2.0.14.bb
@@ -7,6 +7,7 @@ LIC_FILES_CHKSUM = "file://COPYING.txt;md5=cb33e7c4df9fbde389f149ad6bc93ce5"
SRC_URI = " \
http://www.libsdl.org/projects/SDL_ttf/release/SDL2_ttf-${PV}.tar.gz \
file://use.pkg-config.for.freetype2.patch \
+ file://0001-Make-sure-we-can-link-with-OpenGL-libraries-in-the-O.patch \
"
SRC_URI[md5sum] = "e53c05e1e7f1382c316afd6c763388b1"
SRC_URI[sha256sum] = "34db5e20bcf64e7071fe9ae25acaa7d72bdc4f11ab3ce59acc768ab62fe39276"