2 # Copyright (C) 2006 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 include $(TOPDIR
)/rules.mk
14 PKG_MD5SUM
:=4e8449cde7135ad97f788e67e1bd64ee
16 PKG_SOURCE_URL
:=http
://www.cti.ecp.fr
/~beauxir5
/peercast
17 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
20 PKG_BUILD_DIR
:=$(BUILD_DIR
)/$(PKG_NAME
)-$(PKG_VERSION
)
21 PKG_INSTALL_DIR
:=$(PKG_BUILD_DIR
)/ipkg-install
23 include $(INCLUDE_DIR
)/package.mk
25 define Package
/peercast
28 DEPENDS
:=+libpthread
+uclibcxx
29 TITLE
:=P2P audio and video streaming server
30 DESCRIPTION
:=PeerCast is a fresh new P2P streaming server. It can stream music
\\\
31 and video from a broad variety of formats. Many audio players can
\\\
32 listen to peercast streams
, as it
's been built to remain compatible\\\
33 with Nullsoft Shoutcast.\\\
34 URL:=http://www.peercast.org/
37 define Package/peercast/conffiles
41 define Build/Configure
42 $(call Build/Configure/Default,--enable-shared \
45 --enable-staticbin, BUILD_CC=$(TARGET_CC) HOSTCC=$(HOSTCC) \
46 $(TARGET_CONFIGURE_OPTS) \
47 CFLAGS="$(TARGET_CFLAGS)" \
48 CXXFLAGS="$(TARGET_CFLAGS) -fno-builtin -nostdinc++ -nodefaultlibs" \
49 CPPFLAGS="-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include" \
50 LDFLAGS="-L$(STAGING_DIR)/usr/lib -L$(STAGING_DIR)/lib" \
51 LIBS="-nodefaultlibs -luClibc++ -lpthread")
55 rm -rf $(PKG_INSTALL_DIR)
56 mkdir -p $(PKG_INSTALL_DIR)
57 $(MAKE) -C $(PKG_BUILD_DIR) \
58 DESTDIR="$(PKG_INSTALL_DIR)" \
62 define Package/peercast/install
63 install -m0755 -d $(1)/usr/sbin
64 $(CP) $(PKG_INSTALL_DIR)/usr/sbin/peercast $(1)/usr/sbin/
65 install -m0755 -d $(1)/usr/share/peercast/html
66 $(CP) $(PKG_INSTALL_DIR)/usr/share/peercast/html/en $(1)/usr/share/peercast/html/
67 install -m0755 -d $(1)/etc
68 install -m0644 ./files/peercast.ini $(1)/etc/
69 install -m0755 -d $(1)/etc/init.d
70 install -m0755 ./files/peercast.init $(1)/etc/init.d/peercast
71 ln -sf peercast $(1)/etc/init.d/S60peercast
74 $(eval $(call BuildPackage,peercast))