[FS#448] Can't build with -flto and -Wl,--as-needed

LEDE Bugs lede-bugs at lists.infradead.org
Wed Feb 1 08:13:02 PST 2017


A new Flyspray task has been opened.  Details are below. 

User who did this - Cristian Morales Vega (RedDwarf) 

Attached to Project - LEDE Project
Summary - Can't build with -flto and -Wl,--as-needed
Task Type - Bug Report
Category - Toolchain
Status - Unconfirmed
Assigned To - 
Operating System - All
Severity - Low
Priority - Very Low
Reported Version - Trunk
Due in Version - Undecided
Due Date - Undecided
Details - Trying to compile "int main(){}" with -flto and -Wl,--as-needed fails.

gcc-5.4.0
binutils-2.25.1
 
$ STAGING_DIR=/lede/staging_dir/target-mips_24kc_musl-1.1.16/ /lede/staging_dir/toolchain-mips_24kc_gcc-5.4.0_musl-1.1.16/bin/mips-openwrt-linux-gcc -flto -Wl,--as-needed -o la la.c 
/lede/staging_dir/toolchain-mips_24kc_gcc-5.4.0_musl-1.1.16/lib/gcc/mips-openwrt-linux-musl/5.4.0/../../../../mips-openwrt-linux-musl/lib/libgcc_s.so.1: error adding symbols: Nonrepresentable section on output
collect2: error: ld returned 1 exit status

If either of the two options is removed there is no problem.


More information can be found at the following URL:
https://bugs.lede-project.org/index.php?do=details&task_id=448



More information about the lede-bugs mailing list