Start Eclipse and create a Sourcery G++ Lite project by selecting C++ label and select Managed Make C++ Project. (To build a C application, expand the C label instead.) Click the button. Give the project the name "hello" and click the button. From the menu select "Executable (Sourcery G++ Lite for ARM SymbianOS)" and click . If you are asked whether or not to open a new perspective, click the button.
from the submenu of the menu. Expand the
Next, select hello.cc
and click
. Paste the following code into
the file:
Example 5.1. Hello, World (C++)
#include <iostream> int main () { std::cout << "Hello, world!" << std::endl; }
As soon as you save the file, Eclipse will build the program. The
executable itself will be located in a subdirectory of the Eclipse
workspace directory named hello
. Of
course, the executable will run on the target system, so if you are
targeting an embedded system, you will have to upload the
executable to the target system before running the application.