News:

When registered with our forums, feel free to send a "here I am" post here to differ human beings from SPAM bots.

Main Menu

New User - Importing Files to form project

Started by Sidhartha, February 14, 2012, 09:45:56 PM

Previous topic - Next topic

Sidhartha

Hi All,

I'm now to codeblocks... traditionally I've used EMACS and the terminal debugger... but it's time to move on!!!

Question... I have small C++ "project" (not a true project in CodeBlocks terms). About 4 .cpp files with associated headers, a main.cpp a makefile and a dictionary file that the c++ project reads (literally a dictionary text file).

My question... how do I get this into Codeblocks so that it complies & runs correctly. I realise I can start an empty project and import the files.
Do I also have to import the makefile & dictionary file? I'm not entirely clear how I run a project from an existing makefile.

A few pointers in the right direction would be appreciated!

Many Thanks

Alpha

It is possible to use (almost) any build system "unconverted" (see Code::Blocks and Makefiles), however, it is generally better to fully transfer the build, allowing Code::Blocks to manage it (especially when the project is small, and therefor relatively easy to convert).

(Working under the assumption your project does not use any external libraries.)  Use the wizard to create an empty console project.  Click Project->Add files... and select all of your *.cpp and *.h files.  I would also suggest adding the dictionary text file simply for ease of access.  Leave the makefile out (or even delete if you plan to never go back :)), unless you have decided not to fully convert.

See also: