Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 530318 - net-misc/lksctp-tools-1.0.16 with gold linker - ld: error: symbol sctp_connectx has undefined version
Summary: net-misc/lksctp-tools-1.0.16 with gold linker - ld: error: symbol sctp_connec...
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Luca Barbato
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: systemwide-gold
  Show dependency tree
 
Reported: 2014-11-24 11:41 UTC by Jeroen Roovers (RETIRED)
Modified: 2022-12-20 17:03 UTC (History)
6 users (show)

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


Attachments
net-misc:lksctp-tools-1.0.16:20141124-113421.log (20141124-113421.log,31.12 KB, text/plain)
2014-11-24 11:41 UTC, Jeroen Roovers (RETIRED)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jeroen Roovers (RETIRED) gentoo-dev 2014-11-24 11:41:12 UTC
Created attachment 390186 [details]
net-misc:lksctp-tools-1.0.16:20141124-113421.log

Mon 24 Nov 12:40:19 CET 2014
emerge --info lksctp-tools
Portage 2.2.14 (python 3.3.5-final-0, default/linux/amd64/13.0/no-multilib, gcc-4.8.3, glibc-2.19-r1, 3.17.2-gentoo-JeR x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-3.17.2-gentoo-JeR-x86_64-Intel-R-_Core-TM-2_Duo_CPU_E8400_@_3.00GHz-with-gentoo-2.2
KiB Mem:     4052412 total,   1370396 free
KiB Swap:    2097148 total,   1969760 free
Timestamp of tree: Sun, 23 Nov 2014 22:45:01 +0000
ld GNU ld (Gentoo 2.24 p1.4) 2.24
distcc 3.1 x86_64-pc-linux-gnu [enabled]
ccache version 3.1.9 [disabled]
app-shells/bash:          4.2_p53
dev-java/java-config:     2.2.0
dev-lang/perl:            5.18.2-r2
dev-lang/python:          2.7.7, 3.2.5-r6, 3.3.5-r1, 3.4.2
dev-util/ccache:          3.1.9-r3
dev-util/cmake:           2.8.12.2-r1
dev-util/pkgconfig:       0.28-r1
sys-apps/baselayout:      2.2
sys-apps/openrc:          0.12.4
sys-apps/sandbox:         2.6-r1
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.11.6-r1, 1.13.4, 1.14.1
sys-devel/binutils:       2.22-r1, 2.23.1, 2.23.2, 2.24-r3
sys-devel/gcc:            4.6.3, 4.7.3-r1, 4.8.1-r1, 4.8.3, 4.9.1, 4.9.2
sys-devel/gcc-config:     1.7.3
sys-devel/libtool:        2.4.2-r1
sys-devel/make:           4.0-r1
sys-kernel/linux-headers: 3.17 (virtual/os-headers)
sys-libs/glibc:           2.19-r1
Repositories: gentoo JeR steam-overlay
ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-frecord-gcc-switches -g -pipe -O2 -Wall -Wformat=2 -march=core2 -mcx16 -msahf -mno-movbe -mno-aes -mno-pclmul -mno-popcnt -mno-abm -mno-lwp -mno-fma -mno-fma4 -mno-xop -mno-bmi -mno-bmi2 -mno-tbm -mno-avx -mno-avx2 -mno-sse4.2 -msse4.1 -mno-lzcnt -mno-rdrnd -mno-f16c -mno-fsgsbase --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=6144 -mtune=core2 -Wno-comment"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/lib/ccache/bin /usr/lib/distcc/bin /usr/share/config /usr/share/gnupg/qualified.txt /var/lib/hsqldb /var/yp/Makefile"
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/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-frecord-gcc-switches -g -pipe -O2 -Wall -Wformat=2 -march=core2 -mcx16 -msahf -mno-movbe -mno-aes -mno-pclmul -mno-popcnt -mno-abm -mno-lwp -mno-fma -mno-fma4 -mno-xop -mno-bmi -mno-bmi2 -mno-tbm -mno-avx -mno-avx2 -mno-sse4.2 -msse4.1 -mno-lzcnt -mno-rdrnd -mno-f16c -mno-fsgsbase --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=6144 -mtune=core2"
DISTDIR="/world/distfiles"
EMERGE_DEFAULT_OPTS="--autounmask=n"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs buildpkg cgroup compressdebug config-protect-if-modified distcc distlocks fixlafiles merge-sync metadata-transfer multilib-strict news parallel-fetch preserve-libs protect-owned sandbox sfperms sign splitdebug strict test-fail-continue unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS=" http://mirror.netcologne.de/gentoo/ http://ftp.snt.utwente.nl/pub/os/linux/gentoo http://gentoo.tiscali.nl/ http://mirror.leaseweb.com/gentoo/ "
LANG="en_GB.utf8"
LDFLAGS="-Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed"
MAKEOPTS="-j2"
PKGDIR="/newaches/gentoo/packages/wim"
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"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/world/gentoo/portage"
PORTDIR_OVERLAY="/keeps/gentoo/local /newaches/gentoo/layman/steam"
SYNC="rsync://rsync.nl.gentoo.org/gentoo-portage"
USE="256-color X a52 aac acl acpi alsa amd64 apng bash-completion berkdb bluetooth bzip2 cairo cli consolekit cracklib crypt cups cxx dbus distinct-l dri drm egl flac fortran gdbm gif gles gles1 gles2 graphite gtk gudev hwdb i3 iconv idn introspection ipv6 jack jpeg kde kmod lame lzma minizip mmx mmxext mng modules mtp multislot multitarget musepack ncat ncurses netlink nfs nls nonblockdialogs nptl offensive ogg opencv opengl openmp openrc opus pam pcre perl png policykit python qml qt3support quesoglc readline samba savedconfig sensord session sloppy smp socks5 sse sse2 sse3 sse4 sse4_1 ssl ssse3 system-libCg tcpd test theora threads tiff tinfo truetype unicode unwind upower uvm vdpau vim-syntax vorbis wavpack wayland webkit2 x264 xa xattr xcb xft xinerama zlib" ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="rrdtool rrdcached" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="en_GB en nl" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_3 python3_4" QEMU_SOFTMMU_TARGETS="i386" QEMU_USER_TARGETS="i386" RUBY_TARGETS="ruby20" USERLAND="GNU" VIDEO_CARDS="nvidia" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
USE_PYTHON="2.7 3.3"
Unset:  CPPFLAGS, CTARGET, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

[ebuild  N    ] net-misc/lksctp-tools-1.0.13  USE="-static-libs"
Comment 1 Andrew John Hughes 2015-06-07 18:24:49 UTC
Same issue seen here. ld.bfd and ld.gold seem to handle the version map differently.
Comment 2 Pandu POLUAN 2016-11-05 16:22:06 UTC
Also confirmed here.
Comment 3 ehrich.weiss 2016-12-29 01:10:28 UTC
Confirmed here as well. If I switch to ld.bfd, the problem goes away.
Comment 4 Jocelyn Mayer 2022-12-18 13:05:27 UTC
This problem, or a similar one, seems always releveant with version 1.0.19-r1

This tiny patch seems to fix this issue:
--- lksctp-tools-1.0.19/src/lib/connectx.c      2021-09-01 13:05:56.966925187 +0200
+++ lksctp-tools-1.0.19/src/lib/connectx.c      2021-09-01 13:06:57.795679552 +0200
@@ -195,3 +195,6 @@ int sctp_connectx3(int fd, struct sockad
        return __connectx(fd, addrs, addrs_size, id);
 }
 
+__attribute__(( __alias__("sctp_connectx3") ))
+int sctp_connectx(int fd, struct sockaddr *addrs, int addrcnt,
+                      sctp_assoc_t *id);
Comment 5 Jocelyn Mayer 2022-12-20 17:03:02 UTC
Update: this fix is not compatible with LTO...
It would end with a "multiple symbol definition" error at link time.
Compiling with this patch would only do if using gcc without LTO as far as I can see.

It seems that the proper fix is to append -fpic -fPIC and disable LTO,
_this is to be confirmed_.