diff --git a/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_build_over.htm b/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_build_over.htm index 3eaa132ac11..59040616644 100644 --- a/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_build_over.htm +++ b/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_build_over.htm @@ -60,19 +60,25 @@ the Make Targets view.

For more information about the Tasks view, see Workbench User Guide > Reference > User interface information > Views and editors > Tasks view.

+

Getting a makefile

You can either create a C/C++ project for which you supply the makefile or create a C/C++ project for which the CDT generates makefiles automatically.

To create a new project, from the menu bar choose File > New -> Project. In the dialog that appears:

+> Project. In the dialog that appears, expand the C/C++ group +and choose e.g. C Project

Setting build preferences

You can set build preferences in Eclipse:

@@ -81,42 +87,47 @@ project.
If certain projects must be built before others, you can set the build order. If your project refers to another project, the CDT must build the other project first. To set the build order, from the menu -bar select Window > Preferences > Build Order. +bar select Window > Preferences and choose General > Preferences > Build Order.

When you set the build order, the CDT does not rebuild projects that depend on a project; you must rebuild all projects to ensure all changes are propagated.

Automatic save
You can set the CDT to perform an automatic save of all -modified resources when you perform a manual build; from the menu bar, -select Windows > Preferences > Workbench. By default, -this feature is enabled.
+modified resources when you perform a manual build. In the preferences dialog, +select General > Workspace and check Save automatically before build. +By default, +this feature is not enabled. +

Controlling the building of your project

-

For a Standard Make project, the C/C++ compiler that a project uses +

For a Makefile project, the C/C++ compiler that a project uses is controlled by the project's Properties setting. To view a project's properties, right-click on the project and select Properties. -In the dialog that appears, the C/C++ Standard Make Project +In the dialog that appears, the C/C++ Build page enables you to control a variety of settings, including:

-
Build Setting
-
Controls whether the compiler will Stop On Error or Keep -Going On Error. Choosing Keep Going On Error will force the -compiler to attempt to build all referenced projects even if the -current project has errors.
-
Build Command
-
Controls which make is used.
-
Workbench Build Behavior
-
Controls which makefile target will be built depending on the -scope of the build.
+
Build Command
+
On the Builder Settings tab, this controls which make is used. To change it, uncheck Use + default build command and change it or add arguments to the make command.
+ +
Build Setting
+
On the Behaviour tab, this controls whether the compiler will Stop on first build error or not + (keep going). Unchecking Stop on first build error will force the compiler to attempt to build all referenced + projects even if the current project has errors.
+ +
Workbench Build Behavior
+
On the Behaviour tab, this controls which makefile target will be built depending on the scope of the + build, e.g. all or clean.
-

For a Managed Make project, the project properties dialog enables +

For a standard (non-Makefile) project (often called "Managed Build" or "Managed Make" project from +earlier CDT version), the project properties dialog enables you to manage the build configurations of your project. For additional information see:

Viewing build information

diff --git a/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_outlineview.htm b/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_outlineview.htm index d1de7520ea3..40dd24715b4 100644 --- a/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_outlineview.htm +++ b/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_outlineview.htm @@ -105,7 +105,7 @@ items:

Related tasks
Displaying C/C++ file components in the -C/C++ Projects view
+Project Explorer view
Searching for C/C++ elements

Related reference
diff --git a/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_over_cdt.htm b/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_over_cdt.htm index eece0ba9a2f..c5ebcfe76e3 100644 --- a/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_over_cdt.htm +++ b/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_over_cdt.htm @@ -41,10 +41,10 @@ views:

CDT updates

The Install/Update wizard provides information about your current Eclipse installation and provides the framework to manage your updates. -For more information, see Workbench User Guide > Tasks > Updating features with the update manager.

+For more information, see Workbench User Guide > Tasks > Updating and installing software.

To view a list of the updates available for the toolsets that you -installed, click Help > Software Updates > New Updates.

+installed, click Help > Check for Updates.

Additional information

