[PATCH] [package] bump pciutils to 3.1.2
[openwrt/svn-archive/archive.git] / utils / pciutils / Makefile
1 #
2 # Copyright (C) 2007-2009 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=pciutils
11 PKG_VERSION:=3.1.2
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
15 PKG_SOURCE_URL:=http://www.kernel.org/pub/software/utils/pciutils/ \
16 ftp://atrey.karlin.mff.cuni.cz/pub/linux/pci
17 PKG_MD5SUM:=46387fd7a18c33fbb5311fdb3ab9ea12
18
19 include $(INCLUDE_DIR)/package.mk
20
21 define Package/pciutils
22 SECTION:=utils
23 CATEGORY:=Utilities
24 TITLE:=Linux PCI Utilities
25 URL:=http://mj.ucw.cz/pciutils.shtml
26 endef
27
28 define Package/pciutils/description
29 This package contains various utilities for inspecting and setting of
30 devices connected to the PCI bus.
31 endef
32
33 define Package/pciutils/postinst
34 #!/bin/sh
35 $${IPKG_INSTROOT}/usr/sbin/update-pciids.sh
36 endef
37
38 MAKE_FLAGS += \
39 CFLAGS="$(TARGET_CFLAGS)" \
40 IDSDIR="/usr/share" \
41 HOST="$(GNU_TARGET_NAME)" \
42 ZLIB="no" \
43
44 define Build/InstallDev
45 $(INSTALL_DIR) $(1)/usr/lib
46 $(CP) $(PKG_BUILD_DIR)/lib/libpci.a $(1)/usr/lib
47 $(INSTALL_DIR) $(1)/usr/include/pci
48 $(CP) $(foreach i,pci.h config.h header.h types.h, \
49 $(PKG_BUILD_DIR)/lib/$(i)) $(1)/usr/include/pci
50 endef
51
52 define Package/pciutils/install
53 $(INSTALL_DIR) $(1)/usr/sbin
54 $(CP) $(PKG_BUILD_DIR)/{lspci,setpci,update-pciids.sh} $(1)/usr/sbin/
55 $(INSTALL_DIR) $(1)/usr/share
56 $(CP) $(PKG_BUILD_DIR)/pci.ids $(1)/usr/share/
57 endef
58
59 $(eval $(call BuildPackage,pciutils))