I have a big problem with Qt libraries cross-compilation. My objective is to develop some Qt-apps for my BeagleBoard-xM on my host machine running Ubuntu 12.04 LTS. I found some nice tutorials, e.g.:
but the toolchain, which Trey used (angstrom-2010.4-test-20100422-i686-linux-armv7a-linux-gnueabi-toolchain-qte-4.6.2), it just disappeared, so I tried some toolchains from Ubuntu repository (gcc-arm-linux-gnueabi, gcc-arm-linux-gnueabihf). And now, when I run ‘configure’ (with all parameters from Trey’s tutorial) and then try to run ‘make’, it breaks with this error:
/usr/lib/gcc/arm-linux-gnueabi/4.6/../../../../arm-linux-gnueabi/lib/../lib/crt1.o: In function_start’:
(.text+0x30): undefined reference to `main’
collect2: ld returned 1 exit status
make[1]: *** […/…/lib/libQtCoreE.so.4.8.5] Error 1
`
I found somewhere, that it might be some linking issue, but I have completely no idea, what to do with that…
Maybe someone has similar problem and could give me some advice?
Yes, I have edited ‘qmake.conf’ file just like Trey described in his tutorial. Everything looks correct for me, but maybe you will find some mistake… Here is my current version of ‘qmake.conf’:
qmake configuration for building with arm-linux-g++
#Compiler Flags to take advantage of the ARM architecture
QMAKE_CFLAGS_RELEASE = -O3 -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp
QMAKE_CXXFLAGS_RELEASE = -O3 -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp
And now something new about arm-linux-gnueabihf toolchain - when I’m using it, I get some extra errors:
/usr/lib/gcc/arm-linux-gnueabihf/4.6/../../../../arm-linux-gnueabihf/lib/../lib/crt1.o: In function_start’:
(.text+0x30): undefined reference to main' .obj/release-shared-emb-arm/qtconcurrentiteratekernel.o: In function QtConcurrent::BlockSizeManager::timeBeforeUser()’:
qtconcurrentiteratekernel.cpp:(.text+0x14a): undefined reference to clock_gettime' .obj/release-shared-emb-arm/qtconcurrentiteratekernel.o: In function QtConcurrent::BlockSizeManager::timeAfterUser()’:
qtconcurrentiteratekernel.cpp:(.text+0x260): undefined reference to `clock_gettime’
collect2: ld returned 1 exit status
make[1]: *** […/…/lib/libQtCoreE.so.4.8.5] Error 1
`
Any ideas…?
Is there anyone here who has succesful compiled Qt-libs with OTHER ARM-linux-toolchain than angstrom-linux-toolchain…?
Or maybe someone has got 32-bit angstrom-linux-toolchain (for Qt) and can just send me it?
Thank you very much, Tux! I downloaded your files and so far compilation runs quite well, no errors at the moment Thank you once more for your help, I hope that I will be finally able to make something more on my Beagle
It looks like my problem was this part of ‘qmake.conf’:
#Compiler Flags to take advantage of the ARM architecture
QMAKE_CFLAGS_RELEASE = -O3 -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp
QMAKE_CXXFLAGS_RELEASE = -O3 -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp
because only when I’ve deleted these statements from it, the ‘make’ command started to work well. I see, that there are some floating point unit parameters (‘neon’, ‘mfloat-abi’), so it may be the reason that FPU (thus some graphic apps too) will be much slower… Am I right?