[Buildroot] [git commit] package/sdl3_ttf: new package

Julien Olivain via buildroot <[email protected]>
Newsgroups net.busybox.buildroot
Message-ID <[email protected]>
commit: https://gitlab.com/buildroot.org/buildroot/-/commit/baa86d079d7afa6bce8ff213fb992900b8c27c71
branch: https://gitlab.com/buildroot.org/buildroot/-/tree/master

SDL3_ttf is a TrueType font rendering library for SDL3, based on
freetype, with optional harfbuzz support.

https://github.com/libsdl-org/SDL_ttf

Signed-off-by: Michael Fischer <[email protected]>
Signed-off-by: Julien Olivain <[email protected]>
---
 DEVELOPERS                     |  1 +
 package/Config.in              |  1 +
 package/sdl3_ttf/Config.in     |  9 +++++++++
 package/sdl3_ttf/sdl3_ttf.hash |  3 +++
 package/sdl3_ttf/sdl3_ttf.mk   | 25 +++++++++++++++++++++++++
 5 files changed, 39 insertions(+)

diff --git a/DEVELOPERS b/DEVELOPERS
index d3451beb99..b7749df319 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -2429,6 +2429,7 @@ F:	package/sdl2/
 F:	package/sdl3/
 F:	package/sdl3_gfx/
 F:	package/sdl3_image/
+F:	package/sdl3_ttf/
 
 N:	Michael Nosthoff <[email protected]>
 F:	package/boost/
diff --git a/package/Config.in b/package/Config.in
index a3276ede1d..e4deb5f00e 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -367,6 +367,7 @@ comment "Graphic libraries"
 	source "package/sdl3/Config.in"
 	source "package/sdl3_gfx/Config.in"
 	source "package/sdl3_image/Config.in"
+	source "package/sdl3_ttf/Config.in"
 	source "package/spirv-headers/Config.in"
 	source "package/tk/Config.in"
 	source "package/virglrenderer/Config.in"
diff --git a/package/sdl3_ttf/Config.in b/package/sdl3_ttf/Config.in
new file mode 100644
index 0000000000..d1c6c2efd0
--- /dev/null
+++ b/package/sdl3_ttf/Config.in
@@ -0,0 +1,9 @@
+config BR2_PACKAGE_SDL3_TTF
+	bool "sdl3_ttf"
+	depends on BR2_PACKAGE_SDL3
+	select BR2_PACKAGE_FREETYPE
+	help
+	  SDL3_ttf is a sample TrueType font library. It allows you to
+	  use TrueType fonts in your SDL3 applications.
+
+	  http://www.libsdl.org/projects/SDL_ttf/
diff --git a/package/sdl3_ttf/sdl3_ttf.hash b/package/sdl3_ttf/sdl3_ttf.hash
new file mode 100644
index 0000000000..a959f011ce
--- /dev/null
+++ b/package/sdl3_ttf/sdl3_ttf.hash
@@ -0,0 +1,3 @@
+# Locally calculated
+sha256  63547d58d0185c833213885b635a2c0548201cc8f301e6587c0be1a67e1e045d  SDL3_ttf-3.2.2.tar.gz
+sha256  7826eca0a0f7e591f38dd844e207a200aac81a59b20d8a30c3af8c6282af13e6  LICENSE.txt
diff --git a/package/sdl3_ttf/sdl3_ttf.mk b/package/sdl3_ttf/sdl3_ttf.mk
new file mode 100644
index 0000000000..12441e243e
--- /dev/null
+++ b/package/sdl3_ttf/sdl3_ttf.mk
@@ -0,0 +1,25 @@
+################################################################################
+#
+# sdl3_ttf
+#
+################################################################################
+
+SDL3_TTF_VERSION = 3.2.2
+SDL3_TTF_SOURCE = SDL3_ttf-$(SDL3_TTF_VERSION).tar.gz
+SDL3_TTF_SITE = https://www.libsdl.org/projects/SDL_ttf/release
+SDL3_TTF_LICENSE = Zlib
+SDL3_TTF_LICENSE_FILES = LICENSE.txt
+SDL3_TTF_INSTALL_STAGING = YES
+
+SDL3_TTF_DEPENDENCIES = sdl3 freetype host-pkgconf
+
+SDL3_TTF_CONF_OPTS = \
+	-DSDLTTF_VENDORED=OFF \
+	-DSDLTTF_HARFBUZZ=OFF
+
+ifeq ($(BR2_PACKAGE_HARFBUZZ),y)
+SDL3_TTF_DEPENDENCIES += harfbuzz
+SDL3_TTF_CONF_OPTS += -DSDLTTF_HARFBUZZ=ON
+endif
+
+$(eval $(cmake-package))
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.