mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
From: Michael Grzeschik <m.grzeschik@pengutronix.de>
To: ptxdist@pengutronix.de
Subject: [ptxdist] [PATCH v5 4/6] sdl2-ttf: add new package
Date: Thu, 26 Jul 2018 19:39:23 +0200	[thread overview]
Message-ID: <20180726173925.1982-5-m.grzeschik@pengutronix.de> (raw)
In-Reply-To: <20180726173925.1982-1-m.grzeschik@pengutronix.de>

Signed-off-by: Michael Grzeschik <m.grzeschik@pengutronix.de>
---
v1 -> v2: - removed extra padding spaces from prompt
          - removed extra space on _LDFLAGS
          - added missing license to zlib
          - added a patch to select opengl dependency
v2 -> v3: - nothing changed
v3 -> v4: - nothing changed
v4 -> v5: - removed hunk from sdl2-test
          - reworked the opengl enable patch on configure.in
	  - added autogen.sh

 ...igure-make-opengl-support-switchable.patch | 34 +++++++++++
 patches/SDL2_ttf-2.0.14/autogen.sh            |  3 +
 patches/SDL2_ttf-2.0.14/series                |  4 ++
 rules/sdl2-ttf.in                             | 12 ++++
 rules/sdl2-ttf.make                           | 61 +++++++++++++++++++
 5 files changed, 114 insertions(+)
 create mode 100644 patches/SDL2_ttf-2.0.14/0001-configure-make-opengl-support-switchable.patch
 create mode 100755 patches/SDL2_ttf-2.0.14/autogen.sh
 create mode 100644 patches/SDL2_ttf-2.0.14/series
 create mode 100644 rules/sdl2-ttf.in
 create mode 100644 rules/sdl2-ttf.make

