Setting up QT 5

Hi All,

I decided to install Haiku and dive in QT programming, because I believe that software makes the platform and QT is a very decent cross platform widget set that makes porting software easier. My question will probably also so spook the mind of other aspiring Haiku devs.

I downloaded QT 5 from HaikuDepot, installed 5.6 ( 5.8 is out) but when I compiled the samples the fun started :slight_smile: The shell didn’t know how to compile the examples. (I am running the gcc2 build and distribution of Haiku OS).

The compiler couldn find the QT libraries. So I included the Qt header directory after the compiler (g++ sample.cpp -I /boot/…) but was rewarded by an even larger list of errors the system couldn’t find.

Is there some documentation somewhere that describes how to set up the QT development environment and what parameters I should set for the compiler to work?

Thanks and have a nice day.

1 Like

Hello! If you are compiling from the Terminal, you must switch to gcc5 using:

setarch x86

After this, you can use the qmake normally.

I hope this could be useful.
Good luck! :smiley:

2 Likes

Cool and thanks!
I discovered that I needed to run qmake on the .pro file. That generated a makefile, that compiled and delivered my application.

2 Likes