Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
Developer
iravelo
Posts: 61
Registered: ‎06-28-2011
My Device: 9700+PB
My Carrier: sfr

Re: Cross compiling Qt in windows?

Tks Peter,
but I am very sorry I do not know what to do with those 4 files in http://www.kdab.com/~rafael/playbook/
I just wanted some precompiled arm qt binaries (=libraries) to "install" in my BB NDK so that I can use give them to some command line whenever I'm ready to package/sign/deploy my first Qt app for my playbook

I've tried to run configure on windows once I managed to git clone QT but I go in too many troubles due to tha fact that windows is not unix and configure does not know where are make, the compiler and so on...
SO SAd !

Tks
---------<={##}=>---------
I.Ravelo; Renault S.A.S. Corporate BBOS Java Apps Lead Conceptor/Coder; Qt learner
Please use plain text.
Developer
peter9477
Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10
My Carrier: none

Re: Cross compiling Qt in windows?

I think what he had originally was a nice .tgz which you could install anywhere. These are some sort of Linux binaries, perhaps merely extracting to the same thing, but obviously not much use on Windows.

I'll see if I can get something built for Wednesday and post it for you.

Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!
Please use plain text.
Developer
peter9477
Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10
My Carrier: none

Re: Cross compiling Qt in windows?

Okay, I built a fresh package from yesterday's latest in the Qt 4.8 branch, including up to changeset c6bda755a2d0cad93520dbd75dc2880a1c9409e2 . Also includes a Symbian build of the Qt Components package up to changeset c53f14bc52a64b09235af2f23b6e6de5ca1b3043.

 

Download from http://microcode.ca/downloads/qt4.8-stage-playbook.tgz (39MB).

 

This is an ARM build, so would work only for running on the target device and not for the simulator.  Last time I tried I wasn't able to build the x86 version for the simulator for some reason.

 

It's a single .tgz file (Gzip-compress tar file) which unpacks below a single folder named armv7le/.

 

With this in place (anywhere you want really) you should be able to follow the instructions in BGMot's post which I linked earlier (http://supportforums.blackberry.com/t5/Native-SDK-for-BlackBerry-Tablet/Cross-compiling-Qt-in-window...

 

Technically I haven't run this particular version yet so if they broke something it may not work.  Also may not work if I screwed something up but it's a straight rebuild same as I did a few days earlier and that worked fine for a basic Hello World using QML.

 

No guarantees how long I leave this up.  Others appear to be working towards automated (nightly?) builds so as soon as this is obsolete I'll post a link here to something else and take it down. Might be a few weeks yet.  I won't build nightly, but if someone's tracking the change history of the project and becomes aware of significant fixes/improvements, just add a note here and I can post an updated build.


Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!
Please use plain text.
Developer
iravelo
Posts: 61
Registered: ‎06-28-2011
My Device: 9700+PB
My Carrier: sfr

Re: Cross compiling Qt in windows?

great , Peter !
thanks a lot, your binaries have been expanded in a dedicated path, next to my QT sdk.
Now, I think I have to find out how to qmake , make , package then deploy to device my helloworld project.
I hope this will help...
http://wiki.qt-project.org/QNX#A_Hello_World_using_the_NDK_CLI_tools
will keep you all informed soon...

---------<={##}=>---------
I.Ravelo; Renault S.A.S. Corporate BBOS Java Apps Lead Conceptor/Coder; Qt learner
Please use plain text.
Developer
peter9477
Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10
My Carrier: none

Re: Cross compiling Qt in windows?

I've actually been using Momentics so far, so once I had those binaries and the headers on my Windows machine, I didn't have to deal with any of the qmake/make stuff. BGmot's post shows how to configure the IDE with the right settings, and it's pretty painless.

Of course, with the right "recipe", using makefiles can be pretty painless too, but at least at the start I find the IDE lets me focus a bit more on just experimenting with the code, and I can easily enough switch to command line later. (I usually go "commando" for production development anyway...)

Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!
Please use plain text.
Developer
peter9477
Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10
My Carrier: none

Re: Cross compiling Qt in windows?

By the way, there may be some compatibility issues to sort out here. Someone in the #qt-qnx IRC chat was having trouble using jheron's Qt Components build (or something... my memory is poor) and it turned out to be because he (jheron?) had targetted "g++" while the libraries had been built "qcc", or maybe it was that the NDK was qcc.  Either way, we couldn't use the g++ build.

Mine is using qcc, in case it matters.  That is, my ./configure line was as follows:

./configure -opensource -confirm-license -qpa -shared -xplatform unsupported/blackberry-armv7le-qcc -arch arm -opengl es2 -little-endian -largefile -nomake examples -xmlpatterns -webkit -no-neon -no-rpath -prefix-install -prefix /qt/install/armv7le


The relevant part is the unsupported/blackberry-armv7le-qcc, which could also end with g++ instead.  This whole thing is outside my area of expertise so I can only report these things but don't know what the implications are or whether it really matters.

 

(I've just tried an x86 build, but I used "-opengl es2" instead of "es1".  That built, but with "es1" I get an error during configuration that "The OpenGL ES 1.x functionality test failed!" and can't run make.)

 

Note that I've added another download at http://microcode.ca/downloads/qt4.8-stage-playbook-armv7le-qcc.tgz so it can be distinguished from an x86 build, and from a possible g++ version once I understand more about that.


Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!
Please use plain text.
Developer
peter9477
Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10
My Carrier: none

Re: Cross compiling Qt in windows?

Okay, I think we've figured out the g++ vs qcc issue.

BGmot (and jheron?) were using the BlackBerry github version of Qt. I've been following the progress on #qt-qnx, however, where @roquetto from KDAB (whom RIM has involved in the port to PlayBook) had told us they'd merged their changes upstream into the main Qt project, and we could just use the 4.8 branch from now on (if I got the story correct).

When using BlackBerry's, you'll have a mkspec/unsupported/blackberry-armv7le-g++, but when using the main Qt github you'll have a blackberry-armv7le-qcc instead.

Perhaps none of this matters. I don't quite know the effect, but I suspect it may simply be the case that if you build Qt-Components with one of those, and Qt itself with the other, the two won't play nicely together.

My .tgz has both together, built with/for the qcc platform, so maybe that's all that matters... i.e. be consistent.

Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!
Please use plain text.
Developer
BGmot
Posts: 1,068
Registered: ‎11-24-2011
My Device: PlayBook
My Carrier: x

Re: Cross compiling Qt in windows?

MS Windows users, try using these instrucions http://bgmotey.blogspot.com/2012/03/qthelloworld-in-momentics-ide-for-ms.html

 

Please use plain text.
Developer
jheron
Posts: 188
Registered: ‎01-27-2012
My Device: playbook
My Carrier: ...

Re: Cross compiling Qt in windows?

[ Edited ]

Nice job Peter! and BGmot!

Yes, I have been using the bb port from github. To build them I just hacked the configure script that came with the components to point to my github bb Qt port's qmake.

I attached the configure script I used, just open the script and look for the first comment , adjust the path so it points to your Qt ports qmake. Then copy it over the configure script in your fresh set of symbian components.

Then just run the script to build the components for the playbook.

I should note that I have done this on linux.

By the way azazello is working on a set of Playbook style components! http://supportforums.blackberry.com/t5/Native-SDK-for-BlackBerry-Tablet/QML-symbian-qt-components-fo...

 

Cheers,

Jon

Please use plain text.
Developer
peter9477
Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10
My Carrier: none

Re: Cross compiling Qt in windows?

Okay, I was trying to do an x86 build of the Qt 4.8 branch (not BlackBerry github) as that's the more recent one. The ./configure line wasn't working with "-opengl es1", and the simulator apparently doesn't have OpenGL ES2 on it yet. As it turns out, however (according to @narnaud from KDAB), the OpenGL support hasn't been tested (and, presumably, wouldn't really work) so there's no point worrying about it.

Therefore an x86 build with "-opengl es2", which does build fully, should be sufficient for now. I'm building one now (the "qcc") version and will post it when ready, for anyone who wants to test on the sim.

Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!
Please use plain text.