diff --git a/patches/SDL2_ttf-2.0.14/0001-configure-make-opengl-support-switchable.patch b/patches/SDL2_ttf-2.0.14/0001-configure-make-opengl-support-switchable.patch
new file mode 100644
index 000000000..e57fffcc0
--- /dev/null
+++ b/patches/SDL2_ttf-2.0.14/0001-configure-make-opengl-support-switchable.patch
@@ -0,0 +1,34 @@
+From: Michael Grzeschik <m.grzeschik@pengutronix.de>
+Date: Fri, 13 Jul 2018 12:24:59 +0200
+Subject: [PATCH] configure: make opengl support switchable
+
+Signed-off-by: Michael Grzeschik <m.grzeschik@pengutronix.de>
+---
+ configure.in | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git a/configure.in b/configure.in
+index 9b36e15cfd4d..972dadf80bd2 100644
+--- a/configure.in
++++ b/configure.in
+@@ -130,6 +130,12 @@ AM_PATH_SDL2($SDL_VERSION,
+ CFLAGS="$CFLAGS $SDL_CFLAGS"
+ LIBS="$LIBS $SDL_LIBS"
+ 
++dnl Check to see if OpenGL support is desired
++AC_ARG_ENABLE(opengl,
++AC_HELP_STRING([--enable-opengl], [include OpenGL support [[default=yes]]]),
++              , enable_opengl=yes)
++
++if test x$enable_opengl = xyes; then
+ dnl Check for OpenGL
+ case "$host" in
+     *-*-cygwin* | *-*-mingw32*)
+@@ -179,6 +185,7 @@ else
+     GL_LIBS=""
+ fi
+ AC_SUBST([GL_LIBS])
++fi
+ AC_SUBST([MATHLIB])
+ AC_SUBST([WINDRES])
+ 
diff --git a/patches/SDL2_ttf-2.0.14/autogen.sh b/patches/SDL2_ttf-2.0.14/autogen.sh
new file mode 100755
index 000000000..a430a4eb7
--- /dev/null
+++ b/patches/SDL2_ttf-2.0.14/autogen.sh
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+./autogen.sh
diff --git a/patches/SDL2_ttf-2.0.14/series b/patches/SDL2_ttf-2.0.14/series
new file mode 100644
index 000000000..89c7959a2
--- /dev/null
+++ b/patches/SDL2_ttf-2.0.14/series
@@ -0,0 +1,4 @@
+# generated by git-ptx-patches
+#tag:base --start-number 1
+0001-configure-make-opengl-support-switchable.patch
+# 61c28fd8bd7358c69acd4d51c712869b  - git-ptx-patches magic
diff --git a/rules/sdl2-ttf.in b/rules/sdl2-ttf.in
new file mode 100644
index 000000000..a14676933
--- /dev/null
+++ b/rules/sdl2-ttf.in
@@ -0,0 +1,12 @@
+## SECTION=multimedia_sdl
+
+config SDL2_TTF
+	tristate
+	select SDL2
+	select FREETYPE
+	prompt "SDL2 ttf"
+	help
+	  This is a sample library which allows you to use TrueType
+	  fonts in your SDL applications. It comes with an example
+	  program "showfont" which displays an example string for a
+	  given TrueType font file.
diff --git a/rules/sdl2-ttf.make b/rules/sdl2-ttf.make
new file mode 100644
index 000000000..6224fbde4
--- /dev/null
+++ b/rules/sdl2-ttf.make
@@ -0,0 +1,61 @@
+# -*-makefile-*-
+#
+# Copyright (C) 2018 by Michael Grzeschik <mgr@pengutronix.de>
+#
+# See CREDITS for details about who has contributed to this project.
+#
+# For further information about the PTXdist project and license conditions
+# see the README file.
+#
+
+#
+# We provide this package
+#
+PACKAGES-$(PTXCONF_SDL2_TTF) += sdl2-ttf
+
+#
+# Paths and names
+#
+SDL2_TTF_VERSION	:= 2.0.14
+SDL2_TTF_MD5		:= e53c05e1e7f1382c316afd6c763388b1
+SDL2_TTF		:= SDL2_ttf-$(SDL2_TTF_VERSION)
+SDL2_TTF_SUFFIX	:= tar.gz
+SDL2_TTF_URL		:= https://www.libsdl.org/projects/SDL_ttf/release/$(SDL2_TTF).$(SDL2_TTF_SUFFIX)
+SDL2_TTF_SOURCE	:= $(SRCDIR)/$(SDL2_TTF).$(SDL2_TTF_SUFFIX)
+SDL2_TTF_DIR		:= $(BUILDDIR)/$(SDL2_TTF)
+SDL2_TTF_LICENSE	:= unknown
+
+# ----------------------------------------------------------------------------
+# Prepare
+# ----------------------------------------------------------------------------
+
+SDL2_TTF_CONF_TOOL	:= autoconf
+SDL2_TTF_CONF_OPT	:= \
+	$(CROSS_AUTOCONF_USR) \
+	--$(call ptx/endis,PTXCONF_SDL2_OPENGL)-opengl
+
+ifdef PTXCONF_SDL2_PULSEAUDIO
+SDL2_TTF_LDFLAGS	:= \
+	-Wl,-rpath-link,$(SYSROOT)/usr/lib/pulseaudio
+endif
+
+# ----------------------------------------------------------------------------
+# Target-Install
+# ----------------------------------------------------------------------------
+
+$(STATEDIR)/sdl2-ttf.targetinstall:
+	@$(call targetinfo)
+
+	@$(call install_init, sdl2-ttf)
+	@$(call install_fixup, sdl2-ttf,PRIORITY,optional)
+	@$(call install_fixup, sdl2-ttf,SECTION,base)
+	@$(call install_fixup, sdl2-ttf,AUTHOR,"Michael Grzeschik <mgr@pengutronix.de>")
+	@$(call install_fixup, sdl2-ttf,DESCRIPTION,missing)
+
+	@$(call install_lib, sdl2-ttf, 0, 0, 0644, libSDL2_ttf-2.0)
+
+	@$(call install_finish, sdl2-ttf)
+
+	@$(call touch)
+
+# vim: syntax=make
-- 
2.18.0


_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de

  parent reply	other threads:[~2018-07-26 17:39 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-26 17:39 [ptxdist] [PATCH v5 0/6] sdl2: add support for new packages Michael Grzeschik
2018-07-26 17:39 ` [ptxdist] [PATCH v5 1/6] sdl2: add new package Michael Grzeschik
2018-07-27 13:09   ` Michael Grzeschik
2018-07-26 17:39 ` [ptxdist] [PATCH v5 2/6] sdl2-image: " Michael Grzeschik
2018-07-26 17:39 ` [ptxdist] [PATCH v5 3/6] sdl2-net: " Michael Grzeschik
2018-07-26 17:39 ` Michael Grzeschik [this message]
2018-07-26 17:39 ` [ptxdist] [PATCH v5 5/6] sdl2-mixer: " Michael Grzeschik
2018-07-26 17:39 ` [ptxdist] [PATCH v5 6/6] sdl2-test: " Michael Grzeschik

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180726173925.1982-5-m.grzeschik@pengutronix.de \
    --to=m.grzeschik@pengutronix.de \
    --cc=ptxdist@pengutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox