Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 946073 - net-firewall/iptables-1.8.11: fails to build with musl (error: redefinition of 'ethhdr')
Summary: net-firewall/iptables-1.8.11: fails to build with musl (error: redefinition o...
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords: PATCH
Depends on:
Blocks:
 
Reported: 2024-12-07 21:28 UTC by Violet Purcell
Modified: 2025-01-21 18:31 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,54.69 KB, text/x-log)
2024-12-07 21:28 UTC, Violet Purcell
Details
patch (0001-musl-build-fix.patch,1.46 KB, patch)
2024-12-07 21:29 UTC, Violet Purcell
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Violet Purcell 2024-12-07 21:28:55 UTC
Created attachment 913534 [details]
build.log

More of the linux headers clashing with musl headers issue.

emerge --info:
Portage 3.0.66.1 (python 3.13.0-final-0, default/linux/arm64/23.0/musl/llvm, [unavailable], musl-1.2.5-r4, 6.12.1-asahi-8 aarch64)
=================================================================
System uname: Linux-6.12.1-asahi-8-aarch64-with-libc
KiB Mem:    32389072 total,  10944160 free
KiB Swap:   33554416 total,  33463280 free
Head commit of repository gentoo: e9939fbb9072bb35c73d0d6c1a2f87cff69b1ba1

Head commit of repository asahi: af8155f7a0df5ec8fbe0d08239d5074e9195c27b

Head commit of repository guru: 41148541358cbb139ecc413d30b0fc1348ea5af7

Head commit of repository haskell: e53eef550c86e406df8d9feac69e3238538b9893

Head commit of repository llvm: 1142843c19d05f341fa9801c51e0d2ca198e1a69

Head commit of repository vimproved: 369a8f235fe2d77f2550f53ade9c1189df004f8e

Head commit of repository vimsys: c75d92915ccedcc8ed27ba515a5120d615c63af4

sh dash 0.5.12-r1
ld LLD 19.1.5 (compatible with GNU linkers)
app-misc/pax-utils:       1.3.8::gentoo
app-shells/bash:          5.2_p37::gentoo
dev-build/autoconf:       2.71-r7::gentoo, 2.72-r1::gentoo
dev-build/automake:       1.17-r1::gentoo
dev-build/cmake:          3.31.2::gentoo
dev-build/libtool:        2.5.4::gentoo
dev-build/make:           4.4.1-r100::gentoo
dev-build/meson:          1.6.0-r1::gentoo
dev-java/java-config:     2.3.4::gentoo
dev-lang/perl:            5.40.0-r1::gentoo
dev-lang/python:          3.12.7_p1::gentoo, 3.13.0::gentoo
dev-lang/rust:            1.82.0-r100::gentoo, 1.83.0::gentoo
sys-apps/baselayout:      2.17::gentoo
sys-apps/sandbox:         2.40::gentoo
sys-devel/clang:          19.1.5::llvm
sys-devel/lld:            19.1.5::llvm
sys-devel/llvm:           19.1.5-r1::llvm
sys-kernel/linux-headers: 6.12::gentoo (virtual/os-headers)
sys-libs/musl:            1.2.5-r4::vimsys
Repositories:

gentoo
    location: /var/db/repos/gentoo
    sync-type: git
    sync-uri: https://github.com/gentoo/gentoo.git
    priority: -1000
    volatile: False

asahi
    location: /var/db/repos/asahi
    sync-type: git
    sync-uri: https://github.com/chadmed/asahi-overlay.git
    masters: gentoo
    volatile: False

crossdev
    location: /var/db/repos/crossdev
    masters: gentoo
    volatile: False

guru
    location: /var/db/repos/guru
    sync-type: git
    sync-uri: https://github.com/gentoo/guru.git
    masters: gentoo
    volatile: False

haskell
    location: /var/db/repos/haskell
    sync-type: git
    sync-uri: https://github.com/gentoo-haskell/gentoo-haskell.git
    masters: gentoo
    volatile: False

llvm
    location: /var/db/repos/llvm
    sync-type: git
    sync-uri: https://codeberg.org/vimproved/llvm-overlay.git
    masters: gentoo
    volatile: False

vimproved
    location: /var/db/repos/vimproved
    sync-type: git
    sync-uri: https://codeberg.org/vimproved/overlay.git
    masters: gentoo
    volatile: False

vimsys
    location: /var/db/repos/vimsys
    sync-type: git
    sync-uri: https://codeberg.org/vimproved/vimsys.git
    masters: gentoo vimproved
    volatile: False

Installed sets: @common, @desktop, @devel, @games, @hwprofile-asahi, @openrc
ACCEPT_KEYWORDS="arm64 ~arm64"
ACCEPT_LICENSE="@FREE"
ADDR2LINE="llvm-addr2line"
AR="llvm-ar"
AS="clang -c"
CBUILD="aarch64-unknown-linux-musl"
CC="clang"
CFLAGS="-mcpu=native -O3 -pipe -flto=thin"
CHOST="aarch64-unknown-linux-musl"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt /var/bind"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CPP="clang-cpp"
CXX="clang++"
CXXFLAGS="-mcpu=native -O3 -pipe -flto=thin"
DISTDIR="/var/cache/distfiles"
EMERGE_DEFAULT_OPTS="--with-bdeps=y"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GDK_PIXBUF_MODULE_FILE GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR XDG_STATE_HOME"
FCFLAGS="-O2"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs binpkg-multi-instance buildpkg-live candy config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync merge-wait network-sandbox news parallel-fetch pid-sandbox pkgdir-index-trusted preserve-libs protect-owned qa-unresolved-soname-deps sandbox strict strict-keepdir unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync warn-on-large-env xattr"
FFLAGS="-O2"
GENTOO_MIRRORS="https://mirrors.rit.edu/gentoo/"
INSTALL_MASK="charset.alias /usr/share/locale/locale.alias"
LANG="en_US.UTF-8"
LD="ld.lld"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,--as-needed"
LEX="reflex"
LIBTOOL="rclibtool"
MAKEOPTS="-j12 LIBTOOL=rclibtool"
NM="llvm-nm"
OBJCOPY="llvm-objcopy"
OBJDUMP="llvm-objdump"
PKGDIR="/var/cache/binpkgs"
PORTAGE_COMPRESS="gzip"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
RANLIB="llvm-ranlib"
READELF="llvm-readelf"
RUSTFLAGS="-C target-cpu=native"
SHELL="/bin/zsh"
STRINGS="llvm-strings"
STRIP="llvm-strip"
USE="acl arm64 bzip2 clang crypt elogind iconv ipv6 libtirpc llvm-libunwind ncurses nls opengl openmp pam pcre pic readline seccomp ssl test-rust udev unicode vulkan wayland xattr zlib" ADA_TARGET="gcc_12" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_anon authn_dbm authn_file authz_dbm authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir env expires ext_filter file_cache filter headers include info log_config logio mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_ARM="edsp vfp vfpv3 vfpv4 vfp-d32 aes sha1 sha2 crc32 asimddp i8mm v8" ELIBC="musl" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax navcom oceanserver oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 tsip tripmate tnt ublox" GUILE_SINGLE_TARGET="3-0" GUILE_TARGETS="3-0" INPUT_DEVICES="libinput" KERNEL="linux" L10N="en en-US" LCD_DEVICES="bayrad cfontz glk hd44780 lb216 lcdm001 mtxorb text" LLVM_SLOT="19" LLVM_TARGETS="AArch64" LUA_SINGLE_TARGET="luajit" LUA_TARGETS="luajit" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php8-2" POSTGRES_TARGETS="postgres16" PYTHON_SINGLE_TARGET="python3_13" PYTHON_TARGETS="python3_12 python3_13" RUBY_TARGETS="ruby33" VIDEO_CARDS="asahi honeykrisp" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipp2p iface geoip fuzzy condition tarpit sysrq proto logmark ipmark dhcpmac delude chaos account"
YACC="byacc"
Unset:  ARFLAGS, ASFLAGS, CCLD, CONFIG_SHELL, CPPFLAGS, CTARGET, CXXFILT, ELFEDIT, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, LC_ALL, LFLAGS, LINGUAS, MAKE, MAKEFLAGS, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PYTHONPATH, SIZE, YFLAGS
Comment 1 Violet Purcell 2024-12-07 21:29:44 UTC
Created attachment 913535 [details, diff]
patch
Comment 2 ernsteiswuerfel archtester 2024-12-18 11:29:07 UTC
Thanks Violet! Works for me.
Comment 3 Fabian Groffen gentoo-dev 2024-12-18 19:31:02 UTC
Is there an upstream ref for this patch?

FWIW I can confirm the patch is working on my amd64-musl.