add ld assert-deflib and guidance to gate build
Build on sparc is failing with:
Undefined first referenced symbol in file inet_pton pics/dhcp_inittab.o (symbol belongs to implicit dependency /lib/libnsl.so.1) inet_ntoa pics/dhcp_inittab.o (symbol belongs to implicit dependency /lib/libnsl.so.1) inet_ntop pics/dhcp_inittab.o (symbol belongs to implicit dependency /lib/libnsl.so.1) ld: fatal: symbol referencing errors. No output written to libdhcputil.so.1
The actual issue is not about missing -lnsl option, the libc was not built due to other errors and libdhcputil was linked against build host libc instead. Since that libc was old enough not to have new symbols, we did end up in error above.
The fix for this issue has been developed for quite some time, in this patch I have picked up
changes from Richard (who in turn did pick up from Robert). The idea is simple - introduce linker
checks to ensure we do perform link with correct components.
The core of the change is in Makefile.master, the rest is really about cleaning the build.
Testing done: build/install/boot on x86, build on sparc.
Updated by Electric Monk over 1 year ago
- Status changed from In Progress to Closed
- % Done changed from 90 to 100
commit 5801b0f01c3c34499a929ed96164a5a68b470945 Author: Toomas Soome <firstname.lastname@example.org> Date: 2020-02-05T17:00:00.000Z 12217 add ld assert-deflib and guidance to gate build Reviewed by: Robert Mustacchi <email@example.com> Reviewed by: Gergő Mihály Doma <firstname.lastname@example.org> Approved by: Dan McDonald <email@example.com>