stinkpot
stinkpot

Reputation: 70

arm-linux-gnueabi-ld unrecognized option '-Wl,--gc-sections'

I am try to do a QT opensource cross compiling, using standard arm-linux-gnueabi tool set which is installed via Ubuntu apt-get, but get these errors, and I have stuck here for 1 week: arm-linux-gnueabi-ld -Wl,--gc-sections -Wl,-O1 -fuse-ld=gold -Wl,--enable-new-dtags -o ../../../bin/rcc .obj/rcc.o .obj/main.o -L/home/charlie/qt-everywhere-opensource-src-5.5.0/qtbase/lib -lQt5Bootstrap -lpthread arm-linux-gnueabi-ld: unrecognized option '-Wl,--gc-sections' arm-linux-gnueabi-ld: use the --help option for usage information Makefile:194: recipe for target '../../../bin/rcc' failed

Is there anything wrong in the configure or tool set? Thanks

Upvotes: 2

Views: 3226

Answers (1)

ashwanth selvam
ashwanth selvam

Reputation: 506

The -Wl is used to pass options to linker from gcc. So your usage should be either

arm-linux-gnueabi-ld --gc-sections

or

arm-linux-gnueabi-gcc -Wl,--gc-sections

Upvotes: 3

Related Questions