aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAisha Tammy <gentoo@aisha.cc>2022-08-14 11:41:18 +0000
committerAisha Tammy <gentoo@aisha.cc>2022-08-14 11:41:18 +0000
commit6112c98a7cb96b68eba7366702145d60a9c65aba (patch)
tree194d7cef026aebc6133ff902824a1690d53324be /sys-kernel
parentnet-libs/dpdk: fix objdump calls (diff)
downloadguru-6112c98a7cb96b68eba7366702145d60a9c65aba.tar.gz
guru-6112c98a7cb96b68eba7366702145d60a9c65aba.tar.bz2
guru-6112c98a7cb96b68eba7366702145d60a9c65aba.zip
sys-kernel/rte_kni-kmod: fix objdump calls
Closes: https://bugs.gentoo.org/842315 Signed-off-by: Aisha Tammy <gentoo@aisha.cc>
Diffstat (limited to 'sys-kernel')
-rw-r--r--sys-kernel/rte_kni-kmod/files/dpdk-22.03-binutils.patch60
-rw-r--r--sys-kernel/rte_kni-kmod/rte_kni-kmod-22.03.ebuild10
2 files changed, 69 insertions, 1 deletions
diff --git a/sys-kernel/rte_kni-kmod/files/dpdk-22.03-binutils.patch b/sys-kernel/rte_kni-kmod/files/dpdk-22.03-binutils.patch
new file mode 100644
index 000000000..db34aca18
--- /dev/null
+++ b/sys-kernel/rte_kni-kmod/files/dpdk-22.03-binutils.patch
@@ -0,0 +1,60 @@
+diff --git a/buildtools/check-symbols.sh b/buildtools/check-symbols.sh
+index e458c0a..9031a18 100755
+--- a/buildtools/check-symbols.sh
++++ b/buildtools/check-symbols.sh
+@@ -22,7 +22,7 @@ fi
+
+ DUMPFILE=$(mktemp -t dpdk.${0##*/}.objdump.XXXXXX)
+ trap 'rm -f "$DUMPFILE"' EXIT
+-objdump -t $OBJFILE >$DUMPFILE
++@OBJDUMP@ -t $OBJFILE >$DUMPFILE
+
+ ret=0
+
+diff --git a/buildtools/meson.build b/buildtools/meson.build
+index e1c600e..6b09e63 100644
+--- a/buildtools/meson.build
++++ b/buildtools/meson.build
+@@ -4,7 +4,7 @@
+ pkgconf = find_program('pkg-config', 'pkgconf', required: false)
+ check_symbols = find_program('check-symbols.sh')
+ ldflags_ibverbs_static = find_program('options-ibverbs-static.sh')
+-objdump = find_program('objdump', 'llvm-objdump')
++objdump = find_program('@OBJDUMP@')
+
+ python3 = import('python').find_installation(required: false)
+ if python3.found()
+@@ -24,18 +24,11 @@ binutils_avx512_check = (py3 + files('binutils-avx512-check.py') +
+ # select library and object file format
+ pmdinfo = py3 + files('gen-pmdinfo-cfile.py') + [meson.current_build_dir()]
+ pmdinfogen = py3 + files('pmdinfogen.py')
++ar = find_program('ar')
++pmdinfo += ar
+ if host_machine.system() == 'windows'
+- if cc.get_id() == 'gcc'
+- pmdinfo += 'ar'
+- else
+- pmdinfo += 'llvm-ar'
+- endif
+ pmdinfogen += 'coff'
+-elif host_machine.system() == 'freebsd'
+- pmdinfo += 'llvm-ar'
+- pmdinfogen += 'elf'
+ else
+- pmdinfo += 'ar'
+ pmdinfogen += 'elf'
+ endif
+
+diff --git a/devtools/check-abi-version.sh b/devtools/check-abi-version.sh
+index f0cca42..6efe1eb 100755
+--- a/devtools/check-abi-version.sh
++++ b/devtools/check-abi-version.sh
+@@ -28,7 +28,7 @@ NEXT_ABIVER="DPDK_$((${2-$DEFAULT_ABI}+1))"
+ ret=0
+
+ # get output of objdump
+-OBJ_DUMP_OUTPUT=`objdump -TC --section=.text ${LIB} 2>&1 | grep ".text"`
++OBJ_DUMP_OUTPUT=`@OBJDUMP@ -TC --section=.text ${LIB} 2>&1 | grep ".text"`
+
+ # there may not be any .text sections in the .so file, in which case exit early
+ echo "${OBJ_DUMP_OUTPUT}" | grep "not found in any input file" -q
diff --git a/sys-kernel/rte_kni-kmod/rte_kni-kmod-22.03.ebuild b/sys-kernel/rte_kni-kmod/rte_kni-kmod-22.03.ebuild
index 44e368c06..f0b7092e5 100644
--- a/sys-kernel/rte_kni-kmod/rte_kni-kmod-22.03.ebuild
+++ b/sys-kernel/rte_kni-kmod/rte_kni-kmod-22.03.ebuild
@@ -41,13 +41,21 @@ BDEPEND="
${PYTHON_DEPS}
"
-CONFIG_CHECK="~IOMMU_SUPPORT ~AMD_IOMMU ~VFIO ~VFIO_PCI ~UIO ~UIO_PDRV_GENIRQ ~UIO_DMEM_GENIRQ ~HPET_MMAP"
+PATCHES=( "${FILESDIR}/dpdk-22.03-binutils.patch" )
pkg_setup() {
linux-mod_pkg_setup
python-single-r1_pkg_setup
}
+src_prepare() {
+ default
+ sed -e "s/@OBJDUMP@/$(tc-getOBJDUMP)/g" -i \
+ buildtools/meson.build \
+ buildtools/check-symbols.sh \
+ devtools/check-abi-version.sh || die
+}
+
src_configure() {
linux-mod_pkg_setup
python-single-r1_pkg_setup