Presentation is loading. Please wait.

Presentation is loading. Please wait.

Developing C/C++ applications with the Eclipse CDT David Gallardo.

Similar presentations


Presentation on theme: "Developing C/C++ applications with the Eclipse CDT David Gallardo."— Presentation transcript:

1 Developing C/C++ applications with the Eclipse CDT David Gallardo

2 Getting started with CDT Requirements: –A version of the Eclipse Platform compatible with Eclipse CDT –The Eclipse CDT (Install via Update from: http://download.eclipse.org/tools/cdt/releases/new ) –CDT does not include a compiler! You need a separate C/C++ toolset including compiler, linker, make utility and standard libraries. –Linux includes these; in Windows, you’ll have to install Cygwin or MinGW.

3 Configure Eclipse Select debugger: – (GNU gdb) Select binary parser: – (Project Properties -> C/C++ Make Project -> Binary Parser Check only PE Windows Parser Enter build command: –Select Windows->Preferences->C/C++->Make->New Make Projects –Under Make Builder, in Build command section, uncheck the Use default box, and enter: mingw32- make –f makefile

4 Views in C/C++ perspective C/C++ Projects (the file navigator for C/C++ resources) Navigator (the file navigator for all Eclipse resources) Console Properties Tasks Make Targets Outline Search

5 Views in C/C++ Debug perspective Debug Variables Breakpoints Expressions Registers Memory Outline Console Tasks

6 C/C++ editor features Syntax highlighting Content assist is available for: –Fields, Variables –Methods,Functions –Classes, Structs,Unions –Namespaces –Enumerations –Code templates you can create and edit Debugger integration

7 Managed vs. standard make projects CDT offers two types of C and C++ projects: standard make and managed make Standard make projects allow you create and manage your own makefile. Pros and cons: –Flexible and powerful –Can be difficult to create and maintain In managed make projects, CDT creates and manages the makefile for you. Pros and cons: –Build is automatic—no need to deal with messy makefiles –Don’t have complete control over build process

8 Demo Create a C program—Hello, World!, of course! –Create C/C++ project (using standard make) –Create source file(s) –Create makefile Running a C program –Create Run configuration –Run Debug


Download ppt "Developing C/C++ applications with the Eclipse CDT David Gallardo."

Similar presentations


Ads by Google