[Development] One qmake and cross compilation for different targets

Tomasz Olszak olszak.tomasz at gmail.com
Fri Aug 23 11:40:55 CEST 2013


2013/8/23 Oswald Buddenhagen <oswald.buddenhagen at digia.com>

> On Thu, Aug 22, 2013 at 08:39:15PM +0000, Tomasz Olszak wrote:
> > Let's Suppose that we have 2 different targets (ARM,MIPS) and we want
> > develop on Windows, Mac and linux 64/32 bit. If I am provider of Qt cross
> > compiled binaries for ARM and MIPS then in the end I can't provide
> complete
> > development toolchain because I don't know which host OS will be used for
> > crosscompilation. So either I will cross compile Qt NxM (where N number
> of
> > hosts, M number of targets) times or suggest developers to built Qt on
> > their own.
> >
> > Is there a way to extract data from Qt libraries (ARM, MIPS) and build
> > corresponding host's qmake, moc etc. for these targets?
> >
> the blackberries asked me the same question a few days ago ...
>
If it was on ML, I didn't spot it then - sorry.

> unfortunately there is no clean way to avoid the NxM compilations; the
> qmake instance is too tightly coupled to the qt build (it's also the
> actual "identifier" of a particular qt as far as qtcreator is
> concerned).
> you can try some trickery to avoid the redundancy behind the scenes:
> - compile all builds for one target with the same -prefix but different
>   -hostprefix'es
> - hard-link the binaries in the -hostbindir's for the same host systems
>   but different -prefixes. note: you must put a qt.conf in each
>   -hostbindir to override qmake's built-in idea of which qt build it
>   belongs to.
> so it's mostly an installation/packaging challenge. you can do many of
> the actual compilations selectively per directory once you have figured
> out which targets you need.
>
I don't know if I put things clearly. I don't know qmake. moc, rcc
internals but I do know that they are tightly dependent on Qt version. How
hard could it be to:
1. Prepare some metadata+mksecs with Qt targets binaries maybe in some dev
tools package. (maybe this metadata is only qtbase/configure internal args,
output of tests and so on)
2. prepare qmake, moc, rcc source packages.
3. Build host dev tools for crosscompilation from these src qmake, moc and
rcc packages and metadata. I would like to pass only hostrefix,
crosscompiler and sysroot path for configure. Rest info will be taken from
mentioned metadata. This process can be automated with QtCreator plugin.

Is it possible? If yes how hard is that?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/development/attachments/20130823/b68a9ae2/attachment.html>


More information about the Development mailing list