Unsolved Cross compiling QT 5.6 on ARM, how to use g++ instead of ld for linking?
-
Hi there,
I am trying to compile QT for an arm board which I have on my desk. After I got some help while trying to configure 5.11 here, I noticed that the compiler I am able to use seems to have problems while using C++11:
Note: Also available for Linux: linux-clang linux-icc Note: Dropped compiler flags '-pthread' when detecting library 'glib'. Note: No wayland-egl support detected. Cross-toolkit compatibility disabled. WARNING: Python version 2 (2.7.5 or later) is required to build QtWebEngine. WARNING: gperf is required to build QtWebEngine. ERROR: C++11 <random> is required and is missing or failed to compile. ERROR: detected a std::atomic implementation that fails for function pointers. Please apply the patch corresponding to your Standard Library vendor, found in qtbase/config.tests/atomicfptr Check config.log for details.
So I decided to give 5.6 a try:
I use the following configure command:../configure -opensource -confirm-license -release -no-gui -device arm-gad-linux-gnueabi-g++ -device-option CROSS_COMPILE=/home/johndoe/opt/gad/R9.0/sysroots/x86_64-gadsdk-linux/usr/bin/arm-gad-linux-gnueabi/arm-gad-linux-gnueabi- -sysroot /home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi -prefix /home/johndoe/usr/local/qt5
I copied the mkspec for
linux-imx6-g++
to a new directoryarm-gad-linux-gnueabi-g++
and adjusted the config:include(../common/linux_device_pre.conf) QMAKE_LIBS_EGL += -lEGL QMAKE_LIBS_OPENGL_ES2 += -lGLESv2 -lEGL -lGAL QMAKE_LIBS_OPENVG += -lOpenVG -lEGL -lGAL IMX6_CFLAGS = -march=armv7-a -mfpu=neon -DLINUX=1 -DEGL_API_FB=1 QMAKE_CFLAGS += $$IMX6_CFLAGS QMAKE_CXXFLAGS += $$IMX6_CFLAGS DISTRO_OPTS += hard-float # Preferred eglfs backend EGLFS_DEVICE_INTEGRATION = eglfs_viv include(../common/linux_arm_device_post.conf) load(qt_config)
The configuring seems to be successful:
johndoe@8084885492c9:~/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build$ ./build.sh + cd qtbase + /home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/qtbase/configure -top-level -opensource -confirm-license -release -no-gui -device arm-gad-linux-gnueabi-g++ -device-option CROSS_COMPILE=/home/johndoe/opt/gad/R9.0/sysroots/x86_64-gadsdk-linux/usr/bin/arm-gad-linux-gnueabi/arm-gad-linux-gnueabi- -sysroot /home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi -prefix /home/johndoe/usr/local/qt5 This is the Qt Open Source Edition. You are licensed to use this software under the terms of the GNU Lesser General Public License (LGPL) version 2.1. You are also licensed to use this software under the terms of the GNU Lesser General Public License (LGPL) version 3. You have already accepted the terms of the Open Source license. Preparing build tree... Running configuration tests (phase 1)... Done running configuration tests. Creating qmake... .........................................................................................Done. Running configuration tests (phase 2)... Note: PKG_CONFIG_LIBDIR automatically set to /home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi/usr/lib/pkgconfig:/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi/usr/share/pkgconfig:/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi/usr/lib/arm-gad-linux-gnueabi/pkgconfig checking for C++11... yes. checking for C++14... no. checking for default C++ standard edition... yes. checking for 64-bit std::atomic... yes. checking for sse2... no. checking for ipc_sysv... yes. checking for zlib... yes. checking for mtdev... no. checking for libjpeg... no. checking for libpng... no. checking for dlopen... no. checking for libdl... yes. checking for DB2... no. checking for InterBase... no. checking for MySQL (thread-safe)... no. checking for MySQL (thread-unsafe)... no. checking for OCI... no. checking for ODBC... no. checking for iODBC... no. checking for PostgreSQL... no. checking for SQLite2... no. checking for TDS... no. checking for Cups... no. checking for POSIX iconv... yes. checking for D-Bus... yes. checking for libproxy... no. checking for Glib... yes. checking for ICU... no. checking for PulseAudio... no. checking for OpenGL... no. checking for OpenGL ES 2.0... no. checking for FontConfig... no. checking for libudev... yes. checking for evdev... yes. checking for tslib... no. checking for xkbcommon... no. checking for libinput... no. checking for XLib... no. checking for Xrender... no. checking for XInput2... no. checking for xcb... no. checking for GBM... no. checking for LinuxFB... yes. checking for KMS... no. checking for Mir client... no. checking for EGL... no. checking for FreeType... no. checking for STL... yes. checking for POSIX clock_gettime()... yes. checking for POSIX Monotonic Clock... yes. checking for posix_fallocate... yes. checking for mremap... yes. checking for getaddrinfo... yes. checking for inotify... yes. checking for eventfd... yes. checking for IPv6 interface name... yes. checking for getifaddrs... yes. checking for cloexec... yes. checking for OpenSSL... yes. checking for PCRE... no. checking for OpenVG... no. checking for OpenVG... no. checking for OpenVG (lc includes)... no. checking for OpenVG (lc includes)... no. checking for alsa... no. checking for GStreamer 1.0... no. checking for GStreamer 0.10... no. Done running configuration tests. Configure summary Building on: linux-g++ (x86_64, CPU features: mmx sse sse2) Building for: devices/arm-gad-linux-gnueabi-g++ (arm, CPU features: neon) Platform notes: - Also available for Linux: linux-clang linux-kcc linux-icc linux-cxx Build options: Configuration .......... accessibility audio-backend c++11 clock-gettime clock-monotonic compile_examples concurrent cross_compile dbus dbus-linked evdev eventfd freetype full-config getaddrinfo getifaddrs glib harfbuzz iconv inotify ipv6ifname large-config largefile libudev linuxfb medium-config minimal-config mremap neon no-gui no-widgets openssl pcre png posix_fallocate precompile_header qpa qpa reduce_exports release rpath shared small-config system-zlib threadsafe-cloexec Build parts ............ libs examples Mode ................... release Using sanitizer(s)...... none Using C++ standard ..... c++11 Using gold linker....... no Using new DTAGS ........ no Using PCH .............. yes Using LTCG ............. no Target compiler supports: Neon ................. yes Qt modules and options: Qt D-Bus ............... yes (linked to dbus-1) Qt Concurrent .......... yes Qt GUI ................. no Qt Widgets ............. no Large File ............. yes QML debugging .......... yes Use system proxies ..... no Support enabled for: Accessibility .......... yes ALSA ................... no CUPS ................... no Evdev .................. yes FontConfig ............. no FreeType ............... yes (bundled copy) Glib ................... yes GStreamer .............. no GTK theme .............. no HarfBuzz ............... yes (bundled copy) Iconv .................. yes ICU .................... no Image formats: GIF .................. yes (plugin, using bundled copy) JPEG ................. yes (plugin, using bundled copy) PNG .................. yes (in QtGui, using bundled copy) libinput................ no Logging backends: journald ............... no syslog ............... no mtdev .................. no Networking: getaddrinfo .......... yes getifaddrs ........... yes IPv6 ifname .......... yes libproxy.............. no OpenSSL .............. yes (loading libraries at run-time) OpenGL / OpenVG: EGL .................. no OpenGL ............... no OpenVG ............... no PCRE ................... yes (bundled copy) pkg-config ............. yes PulseAudio ............. no QPA backends: DirectFB ............. no EGLFS ................ no EGLFS i.MX6 ........ no EGLFS i.MX6 Wayland. no EGLFS EGLDevice .... no EGLFS GBM .......... no EGLFS Mali ......... no EGLFS Raspberry Pi . no EGLFS X11 .......... no LinuxFB .............. yes Mir client............ no XCB .................. no Session management ..... yes SQL drivers: DB2 .................. no InterBase ............ no MySQL ................ no OCI .................. no ODBC ................. no PostgreSQL ........... no SQLite 2 ............. no SQLite ............... yes (plugin, using bundled copy) TDS .................. no tslib .................. no udev ................... yes xkbcommon-x11........... no xkbcommon-evdev......... no zlib ................... yes (system library) NOTE: Qt is using double for qreal on this system. This is binary incompatible against Qt 5.1. Configure with '-qreal float' to create a build that is binary compatible with 5.1. Qt is now configured for building. Just run 'make'. Once everything is built, you must run 'make install'. Qt will be installed into /home/johndoe/usr/local/qt5 Prior to reconfiguration, make sure you remove any leftovers from the previous build.
When I now try to
make
, I run into errors when the linker kicks in:cd qtbase/ && ( test -e Makefile || /home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase/bin/qmake /home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/qtbase/qtbase.pro -o Makefile ) && make -f Makefile make[1]: Entering directory '/home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase' cd src/ && ( test -e Makefile || /home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase/bin/qmake /home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/qtbase/src/src.pro -o Makefile ) && make -f Makefile make[2]: Entering directory '/home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase/src' cd corelib/ && ( test -e Makefile.qtzlib || /home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase/bin/qmake /home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/qtbase/src/corelib/qtzlib.pro -o Makefile.qtzlib ) && make -f Makefile.qtzlib make[3]: Entering directory '/home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase/src/corelib' make[3]: Nothing to be done for 'first'. make[3]: Leaving directory '/home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase/src/corelib' cd tools/bootstrap/ && ( test -e Makefile || /home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase/bin/qmake /home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/qtbase/src/tools/bootstrap/bootstrap.pro -o Makefile ) && make -f Makefile make[3]: Entering directory '/home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase/src/tools/bootstrap' make[3]: Nothing to be done for 'first'. make[3]: Leaving directory '/home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase/src/tools/bootstrap' cd tools/moc/ && ( test -e Makefile || /home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase/bin/qmake /home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/qtbase/src/tools/moc/moc.pro -o Makefile ) && make -f Makefile make[3]: Entering directory '/home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase/src/tools/moc' arm-gad-linux-gnueabi-ld --sysroot=/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -Wl,--gc-sections -Wl,-O1 -o ../../../bin/moc .obj/moc.o .obj/preprocessor.o .obj/generator.o .obj/parser.o .obj/token.o .obj/main.o -L/home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase/lib -lQt5Bootstrap -lpthread arm-gad-linux-gnueabi-ld: unrecognized option '-Wl,-O1' arm-gad-linux-gnueabi-ld: use the --help option for usage information Makefile:124: recipe for target '../../../bin/moc' failed make[3]: *** [../../../bin/moc] Error 1 make[3]: Leaving directory '/home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase/src/tools/moc' Makefile:108: recipe for target 'sub-moc-make_first' failed make[2]: *** [sub-moc-make_first] Error 2 make[2]: Leaving directory '/home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase/src' Makefile:46: recipe for target 'sub-src-make_first' failed make[1]: *** [sub-src-make_first] Error 2 make[1]: Leaving directory '/home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build/qtbase' Makefile:72: recipe for target 'module-qtbase-make_first' failed make: *** [module-qtbase-make_first] Error 2
I think, this might be an issue because
arm-gad-linux-gnueabi-ld
is tried to use for linking. When using make with a plain makefile, my toolchain seems to usearm-gad-linux-gnueabi-g++
for linking:johndoe@8084885492c9:~/opt/resources/demobuild$ cat Makefile && make INC = -c -Wall -Werror -std=c++11 -O2 \ $(shell pkg-config --cflags dbus-c++-shiny-1 glib-2.0 actia-platform-1) LDLIBS = $(shell pkg-config --libs dbus-c++-shiny-1 glib-2.0 ) -lboost_system -lpthread #-L/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi/usr/lib/ -lboost_system -lpthread TARGET = server .PHONY: all all: main.o $(CXX) $^ -o $(TARGET) $(LDFLAGS) $(LDLIBS) %.o: %.cpp $(CXX) $(CFLAGS) $(INC) $< -o $@ .PHONY: clean clean: rm -f *.o $(TARGET) arm-gad-linux-gnueabi-g++ -march=armv7-a -mthumb-interwork -mfloat-abi=hard -mfpu=neon -mtune=cortex-a9 --sysroot=/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi -O2 -pipe -g -feliminate-unused-debug-types -c -Wall -Werror -std=c++11 -O2 -DDBUS_API_SUBJECT_TO_CHANGE -I/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi/usr/include/dbus-c++-shiny-1 -I/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi/usr/include/dbus-1.0 -I/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi/usr/lib/dbus-1.0/include -I/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi/usr/include/glib-2.0 -I/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi/usr/lib/glib-2.0/include -I/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi/usr/include/actia-1 main.cpp -o main.o arm-gad-linux-gnueabi-g++ -march=armv7-a -mthumb-interwork -mfloat-abi=hard -mfpu=neon -mtune=cortex-a9 --sysroot=/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi main.o -o server -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -ldbus-c++-shiny-1 -ldbus-1 -lglib-2.0 -lboost_system -lpthread
I use a docker container as a build environment where I usually compile my c++ code using plain old makefiles.
The environment looks like this:
johndoe@e655ff6124da:~/opt/resources/qt-5.11/qt-everywhere-src-5.11.0/build$ env AS=arm-gad-linux-gnueabi-as OECORE_TARGET_SYSROOT=/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi AR=arm-gad-linux-gnueabi-ar LDFLAGS=-Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed TARGET_PREFIX=arm-gad-linux-gnueabi- HOSTNAME=e655ff6124da M4=m4 TERM=xterm NM=arm-gad-linux-gnueabi-nm CPPFLAGS= OECORE_DISTRO_VERSION=1.0.0 GDB=arm-gad-linux-gnueabi-gdb OECORE_SDK_VERSION=1.0.0 LS_COLORS=rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.Z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.jpg=01;35:*.jpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36: PKG_CONFIG_SYSROOT_DIR=/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi CONFIG_SITE=/home/johndoe/opt/gad/R9.0/site-config-cortexa9hf-vfp-neon-gad-linux-gnueabi CXXFLAGS= -O2 -pipe -g -feliminate-unused-debug-types CPP=arm-gad-linux-gnueabi-gcc -E -march=armv7-a -mthumb-interwork -mfloat-abi=hard -mfpu=neon -mtune=cortex-a9 --sysroot=/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi PATH=/home/johndoe/opt/gad/R9.0/sysroots/x86_64-gadsdk-linux/usr/bin:/home/johndoe/opt/gad/R9.0/sysroots/x86_64-gadsdk-linux/usr/bin/arm-gad-linux-gnueabi:/home/johndoe/opt/python-virtual/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin LD=arm-gad-linux-gnueabi-ld --sysroot=/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi PWD=/home/johndoe/opt/resources/qt-5.11/qt-everywhere-src-5.11.0/build STRIP=arm-gad-linux-gnueabi-strip LANG=C.UTF-8 OECORE_NATIVE_SYSROOT=/home/johndoe/opt/gad/R9.0/sysroots/x86_64-gadsdk-linux PYTHONHOME=/home/johndoe/opt/gad/R9.0/sysroots/x86_64-gadsdk-linux/usr CONFIGURE_FLAGS=--target=arm-gad-linux-gnueabi --host=arm-gad-linux-gnueabi --build=x86_64-linux --with-libtool-sysroot=/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi CXX=arm-gad-linux-gnueabi-g++ -march=armv7-a -mthumb-interwork -mfloat-abi=hard -mfpu=neon -mtune=cortex-a9 --sysroot=/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi OBJCOPY=arm-gad-linux-gnueabi-objcopy HOME=/home/johndoe SHLVL=2 CFLAGS= -O2 -pipe -g -feliminate-unused-debug-types DEBIAN_FRONTEND=noninteractive OECORE_ACLOCAL_OPTS=-I /home/johndoe/opt/gad/R9.0/sysroots/x86_64-gadsdk-linux/usr/share/aclocal PKG_CONFIG_PATH=/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi/usr/lib/pkgconfig RANLIB=arm-gad-linux-gnueabi-ranlib ARCH=arm CC=arm-gad-linux-gnueabi-gcc -march=armv7-a -mthumb-interwork -mfloat-abi=hard -mfpu=neon -mtune=cortex-a9 --sysroot=/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi CROSS_COMPILE=arm-gad-linux-gnueabi- OBJDUMP=arm-gad-linux-gnueabi-objdump SDKTARGETSYSROOT=/home/johndoe/opt/gad/R9.0/sysroots/cortexa9hf-vfp-neon-gad-linux-gnueabi _=/usr/bin/env OLDPWD=/home/johndoe/opt/resources/qt-5.11/qt-everywhere-src-5.11.0
Can I somehow get the build process to use
g++
instead ofld
?Thanks in advance
Jochen
-
Hi,
No, the compiler and the linker are two different beasts.
What version of GCC are you using ?
-
Here are my verions on the build system:
johndoe@8084885492c9:~/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build$ arm-gad-linux-gnueabi-g++ --version arm-gad-linux-gnueabi-g++ (GCC) 4.8.2 Copyright (C) 2013 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. johndoe@8084885492c9:~/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build$ arm-gad-linux-gnueabi-gcc --version arm-gad-linux-gnueabi-gcc (GCC) 4.8.2 Copyright (C) 2013 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. johndoe@8084885492c9:~/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build$ arm-gad-linux-gnueabi-ld --version GNU ld (GNU Binutils) 2.24 Copyright 2013 Free Software Foundation, Inc. This program is free software; you may redistribute it under the terms of the GNU General Public License version 3 or (at your option) a later version. This program has absolutely no warranty. johndoe@8084885492c9:~/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/build$
When I use
make LINK=arm-gad-linux-gnueabi-g++
instead of onlymake
, the linking seems to succeed for a numerous count of object files. But it still complains about missing libs. Maybe some flags are not yet right.But I first want to find out whether passing
$LINK
while making is a suitable approach or not. If so, I would create a separate question for the not found libs while linking.Thanks
Jochen
-
Just for the sake of testing you can remove the linker options
'-Wl,-O1'
from your mkspec.-Wl
states that whats follow must be pasted to the linker. -
Could you give me a hint how to do this, based on the evironment I already have (see the above
env
output)?As soon as I add any
QMAKE_LFLAGS
-Entry in theqmake.conf
, I get this from configure:checking for STL... no. STL functionality check failed! Cannot build Qt with this STL library. Turn on verbose messaging (-v) to /home/johndoe/opt/resources/qt-5.6/qt-everywhere-opensource-src-5.6.3/qtbase/configure to see the final report.
I tried via
QMAKE_LFLAGS -= -Wl,-O1
but to no avail, the flags are still there. -
IIRC, it's specific to the release LFLAGS.
-
I can't get it to work at all. I tried about a thousand hints and tricks regarding flags, mkspecs that I found in forums elsewhere. I tried older QT versions, with and with c++11 support, without sourcing my environment or with sourcing it, but all to no avail.
I think I will give up for now. Since the device supplier is not interested to help us with their knowledge and they seem to be not interested to provide support for QT at all, we might try to find someone who we can pay to figure out a working mkspec for that specific device.
Thanks for the help so far.