make it so you can install 'file' itself rather than just the library
authorTim Yardley <lst@openwrt.org>
Fri, 13 Jul 2007 14:12:55 +0000 (14:12 +0000)
committerTim Yardley <lst@openwrt.org>
Fri, 13 Jul 2007 14:12:55 +0000 (14:12 +0000)
SVN-Revision: 7968

libs/file/Makefile

index dfa2ad84bdbb0b24b175864d2209a5951ca020b5..230ecc4a12b619cde3b310229341df9d5b209a3c 100644 (file)
@@ -30,6 +30,14 @@ define Package/libmagic
   URL:=ftp://ftp.astron.com/pub/file/
 endef
 
+define Package/file
+  SECTION:=utils
+  CATEGORY:=Utilities
+  DEPENDS:=+libmagic
+  TITLE:=File type determination library
+  URL:=ftp://ftp.astron.com/pub/file/
+endef
+
 define Build/Configure
        $(call Build/Configure/Default, \
                --enable-shared \
@@ -64,4 +72,14 @@ define Package/libmagic/install
        $(CP) $(PKG_INSTALL_DIR)/usr/lib/libmagic.so.* $(1)/usr/lib/
 endef
 
+define Package/file/install
+       $(INSTALL_DIR) $(1)/usr/bin
+       $(INSTALL_DIR) $(1)/usr/share/file
+       $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/file \
+               $(1)/usr/bin
+       $(INSTALL_DATA) $(PKG_BUILD_DIR)/magic/Magdir/linux \
+               $(1)/usr/share/file/magic
+endef
+
 $(eval $(call BuildPackage,libmagic))
+$(eval $(call BuildPackage,file))