Root/libsdl-ttf/Makefile

Source at commit 1b3135c created 8 years 4 months ago.
By Xiangfu Liu, new package: SDL-widgets: a GUI toolkit on top of the SDL libraries
1#
2# Copyright (C) 2010 OpenWrt.org
3#
4# This is free software, licensed under the GNU General Public License v2.
5# See /LICENSE for more information.
6#
7
8include $(TOPDIR)/rules.mk
9
10PKG_NAME:=libsdl-ttf
11PKG_VERSION:=2.0.9
12PKG_RELEASE:=2
13
14PKG_SOURCE:=SDL_ttf-$(PKG_VERSION).tar.gz
15PKG_SOURCE_URL:=http://www.libsdl.org/projects/SDL_ttf/release/
16PKG_MD5SUM:=6dd5a85e4924689a35a5fb1cb3336156
17PKG_BUILD_DIR:=$(BUILD_DIR)/SDL_ttf-$(PKG_VERSION)
18
19PKG_INSTALL:=1
20
21include $(INCLUDE_DIR)/package.mk
22include $(INCLUDE_DIR)/nls.mk
23
24define Package/libsdl-ttf
25  SECTION:=libs
26  CATEGORY:=Libraries
27  TITLE:=Simple DirectMedia Layer True Font
28  URL:=http://www.libsdl.org/projects/SDL_ttf/
29  DEPENDS:=+libsdl $(ICONV_DEPENDS) $(INTL_DEPENDS)
30endef
31
32define Package/libsdl-ttf/description
33  SDL_ttf is a TrueType font rendering library that is used with the SDL library, and almost as portable. It depends on freetype2 to handle the TrueType font data. It allows a programmer to use multiple TrueType fonts without having to code a font rendering routine themselves. With the power of outline fonts and antialiasing, high quality text output can be obtained without much effort.
34endef
35
36PKG_FIXUP:=libtool
37
38TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include/SDL
39
40CONFIGURE_ARGS += \
41       --with-sdl-exec-prefix=$(STAGING_DIR) \
42       --without-x \
43       LIBS="-lSDL -liconv"
44
45TARGET_LDFLAGS+= \
46       -Wl,-rpath-link=$(STAGING_DIR)/usr/lib
47
48define Build/InstallDev
49    $(INSTALL_DIR) \
50        $(1)/usr/include/SDL \
51        $(1)/usr/lib
52
53    $(CP) \
54        $(PKG_INSTALL_DIR)/usr/include/SDL/SDL_ttf.h \
55        $(1)/usr/include/SDL/
56
57    $(CP) \
58        $(PKG_INSTALL_DIR)/usr/lib/libSDL_ttf*.{a,so*} \
59        $(1)/usr/lib/
60endef
61
62define Package/libsdl-ttf/install
63    $(INSTALL_DIR) \
64        $(1)/usr/lib
65
66    $(CP) \
67        $(PKG_INSTALL_DIR)/usr/lib/libSDL_ttf*.so* \
68        $(1)/usr/lib/
69endef
70
71$(eval $(call BuildPackage,libsdl-ttf))
72

Archive Download this file



interactive