Cleanup lame Makefile.
authorLars-Peter Clausen <lars@metafoo.de>
Fri, 12 Sep 2008 21:09:57 +0000 (21:09 +0000)
committerLars-Peter Clausen <lars@metafoo.de>
Fri, 12 Sep 2008 21:09:57 +0000 (21:09 +0000)
SVN-Revision: 12580

sound/lame/Makefile

index f6a6f32..d1fcd6c 100644 (file)
@@ -1,10 +1,11 @@
 #
-# Copyright (C) 2007 OpenWrt.org
+# Copyright (C) 2007-2008 OpenWrt.org
 #
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
 #
 # blogic@openwrt.org
+# $Id$
 
 include $(TOPDIR)/rules.mk
 
@@ -14,9 +15,12 @@ PKG_RELEASE:=1
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=@SF/lame
 PKG_MD5SUM:=f44b9f8e1b5d8835d0a77f9cc9cedd1c
+PKG_FIXUP:=libtool
 
 include $(INCLUDE_DIR)/package.mk
 
+PKG_INSTALL=1
+
 define Package/lame/Default
   SECTION:=sound
   CATEGORY:=Sound
@@ -43,31 +47,25 @@ define Package/lame-lib/description
 lame mp3 encoder libs
 endef
 
-
-define Build/Configure
-       $(call Build/Configure/Default) 
-endef
-
-define Build/Compile
-       $(MAKE) -C $(PKG_BUILD_DIR) \
-               DESTDIR="$(PKG_INSTALL_DIR)" \
-               all install
-endef
-
-define Package/lame/install    
+define Package/lame/install
        $(INSTALL_DIR) $(1)/usr/bin
        $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/lame $(1)/usr/bin/
 endef
 
-define Package/lame-lib/install        
+define Package/lame-lib/install
        $(INSTALL_DIR) $(1)/usr/lib
-       $(CP) $(PKG_INSTALL_DIR)/usr/lib/lib*so* $(1)/usr/lib/
+       $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/lib*so* $(1)/usr/lib/
 endef
 
 define Build/InstallDev
-       mkdir -p $(1)/usr/{lib,include}
-       ${CP} $(PKG_INSTALL_DIR)/usr/{lib,include} $(1)/usr/
+       $(INSTALL_DIR) $(1)/usr/include/lame
+       $(INSTALL_DATA) \
+               $(PKG_INSTALL_DIR)/usr/include/lame/*.h \
+               $(1)/usr/include/lame/
+       $(INSTALL_DIR) $(1)/usr/lib
+       $(INSTALL_DATA) \
+               $(PKG_INSTALL_DIR)/usr/lib/*.{la,so*} \
+               $(1)/usr/lib/
 endef
 
 $(eval $(call BuildPackage,lame-lib))