Configuring C and C++ Build Tools
See Also
You can use the Options window to configure default build tools for your C and C++ projects.
To configure C and C++ build tools:
-
Choose Tools > Options.
-
Click C/C++ in the top pane of the window.
-
Click the Build Tools tab.
-
Modify the properties as desired.
You can set the following properties:
-
Development Host. The Development Host list includes your local host and any remote
hosts you have defined. For information on using remote hosts, see Remote Development. You can add and remove remote development
hosts, change the default host, and share project sources on the local host with the remote
host.
-
To add a remote host, click Edit. In the Development Host Manager dialog box, click
Add. The New Remote Development Host wizard starts. See the help for the New Remote Development Host wizard for more
information.
-
To remove a remote host, click Edit. In the Development Host Manager dialog box, select
the host you want to remove, click Remove, then click OK.
-
To set a host as the default development host, select the host from the Development
Host list and click Set as Default.
-
To map the project sources on the local host to a remote host, click Path Mapper. In
the Edit Path's Map dialog box, select the remote host in the Host list. For each
mapping, type the local path to project sources in the Local Path field or use the
browse button to navigate the local filesystem and select the project's location. In
the Remote Path field, type the path to get to the project sources from the remote
host.
-
To change IDE properties related to a remote development host, click Properties. In
the Host Properties dialog box, you can change the name displayed in the IDE for the
host by typing in the Name field. To change the way project files are shared with the
remote host, select the file synchronization method in the Synchronization list. If the
project files are in a shared folder accessible from the local host and remote host,
select File System Sharing. If sharing the files is not possible, select rsync to use
the rsync utility to copy files to the remote host, or scp to use the secure copy
command to copy the files. The files are copied to your .netbeans directory by default.
This can be changed with the Path Mapper.
-
Tool Collection. The tool collection list displays the collections found on the
current development host and the local host. The default collection is listed in bold type.
This collection is selected by default for any new project you create. You can change the
default tool collection for a specific project in the project properties. For the local
host, you can modify the list by adding or removing collections.
-
-
To add a collection to the list, click Add and specify the base directory in the Add
New Tool Set dialog box. The Tool Set Family and Tool Set Name are filled in
automatically. You can specify a different name for the collection. If you change the
family, make sure that the family you specify is the correct family for the collection
or the compiler flags might not be valid.
-
To remove a collection from the list, select the collection and click Remove.
-
To duplicate a collection, select the collection from the list and modify the base
directory, tool set family, or tool set name in the dialog box.
-
To make a collection the default, select the collection and click Default.
-
Base Directory. The base directory for compilers for the current development host.
These fields can be edited for the local host but not for remote hosts.
-
-
C Compiler. The C compiler to use for building projects. The default compiler is
the first one found in the base directory.
-
C++ Compiler. The C++ compiler to use for building projects. The default
compiler is the first one found in the selected compiler collection.
-
Fortran Compiler. The Fortran compiler to use for building projects. The default
compiler is the first one found in the base directory.
-
Make Command. The make command to use for building projects. The default command is
the first one found in the base directory. To select a different command from the base
directory or another directory, click the browse button and navigate to a different command
in the Select Tool dialog box.
-
Debugger Command. The gdb command to use when debugging projects. The default
command is the first one found in the base directory. To select a different command from
the base directory or another directory, click the browse button and navigate to a
different command in the Select Tool dialog box.
To display the versions of all of the selected tools, click Versions.
To restore all of the tool selections to the defaults, click Restore Defaults.
To set the build tools properties for a specific project, right-click the project and choose
Properties.
Configuring C and C++ Project Settings
Configuring C and C++ Parser Settings
Configuring C and C++ Formatting Style
Configuring C and C++ Semantic
Highlighting
Configuring C and C++ File Extensions
Setting Project Properties
C/C++ Properties Dialog Box: Build
Legal Notices