summaryrefslogtreecommitdiffstats
path: root/meta/recipes-bsp/pciutils
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-bsp/pciutils')
-rw-r--r--meta/recipes-bsp/pciutils/pciutils/configure.patch90
-rw-r--r--meta/recipes-bsp/pciutils/pciutils_3.12.0.bb (renamed from meta/recipes-bsp/pciutils/pciutils_3.11.1.bb)54
2 files changed, 22 insertions, 122 deletions
diff --git a/meta/recipes-bsp/pciutils/pciutils/configure.patch b/meta/recipes-bsp/pciutils/pciutils/configure.patch
deleted file mode 100644
index 5015cf4884..0000000000
--- a/meta/recipes-bsp/pciutils/pciutils/configure.patch
+++ /dev/null
@@ -1,90 +0,0 @@
1From 561216c8cbc280aaa9aecf30cb11835a4a0a78ed Mon Sep 17 00:00:00 2001
2From: Richard Purdie <rpurdie@linux.intel.com>
3Date: Wed, 31 Dec 2008 17:20:38 +0000
4Subject: [PATCH] pciutils: Upgarde 2.2.4 -> 3.0.3
5
6This patch:
7* ensures we link correctly
8* allows us to optionally pass target information to configure rather than using uname
9* select linux as the platform in most cases we care about
10
11This is a merge of various tweaks to allow us to build pciutils including
12work from:
13
147/30/2010 - Qing He <qing.he@intel.com>
151/22/2012 - Shane Wang <shane.wang@intel.com>
16Ionut Radu <ionutx.radu@intel.com>
172017/6/15 - RP - Cleanups and merging patches
18
19Upstream-Status: Inappropriate [embedded specific]
20---
21 Makefile | 2 +-
22 lib/configure | 14 ++++++++++----
23 2 files changed, 11 insertions(+), 5 deletions(-)
24
25diff --git a/Makefile b/Makefile
26index aaec04e..9c1dab0 100644
27--- a/Makefile
28+++ b/Makefile
29@@ -123,7 +123,7 @@ pcilmr$(EXEEXT): pcilmr.o $(LMROBJS) $(COMMON) lib/$(PCIIMPLIB)
30 pcilmr.o: pcilmr.c $(LMRINC)
31
32 %$(EXEEXT): %.o
33- $(CC) $(LDFLAGS) $(TARGET_ARCH) $^ $(LDLIBS) -o $@
34+ $(CC) $(LDFLAGS) $(TARGET_ARCH) $^ $(LIB_LDLIBS) $(LDLIBS) -o $@
35
36 ifdef PCI_OS_WINDOWS
37 comma := ,
38diff --git a/lib/configure b/lib/configure
39index 3df057a..c87e71c 100755
40--- a/lib/configure
41+++ b/lib/configure
42@@ -9,6 +9,10 @@ echo_n() {
43 printf '%s' "$*"
44 }
45
46+VERSION=$1
47+IDSDIR=$2
48+DNS=yes
49+
50 if [ -z "$VERSION" ] ; then
51 echo >&2 "Please run the configure script from the top-level Makefile"
52 exit 1
53@@ -16,8 +20,8 @@ fi
54
55 echo_n "Configuring libpci for your system..."
56 if [ -z "$HOST" ] ; then
57- sys=`uname -s`
58- rel=`uname -r`
59+ sys=${3:-`uname -s`}
60+ rel=
61 realsys="$sys"
62 if [ "$sys" = "AIX" -a -x /usr/bin/oslevel -a -x /usr/sbin/lsattr ]
63 then
64@@ -25,7 +29,7 @@ if [ -z "$HOST" ] ; then
65 proc=`/usr/sbin/lsdev -C -c processor -S available -F name | head -1`
66 cpu=`/usr/sbin/lsattr -F value -l $proc -a type | sed 's/_.*//'`
67 else
68- cpu=`uname -m | sed 's/^i.86-AT386/i386/;s/^i.86$/i386/;s/^sun4u$/sparc64/;s/^i86pc$/i386/;s/^BePC$/i386/;s/^BeMac$/powerpc/;s/^BeBox$/powerpc/'`
69+ cpu=${4:-`uname -m | sed 's/^i.86-AT386/i386/;s/^i.86$/i386/;s/^sun4u$/sparc64/;s/^i86pc$/i386/;s/^BePC$/i386/;s/^BeMac$/powerpc/;s/^BeBox$/powerpc/'`}
70 fi
71 if [ "$sys" = "DragonFly" ]
72 then
73@@ -43,7 +47,7 @@ if [ -z "$HOST" ] ; then
74 then
75 sys=cygwin
76 fi
77- HOST=${3:-$cpu-$sys}
78+ HOST=$cpu-$sys
79 fi
80 [ -n "$RELEASE" ] && rel="${RELEASE}"
81 # CAVEAT: tr on Solaris is a bit weird and the extra [] is otherwise harmless.
82@@ -52,6 +56,8 @@ cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
83 sys=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
84 echo " $host $rel $cpu $sys"
85
86+{ echo "$host" | grep linux; } && sys=linux
87+
88 c=config.h
89 m=config.mk
90 echo >$c '#define PCI_CONFIG_H'
diff --git a/meta/recipes-bsp/pciutils/pciutils_3.11.1.bb b/meta/recipes-bsp/pciutils/pciutils_3.12.0.bb
index 044074ccc3..2db0895bf4 100644
--- a/meta/recipes-bsp/pciutils/pciutils_3.11.1.bb
+++ b/meta/recipes-bsp/pciutils/pciutils_3.12.0.bb
@@ -1,7 +1,7 @@
1SUMMARY = "PCI utilities" 1SUMMARY = "PCI utilities"
2DESCRIPTION = 'The PCI Utilities package contains a library for portable access \ 2DESCRIPTION = 'The PCI Utilities package contains a library for portable access \
3to PCI bus configuration space and several utilities based on this library.' 3to PCI bus configuration space and several utilities based on this library.'
4HOMEPAGE = "http://atrey.karlin.mff.cuni.cz/~mj/pciutils.shtml" 4HOMEPAGE = "https://mj.ucw.cz/sw/pciutils/"
5SECTION = "console/utils" 5SECTION = "console/utils"
6 6
7LICENSE = "GPL-2.0-or-later" 7LICENSE = "GPL-2.0-or-later"
@@ -9,41 +9,27 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
9# Can drop make-native when all systems have make 4.3 9# Can drop make-native when all systems have make 4.3
10# https://git.savannah.gnu.org/cgit/make.git/commit/?id=b90fabc8d6f34fb37d428dc0fb1b8b1951a9fbed 10# https://git.savannah.gnu.org/cgit/make.git/commit/?id=b90fabc8d6f34fb37d428dc0fb1b8b1951a9fbed
11# causes space issues in lib/libpci.pc 11# causes space issues in lib/libpci.pc
12DEPENDS = "zlib kmod make-native" 12DEPENDS = "make-native"
13 13
14SRC_URI = "${KERNELORG_MIRROR}/software/utils/pciutils/pciutils-${PV}.tar.xz \ 14SRC_URI = "${KERNELORG_MIRROR}/software/utils/pciutils/pciutils-${PV}.tar.xz"
15 file://configure.patch" 15SRC_URI[sha256sum] = "f185d116d5ff99b797497efce8f19f1ee8ccc5a668b97a159e3d13472f674154"
16
17SRC_URI[sha256sum] = "3f472ad864473de5ba17f765cc96ef5f33e1b730918d3adda6f945a2a9290df4"
18 16
19inherit multilib_header pkgconfig update-alternatives 17inherit multilib_header pkgconfig update-alternatives
20 18
21PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'hwdb', '', d)}" 19PACKAGECONFIG ??= "hwdb kmod zlib"
22PACKAGECONFIG[hwdb] = "HWDB=yes,HWDB=no,udev" 20PACKAGECONFIG[hwdb] = "HWDB=yes,HWDB=no,udev"
23 21PACKAGECONFIG[kmod] = "LIBKMOD=yes,LIBKMOD=no,kmod"
24PCI_CONF_FLAG = "ZLIB=yes DNS=yes SHARED=yes STRIP= LIBDIR=${libdir}" 22PACKAGECONFIG[zlib] = "ZLIB=yes,ZLIB=no,zlib"
25 23
26# see configure.patch 24# Configuration options
27do_configure () { 25EXTRA_OEMAKE += "${PACKAGECONFIG_CONFARGS} DNS=yes SHARED=yes"
28 ( 26# Construct a HOST that matches what lib/configure expects
29 cd lib && \ 27EXTRA_OEMAKE += "HOST="${HOST_ARCH}-${HOST_OS}""
30 # PACKAGECONFIG_CONFARGS for this recipe could only possibly contain 'HWDB=yes/no', 28# Toolchain. We need to pass CFLAGS via CC as this is the only variable
31 # so we put it before ./configure 29# available to the caller without clobbering assignments (notably, -fPIC)
32 ${PCI_CONF_FLAG} ${PACKAGECONFIG_CONFARGS} ./configure ${PV} ${datadir} ${TARGET_OS} ${TARGET_ARCH} 30EXTRA_OEMAKE += "CC="${CC} ${CFLAGS}" AR="${AR}" STRIP= LDFLAGS="${LDFLAGS}""
33 ) 31# Paths
34} 32EXTRA_OEMAKE += "PREFIX=${prefix} LIBDIR=${libdir} SBINDIR=${sbindir} SHAREDIR=${datadir} MANDIR=${mandir}"
35
36export PREFIX = "${prefix}"
37export SBINDIR = "${sbindir}"
38export SHAREDIR = "${datadir}"
39export MANDIR = "${mandir}"
40
41EXTRA_OEMAKE = "-e MAKEFLAGS= ${PCI_CONF_FLAG}"
42
43ASNEEDED = ""
44
45# The configure script breaks if the HOST variable is set
46HOST[unexport] = "1"
47 33
48do_install () { 34do_install () {
49 oe_runmake DESTDIR=${D} install install-lib 35 oe_runmake DESTDIR=${D} install install-lib
@@ -54,11 +40,15 @@ do_install () {
54} 40}
55 41
56PACKAGES =+ "${PN}-ids libpci" 42PACKAGES =+ "${PN}-ids libpci"
43
57FILES:${PN}-ids = "${datadir}/pci.ids*" 44FILES:${PN}-ids = "${datadir}/pci.ids*"
58FILES:libpci = "${libdir}/libpci.so.*"
59SUMMARY:${PN}-ids = "PCI utilities - device ID database" 45SUMMARY:${PN}-ids = "PCI utilities - device ID database"
60DESCRIPTION:${PN}-ids = "Package providing the PCI device ID database for pciutils." 46DESCRIPTION:${PN}-ids = "Package providing the PCI device ID database for pciutils."
61RDEPENDS:${PN} += "${PN}-ids" 47RDEPENDS:${PN} += "${PN}-ids"
62 48
49FILES:libpci = "${libdir}/libpci.so.*"
50# The versioned symbols in libpci appear to be causing relocations
51INSANE_SKIP:libpci += "textrel"
52
63ALTERNATIVE:${PN} = "lspci" 53ALTERNATIVE:${PN} = "lspci"
64ALTERNATIVE_PRIORITY = "100" 54ALTERNATIVE_PRIORITY = "100"