Skip to content

Commit

Permalink
Getting Started documentation update.
Browse files Browse the repository at this point in the history
* Put Core Build and Managed Build items in separate topics.
* Added two images to Creating a CMake project.
* Added new pages about creating a CBS Makefile project, using
  existing code, and the launch bar.
* Renamed "Creating a simple application" to "Creating a Managed Build
  System Makefile project" and replaced two images.
* Removed "Creating a Makefile project", because it was duplicate
  information.

Fixes eclipse-cdt#992
  • Loading branch information
ewaterlander committed Jan 23, 2025
1 parent 9e04dc5 commit c429387
Show file tree
Hide file tree
Showing 20 changed files with 312 additions and 194 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified doc/org.eclipse.cdt.doc.user/images/cdt_w_basic03a.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/org.eclipse.cdt.doc.user/images/launchbar.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
////
Copyright (c) 2000, 2025 Contributors to the Eclipse Foundation
This program and the accompanying materials
are made available under the terms of the Eclipse Public License 2.0
which accompanies this distribution, and is available at
https://www.eclipse.org/legal/epl-2.0/

SPDX-License-Identifier: EPL-2.0
////

// pull in shared headers, footers, etc
:docinfo: shared

// support image rendering and table of contents within GitHub
ifdef::env-github[]
:imagesdir: ../../images
:toc:
:toc-placement!:
endif::[]

// enable support for button, menu and keyboard macros
:experimental:

// Until ENDOFHEADER the content must match adoc-headers.txt for consistency,
// this is checked by the build in do_generate_asciidoc.sh, which also ensures
// that the checked in html is up to date.
// do_generate_asciidoc.sh can also be used to apply this header to all the
// adoc files.
// ENDOFHEADER

== Launch Bar

CBS projects rely on the *LaunchBar*. Make sure the launch bar plugin
is installed and enabled. In the global preferences the launch bar can
be enabled or disabled.

image:launchbar_preferences.png[Launch Bar preferences]

The launch bar exists out of several components:

image:launchbar.png[Launch Bar]

. Build button, to launch a build.
. Run button, to launch a run. This button will change to a Debug
button in Debug mode.
. Stop button, to stop a Run or Debug session.
. Launch mode selector. To change between Run and Debug mode.
. Launch configuration selector.
. Edit launch configuration. To change the launch configuration
properties.
. Target selector. Not always visible.
. Edit target.
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
////
Copyright (c) 2000, 2025 Contributors to the Eclipse Foundation
This program and the accompanying materials
are made available under the terms of the Eclipse Public License 2.0
which accompanies this distribution, and is available at
https://www.eclipse.org/legal/epl-2.0/

SPDX-License-Identifier: EPL-2.0
////

// pull in shared headers, footers, etc
:docinfo: shared

// support image rendering and table of contents within GitHub
ifdef::env-github[]
:imagesdir: ../../images
:toc:
:toc-placement!:
endif::[]

// enable support for button, menu and keyboard macros
:experimental:

// Until ENDOFHEADER the content must match adoc-headers.txt for consistency,
// this is checked by the build in do_generate_asciidoc.sh, which also ensures
// that the checked in html is up to date.
// do_generate_asciidoc.sh can also be used to apply this header to all the
// adoc files.
// ENDOFHEADER

== Using existing code

This tutorial describes how to use existing code for Core Build System
projects.

Using existing code is done by creating a new **empty** project on top of the
existing code.

=== Using an existing CMake project

To create an empty CMake project select the template *Empty or Existing CMake
Project* in the *New C/{cpp} Project* wizard.

image:cbs_empty_cmake_project.png[Empty or Existing CMake Project]

Then in the *New CMake Project* wizard deselect *Use default location*
and set the location of the existing code.

image:cbs_existing_code_cmake.png[Existing code CMake]

More information about creating a CMake project is described in
xref:new_cmake_proj.adoc[Creating a CMake project]

=== Using an existing Makefile project

Create a Makefile project as described in
xref:new_cbs_makefile_proj.adoc[Creating a Core Build System Makefile project]
with the following changes:

In the *New Makefile Project* wizard deselect *Use default location*
and set the location of the existing code, and deselect *Create Hello
World Source and Makefile example*.

