1) Open Eclipse
Go to Applications in top left corner, then Programming, then Eclipse
2) It will ask you what you want your workspace to be. This is just where all your eclipse projects go. I would just take the default (a folder called "workspace" in your home directory).

3) Create new project
In Eclipse, go to File->New->Project
Somewhere along the way it will ask you if you want to switch to the "C/C++ perspective". Perspectives are just different UIs for different things. This one is for writing C/C++ (instead of Java). Go ahead and click yes.

4) In the dialog that comes up, select "C++ Project" and click "Next"

5) Under "Makefile project" select empty project and press "Finish"
6) Now, copy all of your files into the project. Do this by dragging them into the folder in eclipse...if this doesn't work then just copy the files into the project folder (ex: ~/workspace/part5/) and then right-click on the project in eclipse and press "Refresh"...all the files should now appear in the project

You can do some cool stuff like get autocomplete (control-spacebar) and see where something was declared (see picture below).

Also, at this point, your project should build fine with eclipse. Click the button shown below

You can then see eclipse will build your project in the console at the bottom

You will see errors in the "Problems" tab at the bottom. You can even click on them to go to the line where you have a syntax error!

The debugger can help you a lot. It's not just for finding bugs; it allows you to write code faster by giving you a good idea of what is going on.
We need to tell eclipse what program to debug (what program it should feed into gdb). If you try debugging without setting this up, you will see something like this:

Let's fix that:
1) Make sure you save and build your project.
2) Go to Run->Debug Configurations (sorry screenshots within menus aren't working in gnome :(
This is what will come up

3) Double-click on "C/C++ Application"
Here's where you need to understand why we are doing what we are doing so you can set this up for other projects...follow closely:

4) Now we need to link this with gdb. Go to the debugger tab and select "gdb debugger". The rest should just fill in automatically...

5) So at this point your program is going to be run through gdb with no parameters. Pretty much it will be just run as "minirel"...this will give an error like "Usage: minirel dbname" (just like running just "minirel" from the command line)
Let's run it with testdb (created by the running the tests or "dbcreate testdb"). Go to the "Arguments" tab as shown below. This is where you can put in the command-line arguments that the program should be run with...put in "testdb" so it will run "minirel testdb"

6) DEBUGGING TIME! Now you can click debug...it might ask you to save the configuration. Do that.
It might ask you if you want to switch to the "debugging perspective"...this just arranges the UI in a way more conducive to debugging. You might as well click the box so it always does this.

You can always get back to the C/C++ perspective easily

7) Damn it feels good to be a debugger...here's how you do it

Just to try it out...click the resume button (green arrow in previous picture or F8). The program will run until it hits a break point (there aren't any at this point so it will just run all the way through). Now there is minirel running below in the console...you can type commands in and run them.

Let's set a break point...open up create.C and click in the blue area next to one of the first few lines of RelCatalog::createRel...this will put a blue dot next to that line (a breakpoint)

Now when you type a create table command into minirel in the eclipse console it will break in that function as below
