sys-fs/udev-218 fails to build near the end of the compilation process. x86_64 arch. gcc version 4.7.2. only "kmod" USE flag is enabled. udev-217 compiles fine. Here's are the last lines from the compile: libtool: link: x86_64-pc-linux-gnu-gcc -shared -fPIC -DPIC src/libudev/.libs/libudev_la-libudev.o src/libudev/.libs/libudev_la-libudev-list.o src/libudev/.libs/libudev_la-libudev-util.o src/libudev/.libs/libudev_la-libudev-device.o src/libudev/.libs/libudev_la-libudev-enumerate.o src/libudev/.libs/libudev_la-libudev-monitor.o src/libudev/.libs/libudev_la-libudev-queue.o src/libudev/.libs/libudev_la-libudev-hwdb.o -Wl,--whole-archive ./.libs/libsystemd-internal.a ./.libs/libsystemd-shared.a -Wl,--no-whole-archive -Wl,--as-needed -ldw -lrt -ldl -march=k8 -mtune=k8 -O2 -Wl,--no-undefined -Wl,--gc-sections -Wl,-z -Wl,relro -Wl,-z -Wl,now -Wl,--version-script=/var/tmp/portage/sys-fs/udev-218/work/systemd-218/src/libudev/libudev.sym -Wl,-O1 -pthread -Wl,-soname -Wl,libudev.so.1 -o .libs/libudev.so.1.6.2 ./.libs/libsystemd-internal.a(libsystemd_internal_la-bus-error.o): In function `bus_error_name_to_errno': bus-error.c:(.text.bus_error_name_to_errno+0x9b): undefined reference to `__stop_BUS_ERROR_MAP' bus-error.c:(.text.bus_error_name_to_errno+0xa2): undefined reference to `__start_BUS_ERROR_MAP' collect2: error: ld returned 1 exit status Reproducible: Always
Created attachment 392384 [details] Some more bits from the build.log
Comment on attachment 392384 [details] Some more bits from the build.log 1) Please attach the entire build log to this bug report. 2) Please post your `emerge --info sys-fs/udev' output in a comment.
Upgrading my binutils from 2.20 to 2.24 solved the problem. It's not an uncommon problem either: https://www.marshut.net/kttspt/build-error-with-218-undefined-reference-to-start-bus-error-map.html "Some really old ld versions would end up dropping these sections a bit too eagerly: https://sourceware.org/bugzilla/show_bug.cgi?id=11133"
Apparently "it does not happen with binutils-2.23.2 and binutils-2.24". This should probably become a DEPEND in the ebuild?