[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Bug#1104037: golang-github-iovisor-gobpf: Add utsname support for riscv64 and loong64



Hi,

On Thu, Apr 24, 2025 at 09:30:25PM +0200, Domenico Andreoli wrote:
[...]

Hi Bo,

now golang-github-iovisor-gobpf is missing utsname support for riscv64
and loong64, this will lead to FTBFS from opensnitch on these
architectures, see [0] and [1]. In fact this will also casuse the build
to fail on these two architectures. Two PRs to support both architectures
separately has been sent upstream, but has not yet been merged(inactive
upstream), so I backport them to here.

I see that your backport is not consistent with https://github.com/iovisor/gobpf/pull/316,
where the utsname for loong64 is of type int8. Any reason for this?

Thanks for the review!

You're right -- I mistakenly merged the two upstream PRs into one, thinking it would make
things simpler to reduce maintenance burden, but I missed the fact that they touched different
files and handled things differently (especially the utsname type for loong64). Sorry about
the confusion!

I have separated the patch to match the original upstream changes more closely. I'd really appreciate it if someone familiar with the loong64 port could also take a look.

...


Could you apply this on next upload?

Give me a couple of more days so that the package migrates to testing.

Thank you. :) and please let me know any issue next.

--
Regards,
--
  Bo YU

diff -Nru golang-github-iovisor-gobpf-0.2.0/debian/changelog golang-github-iovisor-gobpf-0.2.0/debian/changelog
--- golang-github-iovisor-gobpf-0.2.0/debian/changelog	2025-04-15 15:42:23.000000000 +0000
+++ golang-github-iovisor-gobpf-0.2.0/debian/changelog	2025-04-24 12:16:21.000000000 +0000
@@ -1,3 +1,10 @@
+golang-github-iovisor-gobpf (0.2.0-9.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Add build support for loong64 and riscv64. (Closes: #1104037) 
+
+ -- Bo YU <vimer@debian.org>  Thu, 24 Apr 2025 12:16:21 +0000
+
 golang-github-iovisor-gobpf (0.2.0-9) unstable; urgency=medium
 
   * While checking if debian/copyright-scan is up to date, skip all the
diff -Nru golang-github-iovisor-gobpf-0.2.0/debian/patches/add-utsname-support-loong64.patch golang-github-iovisor-gobpf-0.2.0/debian/patches/add-utsname-support-loong64.patch
--- golang-github-iovisor-gobpf-0.2.0/debian/patches/add-utsname-support-loong64.patch	1970-01-01 00:00:00.000000000 +0000
+++ golang-github-iovisor-gobpf-0.2.0/debian/patches/add-utsname-support-loong64.patch	2025-04-24 12:16:21.000000000 +0000
@@ -0,0 +1,14 @@
+Description: Add utsname support for loong64
+Origin: upstream, https://github.com/iovisor/gobpf/pull/316
+Bug-debian: https://bugs.debian.org/1104037
+Last-Update: 2025-04-24
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/elf/utsname_int8.go
++++ b/elf/utsname_int8.go
+@@ -1,4 +1,4 @@
+-// +build linux,386 linux,amd64 linux,arm64
++// +build linux,386 linux,amd64 linux,arm64 linux,loong64
+ 
+ package elf
+ 
diff -Nru golang-github-iovisor-gobpf-0.2.0/debian/patches/add-utsname-support-riscv64.patch golang-github-iovisor-gobpf-0.2.0/debian/patches/add-utsname-support-riscv64.patch
--- golang-github-iovisor-gobpf-0.2.0/debian/patches/add-utsname-support-riscv64.patch	1970-01-01 00:00:00.000000000 +0000
+++ golang-github-iovisor-gobpf-0.2.0/debian/patches/add-utsname-support-riscv64.patch	2025-04-24 12:16:21.000000000 +0000
@@ -0,0 +1,14 @@
+Description: elf: Add utsname support for riscv64
+Origin: upstream, https://github.com/iovisor/gobpf/pull/324
+Bug-debian: https://bugs.debian.org/1104037
+Last-Update: 2025-04-24
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/elf/utsname_uint8.go
++++ b/elf/utsname_uint8.go
+@@ -1,4 +1,4 @@
+-// +build linux,arm linux,ppc64 linux,ppc64le s390x
++// +build linux,arm linux,ppc64 linux,ppc64le linux,riscv64 s390x
+ 
+ package elf
+ 
diff -Nru golang-github-iovisor-gobpf-0.2.0/debian/patches/series golang-github-iovisor-gobpf-0.2.0/debian/patches/series
--- golang-github-iovisor-gobpf-0.2.0/debian/patches/series	2025-04-15 15:42:23.000000000 +0000
+++ golang-github-iovisor-gobpf-0.2.0/debian/patches/series	2025-04-24 12:16:21.000000000 +0000
@@ -1 +1,3 @@
 support-for-new-bcc_func_load-signature.patch
+add-utsname-support-riscv64.patch
+add-utsname-support-loong64.patch

Attachment: signature.asc
Description: PGP signature


Reply to: