mirror of
git://git.openembedded.org/meta-openembedded
synced 2026-09-04 02:22:38 +00:00
After commit 1997d3d6c43348c663f3295dac3a906ad38549a4 (net-snmp: Do not pass LDFLAGS to compiler), some linker flags, like "-Wl,--as-needed", appear too late on the linker command line. Backport a patch that corrects the order of the arguments given to the linker. Unfortunately, the patch is not enough. libtool reorders the arguments given to libtool --mode=link so that any lib dependencies appear before other linker arguments. Therefore it is needed to inject -Wl,--as-needed on the linker command line that libtool produces. Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>