Install net-snmp-config into $(STAGING_DIR)/host/bin rather then
[openwrt/svn-archive/archive.git] / sound / mpd / Makefile
1 #
2 # Copyright (C) 2007 - 2008 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=mpd
12 PKG_VERSION:=0.13.2
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
16 PKG_SOURCE_URL:=http://www.musicpd.org/uploads/files/
17 PKG_MD5SUM:=b461896369949ff3cff955692ead9f8b
18
19 include $(INCLUDE_DIR)/package.mk
20
21 define Package/mpd
22 SECTION:=sound
23 CATEGORY:=Sound
24 DEPENDS:=+libflac +libid3tag +libmad +libvorbisidec +libpthread +libiconv
25 TITLE:=Music Player Daemon
26 URL:=http://www.musicpd.org/
27 endef
28
29 define Package/mpd/description
30 MPD is a music player supporting flac, mp3 and ogg files.
31 It is typically controlled over a network using one of it's many
32 clients including mpc(console), gmpc(gnome), phpmp(php) etc.
33 endef
34
35 define Package/mpd/conffiles
36 /etc/mpd.conf
37 endef
38
39 ifndef CONFIG_PACKAGE_kmod-sound-core
40 EXTRA_CONFIG_PARAM:=--disable-alsa
41 endif
42
43 define Build/Configure
44 $(call Build/Configure/Default, \
45 $(EXTRA_CONFIG_PARAM) \
46 --disable-mod \
47 --disable-audiofile \
48 --disable-mpc \
49 --disable-aac \
50 --disable-lsr \
51 --with-tremor \
52 --with-id3tag-includes="$(STAGING_DIR)/usr/include" \
53 --with-id3tag-libraries="$(STAGING_DIR)/usr/lib" \
54 --with-libFLAC-includes="$(STAGING_DIR)/usr/include" \
55 --with-libFLAC-libraries="$(STAGING_DIR)/usr/lib" \
56 --with-mad-includes="$(STAGING_DIR)/usr/include" \
57 --with-mad-libraries="$(STAGING_DIR)/usr/lib" \
58 --with-iconv-includes="$(STAGING_DIR)/usr/lib/libiconv/include" \
59 --with-iconv-libraries="$(STAGING_DIR)/usr/lib/libiconv/lib" \
60 )
61 endef
62
63 define Build/Compile
64 $(MAKE) -C $(PKG_BUILD_DIR) \
65 DESTDIR="$(PKG_INSTALL_DIR)" \
66 all install
67 endef
68
69 define Package/mpd/install
70 $(INSTALL_DIR) $(1)/etc
71 $(CP) $(PKG_BUILD_DIR)/doc/mpdconf.example $(1)/etc/mpd.conf
72 $(INSTALL_DIR) $(1)/usr/bin
73 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/mpd $(1)/usr/bin/
74 $(INSTALL_DIR) $(1)/etc/init.d
75 $(INSTALL_BIN) ./files/mpd.init $(1)/etc/init.d/mpd
76 endef
77
78 $(eval $(call BuildPackage,mpd))