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
BGmot
Posts: 1,068
Registered: ‎11-24-2011
My Device: PlayBook
My Carrier: x

Re: Cross compiling Qt in windows?

Hey Peter,

you might wish to take a look at this patch https://github.com/BGmot/Qt/commit/66d4c3b5de2a813715287dd5b5d703694c58c452

I did not have much luck with Qt on Simulator until I fixed this file.

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 put my x86 build up as well, for the simulator users. This was built with "-opengl es2", which is both untested and apparently won't work on the simulator anyway, so don't try using OpenGL stuff...

 

Link for now is microcode.ca/downloads/qt4.8-stage-playbook-x86-qcc.tgz

 


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
jheron
Posts: 188
Registered: ‎01-27-2012
My Device: playbook
My Carrier: ...

Re: Cross compiling Qt in windows?

Peter, When you said "@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)." 

What does that mean? Does that mean the port is merged with the main Nokia Qt 4.8 and will be updated in the Qt SDK and that the port from github is no longer needed? Or am I misunderstanding?

I am shocked there is still an active community using IRC chats, especially for something as new as the playbook... Brings back memories of the old sat hacking days... :smileywink: Too bad we miss all the chats here..

BGmot, Are you having better luck with the emulator with your patches applied? Is it worth using it? My past experience was that its useless....

It would sure be nice to be able to use the simulator in the Qt SDK, its very fast and is great for debugging. I know its customizable to do whatever we need, just need to find the time... :smileywink:

Cheers,

Jon

 

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?

Hi Jon,

I use NDK+Blackberry SImulator as I don't have my own device (just periodically get access to my friend's Playbook to test stuff) so I have to use Simulator and it works pretty nice if you don't try to use 'non-Qt' stuff like hide/show virtual keyboard or react to user's hide/show virtual keyboard (that works on real device).

I strongly recommend to develop directly on Playbook (to those who have it).

I am also curious what actually KDAB is doing... did they bring what we have at github into http://qt.gitorious.org on Feb 28th, or there are changes? It's becoming confusing - what to use: github or qt.gitorious... -(((

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?

jheron (and BGmot), based solely on a few messages in #qt-qnx, my understanding is that they have merged into the main Qt 4.8 and -- my assumption only -- the BB Qt github is currently out of date with respect to that.

I'm not a regular Git user, so I may be reading this wrong, but what I see on the BB github tells me there have been no changes there since Feb 3, and the one before that was Jan 12.

Meanwhile, at http://qt.gitorious.org/qt/qt/commits/4.8 it appears there are ongoing changes right up to this morning.

Yes, I found it a bit surprising too that IRC was still alive, but then I was never really an IRC user in past. (I pretty much pre-date IRC by a long way. :-) )

The general #playbook-dev channel is quite active, and there are several secondary channels including #webworks-dev and now #qt-qnx. There's no particular organization, and the selection of channels will likely remain in flux until things settle out with Cascades and the whole BB10 platform, at which point I would expect enough stability that we'll have a better picture what works best.

IRC is clearly better for fast interactions than this forum, but has obvious disadvantages as well. I just use both to try to maximize the value of each...

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?

Playbook is my hobby -) so I work and my work is not related to devlopment, I can't spend much time in IRC. Forums are better to me as I can read them several times a day (and being notified if somebody answers my post). Qt situation is weird, 'they' ask for contributions, society is ready to contribute and has thing to contribute but there is no coordination whatsoever. I'd better shut up before slipping into critisizing RIM for luck of communication.

Please use plain text.
Developer
soaman
Posts: 848
Registered: ‎03-03-2011
My Device: Z10

Re: Cross compiling Qt in windows?

Can somebody tell me how to setup properties in IDE so I wouldn't get compiler errors with Peter's files for ARM?

 

Subdirectories are different.

 

Another question: If I want to use XML parser, do I have to add any additional library?

 

TNX

 

BR SOAman

--------------------------------------------------------------------------------------
Leader of Ljubljana BlackBerry Developer Group
BlackBerry Certified Builder for Native Application Development
Please use plain text.
Developer
soaman
Posts: 848
Registered: ‎03-03-2011
My Device: Z10

Re: Cross compiling Qt in windows?

I extracted files into C:\BB_DEV\Native.

 

I added the following assets:

C:/BB_DEV/Native/armv7le/plugins/platforms/libblackberry.so 

C:/BB_DEV/Native/armv7le/lib/libQtCore.so.4.8.1

C:/BB_DEV/Native/armv7le/lib/libQtGui.so.4.8.1

C:/BB_DEV/Native/armv7le/lib/libQtOpenGL.so.4.8.1

 

Modified source:

<assetpath="C:/BB_DEV/Native/armv7le/plugins/platforms/libblackberry.so"type="Qnx/Elf">lib/platforms/libblackberry.so</asset>

 

Added QCC complier preprocessor:

"C:\BB_DEV\Native\armv7le\include\Qt"

"C:\BB_DEV\Native\armv7le\include\QtCore"

"C:\BB_DEV\Native\armv7le\include\QtGui"

