Build Instructions
To build QtD, you need:
- dmd compiler version >= 2.053
- Qt 4 (development headers for all Qt packages)
- cmake >= 2.6
Build procedure:
hg clone https://bitbucket.org/qtd/repo qtd cd qtd mkdir build_dir cd build_dir cmake ../ make sudo make install
If you want to build a 32 bit version of QtD, simply add -m32 to the CMAKE_CXX_FLAGS:
cmake ../ -DCMAKE_CXX_FLAGS=-m32
Ignore any warnings from the generator.
Congratulations - You have built and installed QtD!
You can try this "Hello World" example with QtD to verify that it works.
module main; import qt.gui.QApplication; import qt.gui.QPushButton; int main(string[] args) { scope app = new QApplication(args); scope hello = new QPushButton("Hello World!"); hello.show(); return app.exec(); }
You can compile it with (assuming you haven't changed the install path):
dmd main.d -I/usr/local/include/d -L-L/usr/local/lib -L-lqtdgui -L-lqtdcore -L-lcpp_core -L-lcpp_gui -L-lQtGui -L-lQtCore ./main
Attachments
- helloworld.png (5.4 kB) - added by mwarning on 03/23/10 21:55:47.