Update shell-fm to 0.5 (#3614)
[openwrt/svn-archive/archive.git] / sound / shell-fm / Makefile
index 1a1ae96c707980ee76d8661880940652b6a0ff46..ea73b03bb1ead6fdd90e1b08806fd8a5be783e73 100644 (file)
@@ -9,16 +9,12 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=shell-fm
-PKG_VERSION:=0.2
+PKG_VERSION:=0.5
 PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
-PKG_SOURCE_URL:=http://nex.scrapping.cc/shell-fm/downloads
-PKG_MD5SUM:=6ebbcf1af241a92a1237547fc39ca728
-PKG_CAT:=bzcat
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)
-PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
+PKG_SOURCE_URL:=http://nex.scrapping.cc/code/shell-fm/downloads/
+PKG_MD5SUM:=a257283b0f7e9173ee1073b88e57c5f6
 
 include $(INCLUDE_DIR)/package.mk
 
@@ -27,26 +23,37 @@ define Package/shell-fm
   CATEGORY:=Sound
   DEPENDS:=+libmad +libopenssl +libreadline +libncurses
   TITLE:=Console Based Last.FM Radio Player
-  DESCRIPTION:=\
-       Shell.FM is a console based player for the streams provided \\\
-       by Last.FM for the Linux platform. It's lightweight and easy to use.
   URL:=http://nex.scrapping.cc
 endef
 
+define Package/shell-fm/description
+       Shell.FM is a console based player for the streams provided 
+       by Last.FM for the Linux platform. It's lightweight and easy to use.
+endef
+
+define Package/shell-fm/conffiles
+/etc/shell-fm.rc
+endef
+
 define Build/Configure
-       $(PKG_BUILD_DIR)/reconfig
-       $(call Build/Configure/Default)
 endef
 
 define Build/Compile
        $(MAKE) -C $(PKG_BUILD_DIR) \
+               $(TARGET_CONFIGURE_OPTS) \
+               CFLAGS="$(TARGET_CFLAGS) -I./include/ -I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include" \
                DESTDIR="$(PKG_INSTALL_DIR)" \
+               LDFLAGS="-L$(STAGING_DIR)/usr/lib -L$(STAGING_DIR)/lib -lmad -lao" \
                all install
 endef
 
 define Package/shell-fm/install        
        $(INSTALL_DIR) $(1)/usr/bin
-       $(CP) $(PKG_INSTALL_DIR)/usr/bin/shell-fm $(1)/usr/bin/
+       $(INSTALL_BIN) $(PKG_INSTALL_DIR)/bin/shell-fm $(1)/usr/bin/
+       $(INSTALL_DIR) $(1)/etc
+       $(INSTALL_DATA) ./files/shell-fm.rc $(1)/etc/shell-fm.rc
+       $(INSTALL_DIR) $(1)/etc/init.d
+       $(INSTALL_BIN) ./files/shell-fm.init $(1)/etc/init.d/shell-fm
 endef
 
 $(eval $(call BuildPackage,shell-fm))