[Development] Missing ARM, MIPS, other mkspecs in qt5

Thiago Macieira thiago.macieira at intel.com
Wed Nov 30 08:31:08 CET 2011


On Wednesday, 30 de November de 2011 15.47.00, Rohan McGovern wrote:
> Hello,
> 
> In Qt5, we no longer appear to have any mkspecs for cross-compiling for
> ARM or MIPS.  They were tied up with qws, so they were removed when
> qws was removed.
> 
> Is it intentional that we still don't have any, or has it just fallen
> out that way and we're free to add some generic ARM, MIPS mkspecs for
> testing purposes?

mkspecs for cross-compilation are ill-suited, because the compiler name 
changes a lot. A better solution would be to make those configure-time options 
and simply use the standard mkspec for the platform.

I guess that until such time as a proper build system is in place for Qt, 
we'll have to make do though. I have attached the two qmake.conf I use to 
cross-compile for ARM and for MIPS. The qplatformdefs.h files are the same for 
both:

#include "../linux-g++/qplatformdefs.h"

-- 
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center
     Intel Sweden AB - Registration Number: 556189-6027
     Knarrarnäsgatan 15, 164 40 Kista, Stockholm, Sweden
-------------- next part --------------
include(../linux-g++/qmake.conf)

QMAKE_COMPILER_DEFINES += QT_ENABLE_CXX0X

QMAKE_CC = armv7hl-meego-linux-gnueabi-gcc
QMAKE_LINK_C = armv7hl-meego-linux-gnueabi-gcc
QMAKE_LNK_C_SHLIB = armv7hl-meego-linux-gnueabi-gcc

QMAKE_CFLAGS += -march=armv7-a -mfpu=neon -Wno-psabi
QMAKE_CFLAGS_RELEASE   = -O3 -g

QMAKE_CXX = armv7hl-meego-linux-gnueabi-g++
QMAKE_LINK = armv7hl-meego-linux-gnueabi-g++
QMAKE_LINK_SHLIB = armv7hl-meego-linux-gnueabi-g++

QMAKE_CXXFLAGS        += $$QMAKE_CFLAGS -std=c++0x
QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE

QMAKE_LFLAGS     += $$QMAKE_CXXFLAGS -Wl,--as-needed
QMAKE_LFLAGS_RELEASE += $$QMAKE_CXXFLAGS_RELEASE

QMAKE_AR = armv7hl-meego-linux-gnueabi-ar cqs
QMAKE_OBJCOPY = armv7hl-meego-linux-gnueabi-objcopy
QMAKE_RANLIB = armv7hl-meego-linux-gnueabi-ranlib
-------------- next part --------------
include(../linux-g++/qmake.conf)

QMAKE_COMPILER_DEFINES += QT_ENABLE_CXX0X

QMAKE_CC = mips-poky-linux-gcc
QMAKE_LINK_C = mips-poky-linux-gcc
QMAKE_LNK_C_SHLIB = mips-poky-linux-gcc

QMAKE_CFLAGS += -march=mips32 -mhard-float
QMAKE_CFLAGS_RELEASE   = -O3 -g

QMAKE_CXX = mips-poky-linux-g++
QMAKE_LINK = mips-poky-linux-g++
QMAKE_LINK_SHLIB = mips-poky-linux-g++

QMAKE_CXXFLAGS        += $$QMAKE_CFLAGS -std=c++0x
QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE

QMAKE_LFLAGS     += -Wl,--as-needed

QMAKE_AR = mips-poky-linux-ar cqs
QMAKE_OBJCOPY = mips-poky-linux-objcopy
QMAKE_RANLIB = mips-poky-linux-ranlib
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.qt-project.org/pipermail/development/attachments/20111129/2542a95b/attachment.sig>


More information about the Development mailing list