Identifying Compile Commands Using the Build Tool Configuration File
Symptom
If analysis of build file configuration is involved, the Compile Command may not be the default make or cmake command. You need to identify the compile command in the build file and then input the command.
Reference
- If Build Tool is make, the default value is make. You can also customize a compile command starting with "make". make supports -C and -f parameters. -C specifies the working directory. -f specifies the Makefile. If labels are used in your makefile, you need to identify the compile command based on the used labels.
- Usually the clean and all labels are used in the makefile, as shown in Figure 1.
make clean means to run the compile commands labeled with clean, and make means to run the compile command labeled with all or other associated labels. In this case, you only need to enter make in the Compile Command text box.
- If you add the mpp label, see Figure 2.
make mpp means to run the compile commands labeled with mpp. In this case, you need to enter make mpp in the Compile Command text box. For details, see Figure 3.
- Usually the clean and all labels are used in the makefile, as shown in Figure 1.
- If Build Tool is cmake, the default value is cmake. You can also customize a compile command starting with "cmake". For details about the parameters supported by CMake, see the CMake 3.13.4 user guide on the official website.
- If Build Tool is automake, the default value is make and cannot be changed. Automake does not support parameters. When using Automake, ensure that the makefile is available in the project source code. Upload the makefile together with the source file. Alternatively, you can run the automake commands after uploading the software to be analyzed, and change the owner of the generated makefile to devkit. In this way, the tool can read makefile properly.
- If Build Tool is go (only Go is selected for Source Code Type), the default value is go build. You can customize a compile command starting with "go".
Parent topic: Common Operations


