|
| 1 | +//// |
| 2 | +Copyright (c) 2000, 2025 Contributors to the Eclipse Foundation |
| 3 | +This program and the accompanying materials |
| 4 | +are made available under the terms of the Eclipse Public License 2.0 |
| 5 | +which accompanies this distribution, and is available at |
| 6 | +https://www.eclipse.org/legal/epl-2.0/ |
| 7 | + |
| 8 | +SPDX-License-Identifier: EPL-2.0 |
| 9 | +//// |
| 10 | + |
| 11 | +// pull in shared headers, footers, etc |
| 12 | +:docinfo: shared |
| 13 | + |
| 14 | +// support image rendering and table of contents within GitHub |
| 15 | +ifdef::env-github[] |
| 16 | +:imagesdir: ../../images |
| 17 | +:toc: |
| 18 | +:toc-placement!: |
| 19 | +endif::[] |
| 20 | + |
| 21 | +// enable support for button, menu and keyboard macros |
| 22 | +:experimental: |
| 23 | + |
| 24 | +// Until ENDOFHEADER the content must match adoc-headers.txt for consistency, |
| 25 | +// this is checked by the build in do_generate_asciidoc.sh, which also ensures |
| 26 | +// that the checked in html is up to date. |
| 27 | +// do_generate_asciidoc.sh can also be used to apply this header to all the |
| 28 | +// adoc files. |
| 29 | +// ENDOFHEADER |
| 30 | + |
| 31 | += Core Build System |
| 32 | + |
| 33 | +The Core Build System is the successor of the legacy Managed Build |
| 34 | +System. |
| 35 | + |
| 36 | +The classical Makefile projects are based on the Managed Build System. |
| 37 | +Managed Build projects can generate a Makefile based on GUI controlled |
| 38 | +build configurations in the project properties. The user can |
| 39 | +manage the separate build configurations for Run and Debug. There is a |
| 40 | +notion of "active" build configuration, which is the one that gets |
| 41 | +built when the build button is pressed. |
| 42 | + |
| 43 | +The Core Build System is the basis for CMake projects and Core Build |
| 44 | +Makefile projects. The CDT LaunchBar plays a central role and is used |
| 45 | +for building and launching the program. The philosophy is "Build for |
| 46 | +launch". It simplifies the flow a lot. |
| 47 | + |
| 48 | +These are the main differences compared with the Managed Build System: |
| 49 | + |
| 50 | +* No build configurations. No build file (Makefile or |
| 51 | + CMakeLists.txt) generation. The user writes it by hand. A |
| 52 | + "helloworld" example build file can be created for new projects. |
| 53 | +* Each new project is created with a launch configuration tied to it. |
| 54 | +* Build settings are presented in the launch configuration Build Settings tab. |
| 55 | +* The LaunchBar determines Run or Debug mode for building. There is no |
| 56 | + concept of an active build configuration as there is in Managed |
| 57 | + Build projects. |
| 58 | +* Auto discovery. The project's macro definitions and include paths, |
| 59 | + needed for indexing, are extracted from the build step. For CMake |
| 60 | + projects, data is obtained from the generated JSON file. For Makefile |
| 61 | + projects, data is extracted from the build step console output. |
| 62 | +* Simpler wizards. Creation of a CMake project is via a simple one page |
| 63 | + wizard. Using existing code is simply done by creating a new project |
| 64 | + on top of the existing code. It is not necessary to import the project |
| 65 | + (menu:File[Import...]). |
| 66 | + |
| 67 | +Core Build connects CDT projects to industry standard external build |
| 68 | +systems like CMake, Makefile, and Meson. The removal of the CDT |
| 69 | +specific build configurations allow Core Build projects to be |
| 70 | +easily be shared with other IDEs, command-line use, and Continuous |
| 71 | +Integration (CI) flows. |
| 72 | + |
| 73 | +Thanks to the auto discovery, the indexing of the C/C++ code has |
| 74 | +improved, because all compilation flags are known per file. This is especially |
| 75 | +beneficial for projects that use multiple toolchains in one project. |
| 76 | + |
| 77 | +icon:arrow-circle-right[] link:pass:[../html/new_cmake_proj.html][Next: Creating a CMake project] |
0 commit comments