Howto:Build FlightGear with NetBeans using CMake
The latest CMake-specific build instructions can be found in $FG_SRC/README.cmake: flightgear/README.cmake. If you encounter any CMake-related bugs while trying to build SimGear and/or FlightGear, please consider filing a bug report here: Issue tracker tickets. If you think the instructions are lacking some details, you are invited to add them as required. Also, if you think that some more specific screen shots would help, please do feel free to upload new screen shots here: Special:UploadWizard. Don't worry if you don't know how to embed these images, you can simply leave a comment on the article's talk page, so that we can update the article accordingly. Thanks!
Download and install NetBeans
NetBeans is a multi-platform IDE (integrated development environment) that supports a number of programming languages, C and C++ among them. NetBeans is a highly modular and very powerful IDE with a huge range of features. Go to https://netbeans.apache.org/ in order to download the latest version of NetBeans for your OS/platform. After downloading NetBeans, you'll need to install it.
|Note According to the latest release notes release notes 12.0 the C++ plugin is not ported to the new Apache infrastructure. You have to enable Netbeans 8.2 plugin center and install C/C++ plugin from it. It will be available in the future releases in the NetBeans core.|
Linux: getting & compiling
Please take a look at generic page: Building_FlightGear or Building on Linux using the download_and_compile.sh bash script
Windows: getting & compiling
Please take a look at the generic page regarding Windows compilation: Building using CMake - Windows
You need separate folders in which the project build outputs will be created. If you download and create folders according to the build environment in Windows/Linux OS there is nothing new.
Netbeans project import
After checking out the repository, you'll want to use the NetBeans project wizard to CREATE A NEW PROJECT FROM EXISTING SOURCES for each dependency:
Next, pick "...from existing sources":
Specify the folder where the checked out sources can be found:
Click Finish. NetBeans will attempt to build the project, which will fail, as no dependencies have been set. Ignore it, the project will still be set-up. Repeat above steps for the simgear code. Finally, you should see all projects neatly structured in NetBeans:
Disable code indexing
By default, NetBeans will keep on trying and index all your sources, this may slow down the IDE considerably, so it's a good idea to disable this feature if you don't need it (CONTEXT MENU/RIGHT CLICK on project, go to CODE ASSISTANCE and then uncheck the marked entry):