"C:\BB_DEV\Native\armv7le\include\QtOpenGL"

${QNX_TARGET}/usr/include/freetype2

${QNX_TARGET}/../target-override/usr/include

 

+ QT_BOOTSTRAPPED

 

Added in QCC linker Libraries:

"C:\BB_DEV\Native\armv7le\lib"

 

And Libraries:

QtCore

QtGui

QtOpenGL

 

Build result:

'app' was not declared in this scope main.cpp /Shiny/src line 16 C/C++ Problem

'clicked' was not declared in this scope main.cpp /Shiny/src line 16 C/C++ Problem

'QApplication' was not declared in this scope main.cpp /Shiny/src line 9 C/C++ Problem

'QCoreApplication' has not been declared main.cpp /Shiny/src line 7 C/C++ Problem

'QObject' has not been declared main.cpp /Shiny/src line 16 C/C++ Problem

'QPushButton' was not declared in this scope main.cpp /Shiny/src line 14 C/C++ Problem

'quit' was not declared in this scope main.cpp /Shiny/src line 15 C/C++ Problem

'QWidget' was not declared in this scope main.cpp /Shiny/src line 11 C/C++ Problem

'SIGNAL' was not declared in this scope main.cpp /Shiny/src line 16 C/C++ Problem

'SLOT' was not declared in this scope main.cpp /Shiny/src line 16 C/C++ Problem

window' was not declared in this scope main.cpp /Shiny/src line 12 C/C++ Problem

expected ';' before 'app' main.cpp /Shiny/src line 9 C/C++ Problem

expected ';' before 'quit' main.cpp /Shiny/src line 14 C/C++ Problem

expected ';' before 'window' main.cpp /Shiny/src line 11 C/C++ Problem

QApplication: No such file or directory main.cpp /Shiny/src line 1 C/C++ Problem

QPushButton: No such file or directory main.cpp /Shiny/src line 2 C/C++ Problem

QWidget: No such file or directory main.cpp /Shiny/src line 3 C/C++ Problem

 

Now I am stucked :-(

--------------------------------------------------------------------------------------
Leader of Ljubljana BlackBerry Developer Group
BlackBerry Certified Builder for Native Application Development
Please use plain text.
Developer
soaman
Posts: 848
Registered: ‎03-03-2011
My Device: Z10

Re: Cross compiling Qt in windows?

Build project removed previous errors.

But now I get:

'QT_BEGIN_HEADER' does not name a type Shiny line 62, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qapplication.h C/C++ Problem

expected initializer before ':' token Shiny line 97, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qapplication.h C/C++ Problem

QtCore/qcoreapplication.h: No such file or directory Shiny line 45, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qapplication.h C/C++ Problem

QtCore/qmargins.h: No such file or directory Shiny line 47, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qwidget.h C/C++ Problem

QtCore/qobject.h: No such file or directory Shiny line 46, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qwidget.h C/C++ Problem

QtCore/qpoint.h: No such file or directory Shiny line 47, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qapplication.h C/C++ Problem

QtCore/qsize.h: No such file or directory Shiny line 48, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qapplication.h C/C++ Problem

QtGui/qabstractbutton.h: No such file or directory Shiny line 45, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qpushbutton.h C/C++ Problem

QtGui/qbrush.h: No such file or directory Shiny line 55, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qwidget.h C/C++ Problem

QtGui/qcursor.h: No such file or directory Shiny line 49, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qapplication.h C/C++ Problem

QtGui/qfont.h: No such file or directory Shiny line 50, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qwidget.h C/C++ Problem

QtGui/qfontinfo.h: No such file or directory Shiny line 52, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qwidget.h C/C++ Problem

QtGui/qfontmetrics.h: No such file or directory Shiny line 51, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qwidget.h C/C++ Problem

QtGui/qkeysequence.h: No such file or directory Shiny line 57, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qwidget.h C/C++ Problem

QtGui/qpaintdevice.h: No such file or directory Shiny line 48, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qwidget.h C/C++ Problem

QtGui/qpalette.h: No such file or directory Shiny line 49, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qwidget.h C/C++ Problem

QtGui/qregion.h: No such file or directory Shiny line 54, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qwidget.h C/C++ Problem

QtGui/qsizepolicy.h: No such file or directory Shiny line 53, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qwidget.h C/C++ Problem

QtGui/qwindowdefs.h: No such file or directory Shiny line 46, external location: C:\BB_DEV\Native\armv7le\include\QtGui\qapplication.h C/C++ Problem

--------------------------------------------------------------------------------------
Leader of Ljubljana BlackBerry Developer Group
BlackBerry Certified Builder for Native Application Development
Please use plain text.
Developer
soaman
Posts: 848
Registered: ‎03-03-2011
My Device: Z10

Re: Cross compiling Qt in windows?

Added QCC complier preprocessor:

"C:\BB_DEV\Native\armv7le\include\"

 

Now it compiles!!!

--------------------------------------------------------------------------------------
Leader of Ljubljana BlackBerry Developer Group
BlackBerry Certified Builder for Native Application Development
Please use plain text.