Monday, October 8, 2012

Copying Qt project in Eclipse

Say you have a project in Qt that you want to use as starting point for a new project. Say that your environment is Eclipse. The fastest way I found to do this is:
  1. Create a new qt project: File->New->Project->Qt Console Project
  2. Go through the menus of the Wizard. Don't worry about it too much as we are going to delete it anyhow.
  3. Click Ok.
  4. The directory appears in the Workspace.
  5. Open it and delete the sources in there (.c, .h, .cpp...).
  6. Copy over the ones from your old project. 
  7. Fix the .pro so that it includes what needs to include. OR copy the old one over... They both should have the same inside.
  8. Click build
  9. It may ask you for the Launch Debug Configuration Selection, so, you pick MinGW gdb.
It should just work. You should be able to execute afterwards...

No comments:

Post a Comment