Print

Image

Setting Up An Application With QtCreator - Linux


Introduction

This set of instructions will walk you through setting up a QtCreator C++ project from scratch.

When you have finished this tutorial you will be able to compile a working Ogre Application and you will be ready to start the Basic Tutorials.

Prerequisites

Follow the instruction at Building Your Projects With CMake to setup a CMake project.
Do not generate the project using the CMake GUI - you don't need to as QtCreator will handle the rest.

Setting up an Ogre project in QtCreator

Open project

QtCreator - File - Open File or Project:
Image

Choose build location

Image

Run CMake

Image

Make in console

You need to find the qtcreator-build directory and run this in a console:

make && make install

The reason is that it's a bit involved to set up an INSTALL build configuration in QtCreator, and it only needs to be done once.

Setup executable for project run

Now, click the green arrow in the sidebar to build and run the project.
Since we haven't set up any run configuration, we are prompted to do that in the following dialogue:
Image
Choose build_directory/dist/bin/OgreApp as executable and build_directory/dist/bin as working directory.

Rejoice

Image

Conclusion

As you can see, it's rather easy to setup a project in QtCreator if you use a CMake script.
QtCreator doesn't touch your source directory, except one file: CMakeLists.txt.user.


Contributors to this page: jacmoe177744 points  .
Page last modified on Saturday 01 of January, 2011 16:57:19 UTC by jacmoe177744 points .


The content on this page is licensed under the terms of the Creative Commons Attribution-ShareAlike License.
As an exception, any source code contributed within the content is released into the Public Domain.