image:cbs_existing_code_makefile.png[Existing code Makefile]

icon:arrow-circle-right[] xref:cbs_launchbar.adoc[Next: Launch Bar]
22 changes: 7 additions & 15 deletions doc/org.eclipse.cdt.doc.user/src/getting_started/cdt_w_basic.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,13 @@ endif::[]
// adoc files.
// ENDOFHEADER

== Tutorial: Creating a simple application
== Tutorial: Creating a Managed Build System Makefile project

In this tutorial, you will use the CDT to create a simple 'Hello World'
application. This tutorial describes the process of creating a new {cpp}
project where the build is 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). Now with CDT, you just
select a project type, and that determines what build system to use.

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

Expand All @@ -57,10 +52,13 @@ image:cdt_w_basic02.png[Select File > New > Project menu
option,width=591,height=183]
+
. Select the type of project to create. For this tutorial, expand the
*{cpp}* folder and select *{cpp} Project* and click *Next*.
*C/{cpp}* folder and select *C/{cpp} Project* and click *Next*.
+
image:cdt_w_basic03a.png[Select project type]
+
. Select *{cpp} Managed Build* and click *Next*.
+
image:cdt_w_basic03a.png[Select project
type,width=525,height=500]
image:cdt_w_basic03b.png[Select {cpp} Managed Build]
+
. The *{cpp} Project* wizard opens.
+
Expand Down Expand Up @@ -139,12 +137,6 @@ populated with objects created from your code.
image:cdt_w_basic13.png[C Editor with Outline
view,width=731,height=333]
+
*NOTE:* You can specify a different editor, and add or modify existing
code templates in *Window > Preferences*.
+
*OPTIONAL*: You can type additional code in this file, and then save the
changes by clicking File > Save, or pressing *CTRL+S*.
+
Next, you will need to build your project before you can run it.
+
. Build your project by pressing *CTRL+B*, or select the project in the
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,9 @@ xref:cdt_w_newmake.adoc[image:ngnext.gif[Next
icon,width=16,height=16]] *xref:cdt_w_newmake.adoc[Next: Creating your
makefile]*

xref:cdt_w_newproj.adoc[image:ngback.gif[Back
icon,width=16,height=16]] *xref:cdt_w_newproj.adoc[Back: Creating your
project]*
xref:cdt_w_import.adoc[image:ngback.gif[Back
icon,width=16,height=16]] *xref:cdt_w_import.adoc[Back: Importing an
existing project]*

image:ngconcepts.gif[Related concepts,width=143,height=21]

Expand Down
165 changes: 0 additions & 165 deletions doc/org.eclipse.cdt.doc.user/src/getting_started/cdt_w_newproj.adoc

This file was deleted.

41 changes: 41 additions & 0 deletions doc/org.eclipse.cdt.doc.user/src/getting_started/index_cbs.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
////
Copyright (c) 2000, 2025 Contributors to the Eclipse Foundation
This program and the accompanying materials
are made available under the terms of the Eclipse Public License 2.0
which accompanies this distribution, and is available at
https://www.eclipse.org/legal/epl-2.0/

SPDX-License-Identifier: EPL-2.0
////

// pull in shared headers, footers, etc
:docinfo: shared

// support image rendering and table of contents within GitHub
ifdef::env-github[]
:imagesdir: ../../images
:toc:
:toc-placement!:
endif::[]

// enable support for button, menu and keyboard macros
:experimental:

// Until ENDOFHEADER the content must match adoc-headers.txt for consistency,
// this is checked by the build in do_generate_asciidoc.sh, which also ensures
// that the checked in html is up to date.
// do_generate_asciidoc.sh can also be used to apply this header to all the
// adoc files.
// ENDOFHEADER

= Core Build System contents

xref:core_build_system.adoc[Core Build System]

xref:new_cmake_proj.adoc[Creating a CMake project]

xref:new_cbs_makefile_proj.adoc[Creating a Core Build System Makefile project]

xref:cbs_using_existing_code.adoc[Using existing code]

xref:cbs_launchbar.adoc[Launch Bar]
Loading

0 comments on commit c429387

Please sign in to comment.