Fix cross compile on Ubuntu

When cross compiling on Ubuntu with LTO enabled, the linker will complain about the "-fno-fat-objects" parameter even if the "-fuse-linker-plugin" is passed it.
But if the "-fno-fat-objects" parameter is removed, the linker will complain about "don't support linker plugin in this mode".
Remove both parameters can fix this.

Change-Id: I2d792ca70737f2e82a360bfc597f2b110513b954
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
Yuhang Zhao 2019-03-30 13:52:48 +08:00
parent 20b7e18146
commit 387f120bf9

View File

@ -22,4 +22,8 @@ QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
QMAKE_LINK = $${CROSS_COMPILE}g++
QMAKE_LINK_C = $${CROSS_COMPILE}gcc
QMAKE_CFLAGS_LTCG = -flto
QMAKE_CXXFLAGS_LTCG = $$QMAKE_CFLAGS_LTCG
QMAKE_LFLAGS_LTCG = $$QMAKE_CFLAGS_LTCG
load(qt_config)