fix ettercap compile
[openwrt/svn-archive/archive.git] / utils / pciutils / Makefile
index 11a063fe166f9f5e48515f2a058bae655e8fd250..c2b112257539e655dab19329ec264afab3353b3a 100644 (file)
@@ -16,7 +16,6 @@ PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=http://www.kernel.org/pub/software/utils/pciutils/ \
        ftp://atrey.karlin.mff.cuni.cz/pub/linux/pci
 PKG_MD5SUM:=c18e2a5f04e9abae5a42439de294f086
-PKG_CAT:=zcat
 
 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
 
@@ -26,12 +25,19 @@ define Package/pciutils
   SECTION:=utils
   CATEGORY:=Utilities
   TITLE:=Linux PCI Utilities
-  DESCRIPTION:=\
-       This package contains various utilities for inspecting and setting of \\\
-       devices connected to the PCI bus.
   URL:=http://www.kernel.org/pub/software/utils/pciutils/
 endef
 
+define Package/pciutils/description
+       This package contains various utilities for inspecting and setting of 
+       devices connected to the PCI bus.
+endef
+
+define Package/pciutils/postinst
+#!/bin/sh
+$${IPKG_INSTROOT}/usr/sbin/update-pciids.sh
+endef
+
 define Build/Configure
 endef
 
@@ -43,10 +49,20 @@ define Build/Compile
        )
 endef
 
+define Build/InstallDev
+       $(INSTALL_DIR) $(1)/usr/lib
+       $(CP) $(PKG_BUILD_DIR)/lib/libpci.a $(1)/usr/lib
+       $(INSTALL_DIR) $(1)/usr/include/pci
+       $(CP) $(PKG_BUILD_DIR)/lib/pci.h $(1)/usr/include/pci
+       $(CP) $(PKG_BUILD_DIR)/lib/config.h $(1)/usr/include/pci
+       $(CP) $(PKG_BUILD_DIR)/lib/header.h $(1)/usr/include/pci
+       $(CP) $(PKG_BUILD_DIR)/lib/types.h $(1)/usr/include/pci
+endef
+
 define Package/pciutils/install
-       install -d -m0755 $(1)/usr/sbin
-       $(CP) $(PKG_BUILD_DIR)/{lspci,setpci} $(1)/usr/sbin/
-       install -d -m0755 $(1)/usr/share
+       $(INSTALL_DIR) $(1)/usr/sbin
+       $(CP) $(PKG_BUILD_DIR)/{lspci,setpci,update-pciids.sh} $(1)/usr/sbin/
+       $(INSTALL_DIR) $(1)/usr/share
        $(CP) $(PKG_BUILD_DIR)/pci.ids $(1)/usr/share/
 endef