@@ -60,13 +60,6 @@ Provides answers to the most common questions about using the CDT.
  • CDT Wiki: This is the main source for information around CDT.
  • - -
  • Developer -Documentation: Provides feature and design specifications for building and extending the CDT.
  • -
  • CDT -Community Webpage: Showcases plug-ins and tools developed by and for the CDT Community. -If you have tools or plug-ins that you would like to submit to the CDT Community Page, -use the CDT Development Mailing List or the Eclipse Tools CDT newsgroup.
  • diff --git a/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_perspectives.htm b/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_perspectives.htm index 07c126d8336..f832c54287f 100644 --- a/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_perspectives.htm +++ b/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_perspectives.htm @@ -16,6 +16,7 @@ Each type of perspective is a combination of views, menus, and toolbars that ena For example, the C/C++ perspective has views that are organized to help you develop C/C++ programs; the Debug perspective has views that enable you to debug those programs.

    +

    To Open the C/C++ Perspective, select Window > Open Perspective > Other... and select C/C++

    diff --git a/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_whatsnew.htm b/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_whatsnew.htm index d0d800887da..e75f2b0a226 100644 --- a/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_whatsnew.htm +++ b/doc/org.eclipse.cdt.doc.user/concepts/cdt_c_whatsnew.htm @@ -37,7 +37,9 @@ may contain other information.

    Rename in File

    - The rename refactoring now works interactively in the editor. + To make rename refactoring work interactively in the editor, + position the cursor on an identifier in the editor and hit Cntl-1 + (the hotfix key). Choose "Rename in file." Changing an identifier simultaneously changes all other references to that identifier.

    Rename in File @@ -173,21 +175,39 @@ may contain other information.

     

    + + + + +

    System Includes

    + + + +
      -
    • Heuristics to pick up otherwise unresolved include files from the project +
    • Heuristics to pick up otherwise unresolved include files from the project

      In older versions of CDT the user was forced to manually set up all include paths that were not discovered by the build system. Now CDT is capable of automatically finding any header file that is located within the project without manual setup. -

      (See Bug 213562) -

       

      +

      (See Bug 213562)

      +

       

    • -
    • Rework of template instantiation +
    + + + + +

    Indexer Accuracy

    + + +
      +
    • Rework of template instantiation

      There have been significant improvements to the CDT editor for supporting C++ templates. Content assist now works much better within code that makes heavy use of templates.

       

      -
    • -
    • There have been numerous improvements to the performance and accuracy of the CDT parser and indexer.
    • +
    • + There have been numerous improvements to the performance and accuracy of the CDT parser and indexer.
    @@ -236,7 +256,7 @@ may contain other information.
    • Updated Manage Working Set Configurations dialog for simpler workflows
    • Quick access to configurations via a property page for Working Sets - New working set configuration dialog +

      New working set configuration dialog

       

    • diff --git a/doc/org.eclipse.cdt.doc.user/concepts/cdt_o_home.htm b/doc/org.eclipse.cdt.doc.user/concepts/cdt_o_home.htm index 7e543130e32..8077d0031d6 100644 --- a/doc/org.eclipse.cdt.doc.user/concepts/cdt_o_home.htm +++ b/doc/org.eclipse.cdt.doc.user/concepts/cdt_o_home.htm @@ -10,7 +10,7 @@

      C/C++ Development User Guide

      -

      CDT 5.0

      +

      CDT 6.0

      The C/C++ Development Toolkit (CDT) is a collection of Eclipse-based features that provides the capability to create, edit, navigate, build, and debug projects that use C and/or C++ as a programming language.

      diff --git a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_o_tutorial.htm b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_o_tutorial.htm index baa4843d0df..d638f27996c 100644 --- a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_o_tutorial.htm +++ b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_o_tutorial.htm @@ -14,10 +14,11 @@ Prepare the Workbench
      -Create a new project
      - Create a simple application
      +Create a Makefile project
      + + Import an existing project
      Build a project
      diff --git a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_basic.htm b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_basic.htm index c5d157fcc98..fbfe781f6f8 100644 --- a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_basic.htm +++ b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_basic.htm @@ -15,12 +15,12 @@ function newWin(url) {

      In this tutorial, you will use the CDT to create a simple 'Hello World' application. This tutorial describes the process of creating a new C++ project where the build is -automatically managed by the CDT.

      +automatically managed by the CDT, and running the program.

      Note: In earlier versions of the CDT, there were two separate project types: Managed make (automatically generated a makefile) and Standard make (required the user's makefile to build). -With CDT 4.0, you now select a project type, and that determines what build system will be used.

      +Now with CDT, you now select a project type, and that determines what build system will be used.

      To create a simple "Hello World" application using the CDT, you will perform the following steps:

      @@ -30,7 +30,7 @@ With CDT 4.0, you now select a project type, and that determines what build syst

      Click here to see an illustration (displayed in a separate window).


    • Select the type of project to create. For this tutorial, expand the C++ folder and select C++ Project and click Next. - Click here to see an illustration.

      +

      Click here to see an illustration.


      The C++ Project wizard opens.

      Click here to see an illustration.


      By default, the CDT filters the Toolchain and Project types that it displays in those lists based on the language support for the C++ Project wizard you selected for this tutorial.

      diff --git a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_build.htm b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_build.htm index 9204b33195e..52431390379 100644 --- a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_build.htm +++ b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_build.htm @@ -5,23 +5,39 @@ Building your project +

      Building a project

      +

      The make output and build progress information displays in the Console view. The Make Targets view displays makefile actions, and the Tasks view displays compile warnings or errors.

      To build a project:

        -
      1. In the C/C++ Projects view, select your project. For the tutorial, you can to select the Hello World project you created earlier.


      2. -
      3. Click Project > Build Project.
      4. -

        If you see the error message:

        -
        -

        Exec error:Launching failed

        -
        +
      5. In the Project Explorer view, select your project. For the tutorial, you can select the HelloWorld project you created earlier.


      6. +
      7. Click Project > Build Project. +
        You can also hit the hammer icon on the toolbar. +
      8. +

        If you see an error message, such as:

        +

           (Cannot run program "make": Launching failed)

        then CDT cannot locate the build command, usually make. Either your path is not configured correctly, or you do not have make installed on your system.

        +
      9. You can see the output and results of the build command in the Console view. +Click on its tab to bring the view forward if it is not currently visible. +If for some reason it's not present, you can open it by selecting Window > Show View > Console. +


        +Click here to see an illustration (displayed in a separate window) +.

        + + + +

      Related concepts diff --git a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_debug.htm b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_debug.htm index 8584641ac21..fd94b958153 100644 --- a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_debug.htm +++ b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_debug.htm @@ -18,36 +18,55 @@ examining the contents of variables.

      To debug a project:

      1. Click Run > Debug Configurations....

        The Debug Configurations dialog opens.

      2. -
      3. Double-click C++ Application.
      4. +
      5. Double-click C/C++ Application.
      6. In the Name field, type Hello World.
      7. You can now select this debug launch configuration by name the next time that you debug this project.

        -
      8. In the Project box, type hello.exe. [???????]
      9. +
      10. In the Project box, type or choose your project, e.g. HelloWorld. +
        + Your executable should be selected under "C/C++ Application." +
        If not, the Search Project button should find the executable in the project. +

         

        +
      11. +
          +
        • If you see the error "[Debugger]: No debugger available", select the Debugger tab + and choose a valid debugger for your platform (e.g. gdb/mi). +
        • +
      12. Click Debug.
      13. You will be prompted to switch to the Debug Perspective. Click Yes

        You will now see the debug perspective with the hello.exe application window open. The C/C++ editor repositions in the perspective.

        +
          +
        • If you see an error in the editor "Can't find source file" you can use the buttons provided + to point to your source file, e.g. "Locate File." +
        • +
      14. In the left margin of the main.cpp window, double-click to set a breakpoint on:
        -  cout << "You just entered"
      15. -
      16. Click Run > Resume.
      17. -
      18. When prompted, type a value other than 'm'.
        +  cout << "You just entered" +
        You'll see an icon there indicating the breakpoint is set.
        +
      19. +
      20. Click Run > Resume. +
        Or, you can use the Resume button (green arrow) on the toolbar of the Debug View +
      21. +
      22. When prompted, in the Console view, type a value other than 'm', and hit Enter/Return.
        The breakpoint will be hit.
      23. -
      24. In the Variable view, verify that the variable is not 'm'.
      25. +
      26. In the Variables view, verify that the variable is not 'm'.
      27. Click Run > Resume.
      28. -
      29. When prompted, type a value other than 'm'.
      30. +
      31. When prompted, again type a value other than 'm' in the Console view, and press Enter/Return.
      32. The breakpoint will be hit.

        -
      33. In the Variable view, verify that the variable is not 'm'.
      34. -
      35. In the Variable view, right-click the input variable, and select Change - Variable Value and type 'm'.
      36. +
      37. In the Variables view, verify that the variable is not 'm'.
      38. +
      39. In the Variables view, right-click the input variable, and select Change Value... + and type 'm' between the single quotes and hit OK.
      40. Click Run > Resume.
      41. The output in the hello.exe application window is:
        - "You just entered m, you need to enter m to exit."

      42. Type 'm' to end the program.
        - The hello.exe application window closes and the debug session ends. The debug + "You just entered m, you need to enter m to exit." +
      43. The application terminates and the debug session ends. The debug perspective remains open.
      -

      To learn more about the debugging, see to the related debug conceptual topics.

      +

      To learn more about debugging, see the related debug conceptual topics.

      Back icon Back: Building a project   

      diff --git a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_import.htm b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_import.htm index 11d7b362a12..a0b3d43cb8d 100644 --- a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_import.htm +++ b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_import.htm @@ -15,47 +15,131 @@ function newWin(url) {

      Tutorial: Importing an existing project

      -

      The following tutorial takes you though the process of importing a simple application using the CDT.

      +

      The following tutorial takes you though the process of importing a 'legacy' application using the CDT.

      -

      Step 1: You want to create a single project that will reflect all of the components for the existing source tree.

      +

      Step 1: You want to create a single project that will reflect all of the components for the existing source tree.

      1. Select File > New > Project. -
      2. For this tutorial, expand C++ and select C++ project. -


        The New Project wizard displays. Click here to see an illustration (displayed in a separate window).


        - - +
      3. For this tutorial, expand C/C++ and select C++ project. +


        + The New Project wizard displays. + Click + here to see an illustration (displayed in a separate window).

        +
      4. In the Project name field, type a name for the project. -
      5. Ensure that the Use default location option is not selected because you will need to specify where the resources reside in the file system since they do not reside in your workspace. -
      6. In the Location field, specify a path for your project. -
      7. From the Project types list, expand Makefile Project and select Hello World C++ Project. +
      8. Ensure that the Use default location option is not selected because here we will specify where the + resources reside in the file system, in a location other than your workspace.
        + We assume this directory location already exists, and contains e.g. source files and makefile. If it does not exist, it + will be created. +

        In this example, we will use an existing hello.cpp and its + existing hello.mak makefile, located in the directory c:\brandon. +

          + Click + here to see an illustration (displayed in a separate window).

        + +

        +
      9. In the Location field, specify the path to the existing files for your project. +
      10. From the Project types list, expand Makefile Project and select Empty Project.. +
          +
        • To have sample source and a makefile created in your existing directory, select Hello World C++ Project +
        +
      11. Make sure a toolchain is selected.
      12. +
      13. Click Next. -
      14. Select only the configurations you want created. Configurations display for each toolchain selected on the previous page of the wizard. +

          + +

      15. (Optional) On the Select Configurations page, select only the configurations you want created. Configurations + display for each toolchain selected on the previous page of the wizard.
      16. Click Finish to close the dialog box. -

        You will see the new project in the C/C++ Projects view. In addition, new 'dot' files in your legacy project's root directory, these are CDT project files.

        +

        You will see the new project in the Project Explorer view. In addition, new 'dot' files have been created in + your legacy project's root directory, these are CDT project files.

        +

      Step 2: You are now ready to build your project.

        -
      1. To build your project, select File > Build Project. -

        After the project build completes, the results display in the Console view and new objects, such as binaries and includes, show in the Projects view.

        +
      2. To build your project, select Project > Build Project. +
        You can also hit the hammer icon on the toolbar to + build the selected project. +
         
        +
      3. You may see an error e.g. "make: *** no rule to make target 'all'. +

        This is because, in our case, we didn't tell it where the makefile is, or its name.

        +
          +
        • Open the project properties (right mouse on project name in the Project Explorer view + and select Properties at the bottom on the context menu).
        • +
        • On the C/C++ Build Page, on its Builder Settings tab, uncheck "Use default build command" + and change the make command to make -f hello.mak + since our makefile is not named the default makefile. +

          Click + here to see an illustration (displayed in a separate window).

          +
        • +
        • Click OK to close the Project Properties window. +
        • +
        • Your project will probably rebuild. If not you can force a build via + Project > Build Project + or use the hammer icon . +
        • +
        +
      4. +

        After the project build completes, the results display in the Console view and new objects, such as binaries and includes, show in the Project Explorer view.

        +

          + Click + here to see an illustration (displayed in a separate window).

      5. Review the results to ensure that there are no errors. -

        Note: By default, the indexer is set to Fast indexer for the project to parse your project in the same way that a compiler does; beginning with each compilation unit and parsing that file and all files that it includes, except that it parses each header file included in a project only once. This method provides the most accurate index information. For large projects using complex C++ code, this indexer can be slow. For example, if a header file is included and takes two compilation units, the parsing of the second unit reuses the results of parsing the first unit. This is similar to how precompiled headers work. The indexing of large projects using the Fast indexer uses fewer resources than the Full indexer, but the resulting index is not quite as accurate.

        +

          +

        +Note: By default, the indexer is set to Fast indexer for the project to parse your project in the same way that a compiler does; beginning with each compilation unit and parsing that file and all files that it includes, except that it parses each header file included in a project only once. This method provides the most accurate index information. For large projects using complex C++ code, this indexer can be slow. For example, if a header file is included and takes two compilation units, the parsing of the second unit reuses the results of parsing the first unit. This is similar to how precompiled headers work. The indexing of large projects using the Fast indexer uses fewer resources than the Full indexer, but the resulting index is not quite as accurate. +
        To change indexer settings, bring up the Indexer page in the Project Properties. +

        Click here to see an illustration (displayed in a separate window).


        + +
        +

      Step 3: You are now ready to run your application.

        -
      1. To run your application within the C/C++ Perspective, click Run > Run

        +

      2. To run your application within the C/C++ Perspective, click Run > Run Configurations...

        The Run Configurations dialog displays.

        -
      3. To create a run configuration, select Local C/C++ Application and click OK. -
      4. Select the new run configuration in the Configurations view and click the Main tab to edit your run configuration. -
      5. Optional: You can change the name of your run configuration by entering a new name in the Name field. -
      6. To select the project, click Browse opposite the Project field. -
      7. From the Project Selection window, select the project and click OK. -
      8. Select the new C/C++ Application you want to execute by clicking Search. -
      9. From the Program Selection window, select an appropriate binary from the list and click OK. -
      10. Click Apply to save the run configuration and then click Run. +
      11. To create a run configuration, select C/C++ Application and click the New icon. +
      12. Give your run configuration a name by entering a new name in the Name field at the top. +
      13. On the Main tab, select the project by clicking Browse opposite the Project field. +
          +
        • From the Project Selection window, select the project and click OK. +
      14. Select the new C/C++ Application you want to execute by clicking Search. +

        In our case it didn't find the file because it's in a nonstandard location. +Use the Browse button to select the executable. In our case also it's a nonstandard +name, hello.e because that's what our makefile hello.mak built.

        +

        Click + here to see an illustration (displayed in a separate window).

        +
          +
        • If you see the error "[Debugger]: No debugger available", select the Debugger tab + and choose a valid debugger for your platform (e.g. gdb/mi). +
        • +
        + + +
      15. Click Run to save the run configuration and run it. +

        Click + here to see an illustration (displayed in a separate window).

        The application runs in the Console view. The Console also shows which application it is currently running in the title bar. You can configure the view to display different elements, such as user input elements using different colors.

      QNX Copyright Statement diff --git a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_newcpp.htm b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_newcpp.htm index 53e3e61d65d..ace9f5c8287 100644 --- a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_newcpp.htm +++ b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_newcpp.htm @@ -14,7 +14,7 @@

      You can begin coding your HelloWorld program. The .cpp file that you create will be saved in the project folder you just created -Creating a project.

      +Creating a Makefile project.

      Files are edited in the C/C++ editor located to the right of the C/C++ Projects view. The left margin of the C/C++ editor, called the marker @@ -22,58 +22,50 @@ bar, displays icons for items such as bookmarks, breakpoints, and compiler erro

      For more information about:

        -
      • The marker bar, see Workbench User Guide > Reference > User interface - information > Icons and buttons > Editor area marker bar
      • -
      • The editor area, see Workbench User Guide > Reference > User interface + +
      • The editor area and marker bar, see Workbench User Guide > Reference > User interface information > Views and editors > Editor area
      • +
      • The marker bar icons, see Workbench User Guide > Reference > User interface + information > Icons and buttons > Editor area marker bar

      To create a C++ file:

        -
      1. In the C++ Projects view, right-click the HelloWorld project - folder, and select New > File.
      2. -
      3. In the File name field, type main.cpp.
      4. +
      5. In the Project Explorer view, right-click the HelloWorld project + folder, and select New > Source File.
      6. +
      7. In the Source file: field, type main.cpp. +
        By default the source folder should be your project folder. +
        The template selected is probably "Default C/C++ Source Template." +
      8. Click Finish.
      9. -
      10. Type the code, exactly as it appears below, in the editor. Lines are indented with tab - characters, not with spaces.
      11. +
      12. A Comment template probably appears at the top of an otherwise empty file. + Type the code, exactly as it appears below, in the editor. + Or you can paste it in from this help file. +
      13. +
        +#include <iostream>
        +using namespace std;
        +
        +int main () {
        +    // Say Hello five times
        +    for (int index = 0; index < 5; ++index)
        +      cout << "HelloWorld!" << endl;
        +    char input = 'i';
        +    cout << "To exit, press 'm'" << endl;
        +    while(input != 'm') {
        +        cin  >> input;
        +        cout << "You just entered " << input
        +             << " you need to enter m to exit." << endl;
        +    }
        +    exit(0);
        +}
        +
        + -
        -

        #include <iostream>
        - using namespace std;
        -
        - int main () {
        -     - // Say Hello five times
        -     - for (int index = 0; index < 5; ++index)
        -     - cout << "HelloWorld!" << endl;
        -
        -     - char input = 'i';
        -
        -     - cout << "To exit, press 'm'" << endl;
        -
        -     - while(input != 'm') {
        -         - cin  >> input;
        -         - cout << "You just entered " << input
        -             << " you need to enter m to exit." << endl;
        -     - }
        -
        -     - exit(0);
        - }

        -
      14. Click File > Save.
      -

      Your new .cpp file is displayed in the C/C++ Projects -view and in the Navigator view. Your project now contains main.cpp. Before you +

      Your new .cpp file is displayed in the Project Explorer view. Your project now contains main.cpp. Before you can build your HelloWorld project, you must create a makefile.

      diff --git a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_newmake.htm b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_newmake.htm index b437907f5d7..ce562f6a5fe 100644 --- a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_newmake.htm +++ b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_newmake.htm @@ -21,9 +21,8 @@ function newWin(url) {

      To create a makefile:

        -
      1. In the C++ Projects view, right-click the HelloWorld project +
      2. In the Project Explorer view, right-click the HelloWorld project folder and select New > File. -


        Click here to see an illustration (displayed in a separate window).


      3. In the File name box, type makefile.
      4. Click Finish.
      5. Type the gnu make instructions below in the editor. Lines are @@ -48,9 +47,11 @@ function newWin(url) { Save.

      Your new makefile, along with your main.cpp file are -displayed in the C/C++ Projects view and in the Navigator view. Your project now +displayed in the Project Explorer view. Your project now contains main.cpp and makefile. You can now build your HelloWorld project.

      -

      Click here to see an illustration.

      + + +

      NEW Click here to see an illustration.

      diff --git a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_newproj.htm b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_newproj.htm index 24c3dbda0d6..e1e122a5c0c 100644 --- a/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_newproj.htm +++ b/doc/org.eclipse.cdt.doc.user/getting_started/cdt_w_newproj.htm @@ -13,8 +13,10 @@ function newWin(url) { -

      Creating a project

      +

      Creating a Makefile project

      +

      +This tutorial describes the process of creating a new C++ project that includes a makefile, and debugging the program.

      You need to create a project to contain your source code and related files. A project has an associated builder that can incrementally compile source files as they are changed.

      @@ -23,7 +25,7 @@ that can incrementally compile source files as they are changed.

      1. Select File > New > Project.


        When you create a new project, you are required to specify the project type. This project type will determine the toolchain, data, and tabs that the CDT uses/displays.


        -
      2. Select the type of project to create. For this tutorial, expand the C++ folder and select C++ Project. +
      3. Select the type of project to create. For this tutorial, expand the C/C++ folder and select C++ Project.

        The C++ Project wizard opens. Click here to see an illustration.


        By default, the CDT filters the Toolchain and Project types that currently display in those lists are based on the language support for the C++ Project wizard you selected for this tutorial.


      4. In the Project name field, type HelloWorld. @@ -33,10 +35,13 @@ that can incrementally compile source files as they are changed.

      5. Executable - Provides an executable application. This project type folder contains three templates.

        • Hello World C++ Example provides a simple C++ Hello World application with main(). -
        • Hello World ANSI C Example provides a simple C Hello World application with main().
        • Empty Project provides a single source project folder that contains no files. -
        - -

        After you select a template, the result is a project with only the meta-data files required for the project type. You are expected to modify these source files, as required, and provide source files for the project's target.

        The makefile for the Executable project type is automatically created by the CDT.

        +
      6. Hello World ANSI C Example provides a simple C Hello World application with main(). +
      7. Empty Project provides a single source project folder that contains no files. +

        After you select this template, the result is a project with only the meta-data files required for the project type. + You are expected to provide source files for the project's target.

        +
    +

    The makefile for the Executable project type is automatically created by the CDT.

    +

     

  • Shared Library - An executable module that is compiled and linked separately. When you create a project that uses a shared library (libxx.so), you define your shared library's project as a Project Reference for your application. For this project type, the CDT combines object files together and joins them so they're relocatable and can be shared by many processes. Shared libraries are named using the format libxx.so.version, where version is a number with a default of 1. The @@ -47,41 +52,52 @@ into an archive (*.a) that is directly linked into an executable. The makefile for this project type is automatically created by the CDT.
  • Makefile Project - Creates an empty project without the meta-data files. This selection is useful for importing and modifying existing makefile-based projects; a new makefile is not created for this project type. +

    By default, the CDT filters the Toolchain and Project types that currently display in those lists based on the language support for the C++ Project wizard you selected for this tutorial. -

  • From the Project types list, expand Executable and select Hello World C++ Example. This project type provides a simple Hello World application in C++, and the makefile is automatically created by the CDT. +

     

    +
  • From the Project types list, expand Makefile project and select Empty Project. +This project lets you enter the source file and the makefile yourself.
  • Select a required toolchain from the Toolchain list.

    A toolchain is a set of tools (such as a compiler, linker, and assembler) intended to build your project. Additional tools, such as a debugger, can be associated with a toolchain.
    There can be several toolchains available, depending on the compilers installed on your system.

    - +
  • -
  • Click Next.
  • -
  • Click Advanced Settings. -
  • Click the Binary Parser tab. +
  • Click Next. +
  • (Optional) On the Select Configurations page, Click Advanced Settings. +
      +
    • Expand C/C++Build > Settings. Click the Binary Parsers tab.


      Click here to see an illustration.


    • -
    • In the Binary Parser list, select PE Windows Parser.
    • +
    • In the Binary Parser list, select the error parser that is appropriate for your platform. +Other project settings can be modified here as well. The default selection is probably OK. + +
    • To ensure the accuracy of the C/C++ Projects view and the ability to successfully run and debug your programs, selecting the correct parser is important. After you select the correct parser for your development environment and build your project, you can view the components of the .o file in the C/C++ Projects view. You can also view the contents of the .o file in the C/C++ editor. +

      Click OK to close the Project Properties window. +

  • Click Finish.
  • If a message box prompts you to change perspectives, click Yes.
  • -

    Your new project displays in the C/C++ Projects view, and in -the Navigator view. Your project is empty because you have not yet created -files for your project. You can now start writing the code for your HelloWorld +

    Your new project displays in the Project Explorer view. +Your project is empty because you have not yet created +files for your project. +You may see an error since there is nothing to build yet for your project. +You can now start writing the code for your HelloWorld program.

    Tip: You can view and modify the properties of your -HelloWorld project by right-clicking on the project in the C/C++ Projects +HelloWorld project at any time by right-clicking on the project in the Project Explorer view and clicking Properties.

    Next Icon Next: Creating your C++ file

    For more information diff --git a/doc/org.eclipse.cdt.doc.user/images/cdt_w_bin.png b/doc/org.eclipse.cdt.doc.user/images/cdt_w_bin.png new file mode 100644 index 00000000000..1d4df052575 Binary files /dev/null and b/doc/org.eclipse.cdt.doc.user/images/cdt_w_bin.png differ diff --git a/doc/org.eclipse.cdt.doc.user/images/cdt_w_binparser01.png b/doc/org.eclipse.cdt.doc.user/images/cdt_w_binparser01.png index 9bac776a926..af984c339b2 100644 Binary files a/doc/org.eclipse.cdt.doc.user/images/cdt_w_binparser01.png and b/doc/org.eclipse.cdt.doc.user/images/cdt_w_binparser01.png differ diff --git a/doc/org.eclipse.cdt.doc.user/images/cdt_w_import02.png b/doc/org.eclipse.cdt.doc.user/images/cdt_w_import02.png index c99fe37673c..33eb71ac529 100644 Binary files a/doc/org.eclipse.cdt.doc.user/images/cdt_w_import02.png and b/doc/org.eclipse.cdt.doc.user/images/cdt_w_import02.png differ diff --git a/doc/org.eclipse.cdt.doc.user/images/cdt_w_importBrandon01.png b/doc/org.eclipse.cdt.doc.user/images/cdt_w_importBrandon01.png new file mode 100644 index 00000000000..0922e275fbb Binary files /dev/null and b/doc/org.eclipse.cdt.doc.user/images/cdt_w_importBrandon01.png differ diff --git a/doc/org.eclipse.cdt.doc.user/images/cdt_w_importBrandon02.png b/doc/org.eclipse.cdt.doc.user/images/cdt_w_importBrandon02.png new file mode 100644 index 00000000000..b4fd685e707 Binary files /dev/null and b/doc/org.eclipse.cdt.doc.user/images/cdt_w_importBrandon02.png differ diff --git a/doc/org.eclipse.cdt.doc.user/images/cdt_w_importBrandon03.png b/doc/org.eclipse.cdt.doc.user/images/cdt_w_importBrandon03.png new file mode 100644 index 00000000000..8f61be8037b Binary files /dev/null and b/doc/org.eclipse.cdt.doc.user/images/cdt_w_importBrandon03.png differ diff --git a/doc/org.eclipse.cdt.doc.user/images/cdt_w_importBrandon04run.png b/doc/org.eclipse.cdt.doc.user/images/cdt_w_importBrandon04run.png new file mode 100644 index 00000000000..17707514101 Binary files /dev/null and b/doc/org.eclipse.cdt.doc.user/images/cdt_w_importBrandon04run.png differ diff --git a/doc/org.eclipse.cdt.doc.user/images/cdt_w_importBrandon04run2.png b/doc/org.eclipse.cdt.doc.user/images/cdt_w_importBrandon04run2.png new file mode 100644 index 00000000000..2cd374b7cd9 Binary files /dev/null and b/doc/org.eclipse.cdt.doc.user/images/cdt_w_importBrandon04run2.png differ diff --git a/doc/org.eclipse.cdt.doc.user/images/cdt_w_indexer.png b/doc/org.eclipse.cdt.doc.user/images/cdt_w_indexer.png new file mode 100644 index 00000000000..a5ee31f8e37 Binary files /dev/null and b/doc/org.eclipse.cdt.doc.user/images/cdt_w_indexer.png differ diff --git a/doc/org.eclipse.cdt.doc.user/images/cdt_w_newmake02.png b/doc/org.eclipse.cdt.doc.user/images/cdt_w_newmake02.png index cd69d24c269..cc575f00168 100644 Binary files a/doc/org.eclipse.cdt.doc.user/images/cdt_w_newmake02.png and b/doc/org.eclipse.cdt.doc.user/images/cdt_w_newmake02.png differ diff --git a/doc/org.eclipse.cdt.doc.user/images/cdt_w_newmake03.png b/doc/org.eclipse.cdt.doc.user/images/cdt_w_newmake03.png new file mode 100644 index 00000000000..c9a9321c77c Binary files /dev/null and b/doc/org.eclipse.cdt.doc.user/images/cdt_w_newmake03.png differ diff --git a/doc/org.eclipse.cdt.doc.user/images/cdt_w_viewMenu.png b/doc/org.eclipse.cdt.doc.user/images/cdt_w_viewMenu.png new file mode 100644 index 00000000000..c4080540629 Binary files /dev/null and b/doc/org.eclipse.cdt.doc.user/images/cdt_w_viewMenu.png differ diff --git a/doc/org.eclipse.cdt.doc.user/images/cdt_w_viewMenuFilters.png b/doc/org.eclipse.cdt.doc.user/images/cdt_w_viewMenuFilters.png new file mode 100644 index 00000000000..92234ea25d2 Binary files /dev/null and b/doc/org.eclipse.cdt.doc.user/images/cdt_w_viewMenuFilters.png differ diff --git a/doc/org.eclipse.cdt.doc.user/images/cdt_w_viewMenuFilters2.png b/doc/org.eclipse.cdt.doc.user/images/cdt_w_viewMenuFilters2.png new file mode 100644 index 00000000000..5cab36667f0 Binary files /dev/null and b/doc/org.eclipse.cdt.doc.user/images/cdt_w_viewMenuFilters2.png differ diff --git a/doc/org.eclipse.cdt.doc.user/images/hammer-icon.png b/doc/org.eclipse.cdt.doc.user/images/hammer-icon.png new file mode 100644 index 00000000000..5d0076d4b71 Binary files /dev/null and b/doc/org.eclipse.cdt.doc.user/images/hammer-icon.png differ diff --git a/doc/org.eclipse.cdt.doc.user/topics_Getting_Started.xml b/doc/org.eclipse.cdt.doc.user/topics_Getting_Started.xml index d7f937d87d4..50ba8156928 100644 --- a/doc/org.eclipse.cdt.doc.user/topics_Getting_Started.xml +++ b/doc/org.eclipse.cdt.doc.user/topics_Getting_Started.xml @@ -3,10 +3,10 @@ - + - \ No newline at end of file +