make libmad depending on CONFIG_BUILD_PATENTED
[openwrt/svn-archive/archive.git] / libs / libsdl_mixer / Makefile
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
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=SDL_mixer
11 PKG_VERSION:=1.2.11
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://www.libsdl.org/projects/SDL_mixer/release/
16 PKG_MD5SUM:=65ada3d997fe85109191a5fb083f248c
17
18 PKG_FIXUP:=libtool
19 PKG_INSTALL:=1
20
21 include $(INCLUDE_DIR)/package.mk
22
23 TARGET_LDFLAGS += -Wl,-rpath-link,$(STAGING_DIR)/usr/lib
24
25 define Package/libsdl-mixer
26 SECTION:=libs
27 CATEGORY:=Libraries
28 TITLE:=Simple DirectMedia Layer Sound Mixer
29 URL:=http://www.libsdl.org/projects/SDL_mixer/
30 DEPENDS:=+libsdl +libmikmod +libvorbisidec
31 endef
32
33 define Package/libsdl-mixer/description
34 SDL_mixer is a sample multi-channel audio mixer library.
35 endef
36
37 define Build/Configure
38 $(call Build/Configure/Default, \
39 --disable-sdltest \
40 --enable-music-cmd \
41 --enable-music-wave \
42 --enable-music-mod \
43 --enable-music-mod-shared \
44 --enable-music-midi \
45 --disable-music-ogg \
46 --enable-music-ogg-tremor \
47 --enable-music-ogg-shared \
48 --disable-music-flac \
49 --enable-music-flag-shared \
50 --disable-music-mp3 \
51 --enable-music-mp3-shared \
52 --disable-smpegtest \
53 --disable-music-mp3-mad-gpl \
54 )
55 endef
56
57 define Build/InstallDev
58 $(INSTALL_DIR) $(1)/usr/include/SDL $(1)/usr/lib/pkgconfig
59 $(CP) \
60 $(PKG_INSTALL_DIR)/usr/include/SDL/SDL_mixer.h \
61 $(1)/usr/include/SDL/
62 $(CP) \
63 $(PKG_INSTALL_DIR)/usr/lib/libSDL_mixer*.{a,la,so*} \
64 $(1)/usr/lib/
65 $(INSTALL_DATA) \
66 $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/* \
67 $(1)/usr/lib/pkgconfig/
68 endef
69
70 define Package/libsdl-mixer/install
71 $(INSTALL_DIR) $(1)/usr/lib
72 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libSDL_mixer*.so* $(1)/usr/lib/
73 endef
74
75 $(eval $(call BuildPackage,libsdl-mixer))