2 # Copyright (C) 2010 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR)/rules.mk
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://www.libsdl.org/release/
16 PKG_MD5SUM:=e52086d1b508fa0b76c52ee30b55bec4
21 PKG_CONFIG_DEPENDS:=CONFIG_AUDIO_SUPPORT
23 include $(INCLUDE_DIR)/package.mk
28 TITLE:=Simple DirectMedia Layer
29 URL:=http://www.libsdl.org
30 DEPENDS:=+directfb +zlib +libpthread +AUDIO_SUPPORT:alsa-lib
33 define Package/libsdl/description
34 SDL is a library that allows programs portable low level access to a video
35 framebuffer, audio output, mouse, and keyboard.
52 --enable-alsa-shared \
56 --disable-pulseaudio \
57 --enable-pulseaudio-shared \
59 --enable-arts-shared \
63 --disable-dummyaudio \
73 --enable-video-x11-dgamouse \
74 --enable-video-x11-vm \
75 --enable-video-x11-xv \
76 --disable-video-x11-xinerama \
77 --disable-video-x11-xme \
78 --disable-video-x11-xrandr \
79 --disable-video-photon \
80 --disable-video-carbon \
81 --disable-video-cocoa \
82 --enable-video-fbcon \
83 --enable-video-directfb \
84 --disable-video-ps2gs \
87 --disable-video-svga \
89 --disable-video-wscons \
90 --disable-video-aalib \
91 --disable-video-caca \
92 --disable-video-qtopia \
93 --disable-video-picogui \
94 --disable-video-xbios \
96 --disable-video-dummy \
97 --disable-video-opengl \
98 --disable-osmesa-shared \
99 --disable-screensaver \
100 --enable-input-events \
101 --disable-input-tslib \
104 --enable-pthread-sem \
105 --disable-stdio-redirect \
107 --enable-sdl-dlopen \
108 --disable-atari-ldg \
109 --disable-clock_gettime \
113 ifneq ($(CONFIG_AUDIO_SUPPORT),)
124 ac_cv_path_DIRECTFBCONFIG=no \
126 define Build/InstallDev
127 $(INSTALL_DIR) $(1)/usr/include $(1)/usr/lib/pkgconfig
129 $(PKG_INSTALL_DIR)/usr/include/SDL* \
132 $(PKG_INSTALL_DIR)/usr/lib/libSDL*.{a,so*} \
135 $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/* \
136 $(1)/usr/lib/pkgconfig
139 $(INSTALL_DIR) $(1)/usr/share/aclocal
141 $(PKG_INSTALL_DIR)/usr/share/aclocal/* \
142 $(1)/usr/share/aclocal/
144 $(INSTALL_DIR) $(1)/usr/bin
146 $(PKG_INSTALL_DIR)/usr/bin/sdl-config \
149 $(SED) 's,^\(exec_prefix\|prefix\)=.*,\1=\"$(STAGING_DIR)/usr/\",g' \
150 $(1)/usr/bin/sdl-config
152 $(INSTALL_DIR) $(1)/host/bin
153 ln -sf ../../usr/bin/sdl-config $(1)/host/bin/
156 define Package/libsdl/install
157 $(INSTALL_DIR) $(1)/usr/lib
158 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libSDL*.so.* $(1)/usr/lib/
161 $(eval $(call BuildPackage,libsdl))