As stated in 4th and 5th donations the "cnd" cluster as donated presents some issues that have to be resolved. This page presents a proposal to recover some of the functionality of the "cnd" cluster.
cpplite
Work has progressed in the Apache NetBeans C/C++ front via the "cpplite" cluster, which provides integration with different C/C++ Language Server Protocol servers (LSP), including https://clangd.llvm.org/
These C/C++ LSP servers provide syntax highlighting, code completion, go-to definitions and more (see https://clangd.llvm.org/features for a detailed list of features), and are maintained by third parties.
The "cpplite" cluster offers a basic NetBeans project structure, that requires manual creation of the so-called "compilation database" https://clang.llvm.org/docs/JSONCompilationDatabase.html so that the LSP servers can work properly.
cnd-small - Objectives
The objectives of the proposal are:
- to recover some of the functionalities of the cnd cluster (see below)
- to integrate these with cpplite and C/C++ LSP servers (see below)
Proposed plan
The proposed plan is as follows:
cnd-small/1 - Recover some of the funcionalities of the cnd cluster in a new "cnd-small" branch
The proposed list of functionalities to recover is:
- Makefile based project infrastructure https://netbeans.apache.org/kb/docs/cnd/quickstart.html. including C/C++ Shell Script and Makefile with syntax highlighting (cnd/cnd.script). This will allow opening projects created with NetBeans <= 8.2.
- Platform specific toolchains https://netbeans.apache.org/kb/docs/cnd/toolchain.html.
- Remote capabilities https://netbeans.apache.org/kb/docs/cnd/remotedev-tutorial.html.
The idea is to delete all the modules in cnd but the ones listed in the following build-time-only Dependency Structure Matrix:
(see attached cnd-small-cluster.xlsx for details)
The editor can also be included in the list by removing the dependency with jclank (used for formatting) the resulting DSM would then be
NOTE: The DSMs above represent build-time module dependencies (not test dependencies nor runtime dependencies).
NOTE: This subset of the "cnd" cluster seems to be working on Linux, a preliminar branch is here: https://github.com/vieiro/netbeans/tree/cnd-small
cnd-small/2 - Import latest enhancements from master
Once these functionalities are in place the proposal is to merge master into "cnd-small", to integrate with the latest enhancements.
NOTE: For an example see https://github.com/vieiro/netbeans/tree/cnd-small-2
cnd-small/3 - Integrate cnd-small with cpplite
Once "cnd-small" in in place and merged with master, the plan is to enhance the NetBeans Makefile-based projects so that a compilation database can be generated automatically (using the cnd/cnd.api.project and/or cnd.makeproject).
Once the compilation database is generated automatically, it would be easier for users to benefit from code-completion and other features.
cnd-small/4 - Release and future enhancements
At this stage this small subset of the "cnd" cluster could hopefully be rolled-out to users.
After that there are some possible future enhancements:
- See if we want to recover any module from the "cnd" donation.
- Add more tools to the existing Toolchains (including Microsoft Visual Studio 2022, with a free-to-use Community Edition?)