2013-06-06 01:53:30 +02:00
|
|
|
################################################################################
|
2003-01-18 22:27:22 +01:00
|
|
|
#
|
2013-06-06 01:53:28 +02:00
|
|
|
# pciutils
|
2003-01-18 22:27:22 +01:00
|
|
|
#
|
2013-06-06 01:53:30 +02:00
|
|
|
################################################################################
|
2003-01-18 22:27:22 +01:00
|
|
|
|
2015-04-09 20:57:46 +02:00
|
|
|
PCIUTILS_VERSION = 3.3.1
|
2014-10-16 16:06:19 +02:00
|
|
|
PCIUTILS_SITE = $(BR2_KERNEL_MIRROR)/software/utils/pciutils
|
|
|
|
PCIUTILS_SOURCE = pciutils-$(PCIUTILS_VERSION).tar.xz
|
2012-06-02 08:13:56 +02:00
|
|
|
PCIUTILS_INSTALL_STAGING = YES
|
2012-11-13 02:05:54 +01:00
|
|
|
PCIUTILS_LICENSE = GPLv2+
|
|
|
|
PCIUTILS_LICENSE_FILES = COPYING
|
2015-04-09 23:22:05 +02:00
|
|
|
PCIUTILS_MAKE_OPTS = \
|
|
|
|
CC="$(TARGET_CC)" \
|
|
|
|
HOST="$(KERNEL_ARCH)-linux" \
|
|
|
|
OPT="$(TARGET_CFLAGS)" \
|
|
|
|
LDFLAGS="$(TARGET_LDFLAGS)" \
|
|
|
|
RANLIB=$(TARGET_RANLIB) \
|
|
|
|
AR=$(TARGET_AR) \
|
|
|
|
PCIUTILS_DNS=no
|
2012-11-13 02:05:54 +01:00
|
|
|
|
2015-04-09 20:57:46 +02:00
|
|
|
ifeq ($(BR2_PACKAGE_HAS_UDEV),y)
|
|
|
|
PCIUTILS_DEPENDENCIES += udev
|
|
|
|
PCIUTILS_MAKE_OPTS += HWDB=yes
|
|
|
|
else
|
|
|
|
PCIUTILS_MAKE_OPTS += HWDB=no
|
|
|
|
endif
|
|
|
|
|
2008-10-31 13:14:39 +01:00
|
|
|
ifeq ($(BR2_PACKAGE_ZLIB),y)
|
2015-04-09 23:22:05 +02:00
|
|
|
PCIUTILS_MAKE_OPTS += ZLIB=yes
|
2015-03-31 09:21:57 +02:00
|
|
|
PCIUTILS_DEPENDENCIES += zlib
|
2008-10-31 13:14:39 +01:00
|
|
|
else
|
2015-04-09 23:22:05 +02:00
|
|
|
PCIUTILS_MAKE_OPTS += ZLIB=no
|
2008-10-31 13:14:39 +01:00
|
|
|
endif
|
|
|
|
|
2013-04-26 16:24:17 +02:00
|
|
|
ifeq ($(BR2_PACKAGE_KMOD),y)
|
2015-03-31 09:21:57 +02:00
|
|
|
PCIUTILS_DEPENDENCIES += kmod
|
2015-04-09 23:22:05 +02:00
|
|
|
PCIUTILS_MAKE_OPTS += LIBKMOD=yes
|
2013-04-26 16:24:17 +02:00
|
|
|
else
|
2015-04-09 23:22:05 +02:00
|
|
|
PCIUTILS_MAKE_OPTS += LIBKMOD=no
|
2013-04-26 16:24:17 +02:00
|
|
|
endif
|
|
|
|
|
2014-12-03 22:41:29 +01:00
|
|
|
ifeq ($(BR2_STATIC_LIBS),y)
|
2015-04-09 23:22:05 +02:00
|
|
|
PCIUTILS_MAKE_OPTS += SHARED=no
|
2013-11-18 21:02:42 +01:00
|
|
|
else
|
2015-04-09 23:22:05 +02:00
|
|
|
PCIUTILS_MAKE_OPTS += SHARED=yes
|
2013-11-18 21:02:42 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
# Build after busybox since it's got a lightweight lspci
|
|
|
|
ifeq ($(BR2_PACKAGE_BUSYBOX),y)
|
2015-03-31 09:21:57 +02:00
|
|
|
PCIUTILS_DEPENDENCIES += busybox
|
2013-11-18 21:02:42 +01:00
|
|
|
endif
|
|
|
|
|
2010-04-11 10:26:24 +02:00
|
|
|
define PCIUTILS_CONFIGURE_CMDS
|
2010-05-24 08:22:26 +02:00
|
|
|
$(SED) 's/wget --no-timestamping/wget/' $(PCIUTILS_DIR)/update-pciids.sh
|
2008-10-31 13:14:39 +01:00
|
|
|
$(SED) 's/uname -s/echo Linux/' \
|
|
|
|
-e 's/uname -r/echo $(LINUX_HEADERS_VERSION)/' \
|
|
|
|
$(PCIUTILS_DIR)/lib/configure
|
2010-05-06 16:24:36 +02:00
|
|
|
$(SED) 's/^STRIP/#STRIP/' $(PCIUTILS_DIR)/Makefile
|
2010-04-11 10:26:24 +02:00
|
|
|
endef
|
|
|
|
|
|
|
|
define PCIUTILS_BUILD_CMDS
|
2013-11-18 21:02:42 +01:00
|
|
|
$(TARGET_MAKE_ENV) $(MAKE) -C $(@D) $(PCIUTILS_MAKE_OPTS) \
|
2010-05-24 08:22:26 +02:00
|
|
|
PREFIX=/usr
|
2010-04-11 10:26:24 +02:00
|
|
|
endef
|
|
|
|
|
|
|
|
define PCIUTILS_INSTALL_TARGET_CMDS
|
2013-11-18 21:02:42 +01:00
|
|
|
$(TARGET_MAKE_ENV) $(MAKE1) -C $(@D) $(PCIUTILS_MAKE_OPTS) \
|
2014-11-27 23:51:11 +01:00
|
|
|
PREFIX=$(TARGET_DIR)/usr SBINDIR=$(TARGET_DIR)/usr/bin \
|
|
|
|
install install-lib install-pcilib
|
2010-04-11 10:26:24 +02:00
|
|
|
endef
|
|
|
|
|
2012-06-02 08:13:56 +02:00
|
|
|
define PCIUTILS_INSTALL_STAGING_CMDS
|
2013-11-18 21:02:42 +01:00
|
|
|
$(TARGET_MAKE_ENV) $(MAKE1) -C $(@D) $(PCIUTILS_MAKE_OPTS) \
|
2014-11-27 23:51:11 +01:00
|
|
|
PREFIX=$(STAGING_DIR)/usr SBINDIR=$(STAGING_DIR)/usr/bin \
|
|
|
|
install install-lib install-pcilib
|
2012-06-02 08:13:56 +02:00
|
|
|
endef
|
|
|
|
|
2012-07-03 00:07:32 +02:00
|
|
|
$(eval $(generic-package))
|