Hi Donald,
thank you for your help.
I installed LTIB and now I am trying to build Qt5.
The problem is, that the linker can't find some libraries. I was able to
find some of the headers manually. These are the headers that the linker
couldn't find:
missing header
location found on hd
tiffio.h
/home/qt5/qtbase/src/3rdparty/libtiff
libmng.h
/home/qt5/qtbase/src/3rdparty/libmng
sqlcli.h
-
sqlcli1.h
-
ibase.h
/home/qt5/qtbase/include/QtSql
oci.h
/home/qt5/qtbase/include/QtSql
sql.h
/home/qt5/qtbase/include/QtSql
sqlext.h
-
libpq-fe.h
-
sqlite.h
/home/qt5/qtbase/include/QtSql
sybfront.h
-
sybdb.h
-
unicode/utypes.h
/usr/include/unicode
unicode/ucol.h
/usr/include/unicode
unicode/ustring.h
/usr/include/unicode
pulse/pulseaudio.h
-
pulse/glib-mainloop.h
-
I guess the qmake.conf needs to be modified. Qmake_lflags could be the
solution.
The qmake.conf should include some of the locations.
Additionaly the arm-none-linux-gnueabi-g++ compiler does not recognize the
following arguments:
-mmx
-m3dnow
-msse
-msse2
-msse3
-mssse3
-msse4.1
-msse4.2
-mavx
-lxcb
Does anyone know how to include the correct paths into the qmake.conf?
Thanks
Dietrich
Von: Donald Carr <***@gmail.com>
An: ***@continental-corporation.com
Kopie: ***@nokia.com, qt5-***@qt.nokia.com
Datum: 02.12.2011 03:14
Betreff: Re: [Qt5-feedback] Antwort: RE: Antwort: [RMX:#] RE:
Building Qt5 for embedded Linux ARM - compilerproblems
Hey Dietrich,
I use the same arm compilers across a range of targets. Code Sourcery
2010q1 is fantastic and is my defacto compiler for random boards since it
rarely objects to sysroots. I would not imagine any issues using it on the
IMX53
Dietrich: The (Freescale) LTIP build process involves building stuff using
a toolchain, feel free to drop that toolchain into a mkspec if you want.
Daniel: Thanks for fielding questions :)
I have built Qt 5 for:
Raspberry PI
Tegra 2
Beagle board
n9
all of which are ARM based.
Yours sincerely,
Donald
On Thu, Dec 1, 2011 at 9:45 AM, <***@nokia.com> wrote:
Correct, there is only a linux-rasp-pi-g++ mkspec, and this is what Donald
was referring to in his blog post, the mkspec covers more than just the
compiler.
Cheers,
Daniel
From: ext ***@continental-corporation.com [mailto:
***@continental-corporation.com]
Sent: Thursday, December 01, 2011 6:13 PM
To: Molkentin Daniel (Nokia-MP-Qt/Berlin)
Cc: qt5-***@qt.nokia.com
Subject: Antwort: RE: Antwort: [RMX:#] RE: [Qt5-feedback] Building Qt5 for
embedded Linux ARM - compilerproblems
Hi,
I cloned the qt-platform-mkspecs directory, but it didn't include any
linux-arm-gnueabi-g++ folder.
I tried to do it on my own, but I am facing some problems. The libraries
aren't found.
Thats how my qmake.conf looks like:
#
# qmake configuration for building with arm-none-linux-gnueabi-g++
#
MAKEFILE_GENERATOR = UNIX
TARGET_PLATFORM = unix
TEMPLATE = app
CONFIG += qt warn_on release incremental link_prl
gdb_dwarf_index
QT += core gui
QMAKE_INCREMENTAL_STYLE = sublib
include(../../common/linux.conf)
include(../../common/gcc-base-unix.conf)
include(../../common/g++-unix.conf)
#REQS_PREFIX=/stores/broadcom/raspberry-pi/rootfs
GCC_PREFIX=/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi
#PLT reloc type error
#/opt/toolchains/arm-2011.03-41-arm-none-linux-gnueabi/bin/arm-none-linux-gnueabi
# modifications to g++.conf
QMAKE_CC = $${GCC_PREFIX}-gcc
#crt1 + host of symlinks absent in rootfs, introduce if using sysroot
#--sysroot=$${REQS_PREFIX}
QMAKE_CXX = $${GCC_PREFIX}-g++
QMAKE_LINK = $${QMAKE_CXX}
QMAKE_LINK_SHLIB = $${QMAKE_CXX}
# modifications to linux.conf
QMAKE_AR = $${GCC_PREFIX}-ar cqs
QMAKE_OBJCOPY = $${GCC_PREFIX}-objcopy
QMAKE_STRIP = $${GCC_PREFIX}-strip
#INCLUDEPATH += $${REQS_PREFIX}/opt/vc/include/header-pollution
$${REQS_PREFIX}/opt/vc/include $#${REQS_PREFIX}/usr/include
#promiscuous linking is pretty poor form; correct the relevant .pro file
#for correctness (required for webkit)
#LIBS += -L$${REQS_PREFIX}/usr/lib -lsqlite3
#circular dependency EGL <=> GLES2
QMAKE_LIBS_EGL= -lGLESv2 -lEGL
QMAKE_LIBS_OPENGL_ES2=$${QMAKE_LIBS_EGL}
QMAKE_LIBS_OPENVG=$${QMAKE_LIBS_EGL}
#This is an initial set of compiler flags yet to be validated: YMMV
QMAKE_CFLAGS_RELEASE = \
-march=armv7 \
#This is now breaking: Invalid instruction in libQtV8
# -mfloat-abi=softfp \
-mfpu=vfp \
-fomit-frame-pointer \
-Wall \
-O2
QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
#DEFINES += USE_EABI_HARDFLOAT=0
load(qt_config)
And that's the errors I recieved.
mx auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -mmmx -g
-Wall -W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o mmx.o
mmx.cpp
cc1plus: error: unrecognized command line option "-mmmx"
make: *** [mmx.o] Error 1
mmx disabled.
3dnow auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -m3dnow -g
-Wall -W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o 3dnow.o
3dnow.cpp
cc1plus: error: unrecognized command line option "-m3dnow"
make: *** [3dnow.o] Error 1
3dnow disabled.
sse auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -msse -g
-Wall -W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o sse.o
sse.cpp
cc1plus: error: unrecognized command line option "-msse"
make: *** [sse.o] Error 1
sse disabled.
sse2 auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -msse2 -g
-Wall -W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o sse2.o
sse2.cpp
cc1plus: error: unrecognized command line option "-msse2"
make: *** [sse2.o] Error 1
sse2 disabled.
sse3 auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -msse3 -g
-Wall -W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o sse3.o
sse3.cpp
cc1plus: error: unrecognized command line option "-msse3"
make: *** [sse3.o] Error 1
sse3 disabled.
ssse3 auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -mssse3 -g
-Wall -W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o ssse3.o
ssse3.cpp
cc1plus: error: unrecognized command line option "-mssse3"
make: *** [ssse3.o] Error 1
ssse3 disabled.
sse4_1 auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -msse4.1
-g -Wall -W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o sse4_1.o
sse4_1.cpp
cc1plus: error: unrecognized command line option "-msse4.1"
make: *** [sse4_1.o] Error 1
sse4_1 disabled.
sse4_2 auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -msse4.2
-g -Wall -W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o sse4_2.o
sse4_2.cpp
cc1plus: error: unrecognized command line option "-msse4.2"
make: *** [sse4_2.o] Error 1
sse4_2 disabled.
avx auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -mavx -g
-Wall -W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o avx.o
avx.cpp
cc1plus: error: unrecognized command line option "-mavx"
make: *** [avx.o] Error 1
avx disabled.
zlib auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o zlib.o zlib.cpp
zlib.cpp:42:18: fatal error: zlib.h: No such file or directory
compilation terminated.
make: *** [zlib.o] Error 1
zlib disabled.
libjpeg auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o libjpeg.o
libjpeg.cpp
libjpeg.cpp:45:21: fatal error: jpeglib.h: No such file or directory
compilation terminated.
make: *** [libjpeg.o] Error 1
libjpeg disabled.
libtiff auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o libtiff.o
libtiff.cpp
libtiff.cpp:42:20: fatal error: tiffio.h: No such file or directory
compilation terminated.
make: *** [libtiff.o] Error 1
libtiff disabled.
libmng auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o libmng.o
libmng.cpp
libmng.cpp:42:20: fatal error: libmng.h: No such file or directory
compilation terminated.
make: *** [libmng.o] Error 1
libmng disabled.
libpng auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o libpng.o
libpng.cpp
libpng.cpp:42:17: fatal error: png.h: No such file or directory
compilation terminated.
make: *** [libpng.o] Error 1
libpng disabled.
DB2 auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o db2.o db2.cpp
db2.cpp:42:20: fatal error: sqlcli.h: No such file or directory
compilation terminated.
make: *** [db2.o] Error 1
DB2 disabled.
InterBase auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o ibase.o ibase.cpp
ibase.cpp:42:19: fatal error: ibase.h: No such file or directory
compilation terminated.
make: *** [ibase.o] Error 1
InterBase disabled.
MySQL (thread-safe) auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -I/usr/include/mysql
-o mysql.o ../mysql/mysql.cpp
cc1plus: warning: include location "/usr/include/mysql" is unsafe for
cross-compilation
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++
-Wl,-rpath,/home/lucid/qt5/qtbase/lib -o mysql_r mysql.o
-L/usr/lib/mysql -lmysqlclient_r
/home/lucid/armgnulinux/bin/../lib/gcc/arm-none-linux-gnueabi/4.5.2/../../../../arm-none-linux-gnueabi/bin/ld:
warning: library search path "/usr/lib/mysql" is unsafe for
cross-compilation
/home/lucid/armgnulinux/bin/../lib/gcc/arm-none-linux-gnueabi/4.5.2/../../../../arm-none-linux-gnueabi/bin/ld:
cannot find -lmysqlclient_r
collect2: ld returned 1 exit status
make: *** [mysql_r] Error 1
MySQL (thread-safe) disabled.
MySQL (thread-unsafe) auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -I/usr/include/mysql
-o mysql.o mysql.cpp
cc1plus: warning: include location "/usr/include/mysql" is unsafe for
cross-compilation
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++
-Wl,-rpath,/home/lucid/qt5/qtbase/lib -o mysql mysql.o
-L/usr/lib/mysql -lmysqlclient
/home/lucid/armgnulinux/bin/../lib/gcc/arm-none-linux-gnueabi/4.5.2/../../../../arm-none-linux-gnueabi/bin/ld:
warning: library search path "/usr/lib/mysql" is unsafe for
cross-compilation
/home/lucid/armgnulinux/bin/../lib/gcc/arm-none-linux-gnueabi/4.5.2/../../../../arm-none-linux-gnueabi/bin/ld:
cannot find -lmysqlclient
collect2: ld returned 1 exit status
make: *** [mysql] Error 1
MySQL (thread-unsafe) disabled.
OCI auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o oci.o oci.cpp
oci.cpp:42:17: fatal error: oci.h: No such file or directory
compilation terminated.
make: *** [oci.o] Error 1
OCI disabled.
ODBC auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o odbc.o odbc.cpp
odbc.cpp:45:17: fatal error: sql.h: No such file or directory
compilation terminated.
make: *** [odbc.o] Error 1
ODBC disabled.
iODBC auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o iodbc.o iodbc.cpp
iodbc.cpp:42:17: fatal error: sql.h: No such file or directory
compilation terminated.
make: *** [iodbc.o] Error 1
iODBC disabled.
PostgreSQL auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o psql.o psql.cpp
psql.cpp:42:22: fatal error: libpq-fe.h: No such file or directory
compilation terminated.
make: *** [psql.o] Error 1
PostgreSQL disabled.
SQLite2 auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o sqlite2.o
sqlite2.cpp
sqlite2.cpp:42:20: fatal error: sqlite.h: No such file or directory
compilation terminated.
make: *** [sqlite2.o] Error 1
SQLite2 disabled.
unknown SQL driver: sqlite_symbian
TDS auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o tds.o tds.cpp
tds.cpp:42:22: fatal error: sybfront.h: No such file or directory
compilation terminated.
make: *** [tds.o] Error 1
TDS disabled.
NIS auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o nis.o nis.cpp
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++
-Wl,-rpath,/home/lucid/qt5/qtbase/lib -o nis nis.o -lnsl
{ test -z "" || cd ""; } && test $(gdb --version | sed -e
's,[^0-9]\+\([0-9]\)\.\([0-9]\).*,\1\2,;q') -gt 72 && gdb --nx --batch
--quiet -ex 'set confirm off' -ex 'save gdb-index .' -ex quit 'nis' &&
test -f nis.gdb-index &&
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-objcopy --add-section
'.gdb_index=nis.gdb-index' --set-section-flags '.gdb_index=readonly' 'nis'
'nis' && rm -f nis.gdb-index || true
NIS enabled.
D-Bus auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o dbus.o dbus.cpp
dbus.cpp:43:23: fatal error: dbus/dbus.h: No such file or directory
compilation terminated.
make: *** [dbus.o] Error 1
D-Bus disabled.
Glib auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o glib.o glib.cpp
glib.cpp:44:18: fatal error: glib.h: No such file or directory
compilation terminated.
make: *** [glib.o] Error 1
Glib disabled.
ICU auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o icu.o icu.cpp
icu.cpp:42:28: fatal error: unicode/utypes.h: No such file or directory
compilation terminated.
make: *** [icu.o] Error 1
ICU disabled.
PulseAudio auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -o pulseaudio.o
pulseaudio.cpp
pulseaudio.cpp:42:30: fatal error: pulse/pulseaudio.h: No such file or
directory
compilation terminated.
make: *** [pulseaudio.o] Error 1
PulseAudio disabled.
OpenGL ES 2.x auto-detection... ()
/home/lucid/armgnulinux/bin/arm-none-linux-gnueabi-g++ -c -pipe -g -Wall
-W -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -I/usr/X11R6/include
-o opengles2.o opengles2.cpp
opengles2.cpp:45:25: fatal error: GLES2/gl2.h: No such file or directory
compilation terminated.
make: *** [opengles2.o] Error 1
OpenGL ES 2.x disabled.
The OpenGL ES 2.0 functionality test failed!
You might need to modify the include and library search paths by editing
QMAKE_INCDIR_OPENGL_ES2, QMAKE_LIBDIR_OPENGL_ES2 and
QMAKE_LIBS_OPENGL_ES2 in
/home/lucid/qt5/qtbase/mkspecs/qws/linux-arm-gnueabi-g++.
Any ideas?
Von: <***@nokia.com>
An: <***@continental-corporation.com>, <
qt5-***@qt.nokia.com>
Datum: 01.12.2011 16:51
Betreff: RE: Antwort: [RMX:#] RE: [Qt5-feedback] Building Qt5 for
embedded Linux ARM - compilerproblems
Please reply-to-list so everyone can answer. Short answer (and the only I
can give): make sure the cross-tool-chain is in the path and that you are
using the right mkspec (from https://gitorious.org/qt-platform-mkspecs)
and link it into the mkspec dir of Qt5 as mentioned in the blog post.
Cheers,
Daniel
From: ext ***@continental-corporation.com [
mailto:***@continental-corporation.com]
Sent: Thursday, December 01, 2011 4:38 PM
To: Molkentin Daniel (Nokia-MP-Qt/Berlin)
Subject: Antwort: [RMX:#] RE: [Qt5-feedback] Building Qt5 for embedded
Linux ARM - compilerproblems
I downloaded and installed the compiler. Now I am facing the problem, that
the compiler is not found by the Qt5 configure command. I need to modify
the mkspecs folder. Do you know how to do that?
Thank you for your help.
Dietrich
Von: <***@nokia.com>
An: <***@continental-corporation.com>, <
qt5-***@qt.nokia.com>
Datum: 01.12.2011 15:29
Betreff: [RMX:#] RE: [Qt5-feedback] Building Qt5 for embedded Linux
ARM - compilerproblems
The post mentions âI am using the Code Sourcery 2010q1 compiler.â
So my guess would be that the toolchain used has been downloaded from
here: https://sourcery.mentor.com/sgpp/lite/arm/portal/release1294
Cheers,
Daniel
From: qt5-feedback-bounces+daniel.molkentin=***@qt.nokia.com [
mailto:qt5-feedback-bounces+daniel.molkentin=***@qt.nokia.com] On
Behalf Of ext ***@continental-corporation.com
Sent: Thursday, December 01, 2011 2:25 PM
To: qt5-***@qt.nokia.com
Subject: [Qt5-feedback] Building Qt5 for embedded Linux ARM - compiler
problems
Hi,
I read this⊠[labs.qt.nokia.com] labs post, but I couldnât figure out how
build Qt5 for ARM with embedded linux. My main problem is that I donât
know which compiler to use. I am using the i.MX53 Quickstart Board from
Freescale. Qt5 is already running on my Ubuntu 10.04, but I would like to
set up a Qt5 environment that allows my to cross compile for this ARM
board.
Thatâs how my configure looks like:
./configure -opensource -arch arm -xplatform ??????? -release -opengl es2
-little-endian -nomake docs -no-svg -no-audio-backend -no-multimedia
-no-xmlpatterns -no-v8 -no-location -no-declarative -no-cups -xcb
-no-wayland -no-phonon -no-qt3support -no-webkit -no-javascript-jit
-no-neon -confirm-license -verbose -qpa -no-gtkstyle
I read already this thread: Qt5 on linux arm â xcb platform plugin not
working [developer.qt.nokia.com]
but I donât know where exactly and how he got the linux-g++-mx5x compiler.
As far as I understand there are actually to possible compiler that are
available for cross compiling for ARM.
1. arm-none-linux-gnueabi-gcc
2. arm-linux-gcc
But I don't know how to install and use them for my configure command.
Did anyone already succeed in building Qt5 for any ARM chip?
Thanks a lot.
Dietrich
_______________________________________________
Qt5-feedback mailing list
Qt5-***@qt.nokia.com
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback
--
-------------------------------
°v° Donald Carr
/(_)\ Professional Penguin lover
^ ^
Cave canem, te necet lingendo