我正在尝试使用NetBean来编写C++,我已经按照这里找到的每个命令进行了操作:https: //netbeans.org/community/releases/68/cpp-setup-instructions.html#compilers_windows
但是,我在netbeans中使用make命令选项时遇到问题.我已经设置了基本目录o M:\ c ++\bin,我安装了MinGW,并且我将make命令设置为M:\ MinSYS\bin\make.exe,但是当尝试构建一个简单的程序时,netbeans会生成以下错误:
"/M/c++/MinSYS/bin/make.exe" -f nbproject/Makefile-Debug.mk QMAKE= SUBPROJECTS= .build-conf
make.exe[1]: Entering directory `/m/Documents/NetBeansProjects/CppApplication_1'
"/M/c++/MinSYS/bin/make.exe" -f nbproject/Makefile-Debug.mk dist/Debug/MinGW-Windows/cppapplication_1.exe
make.exe[2]: Entering directory `/m/Documents/NetBeansProjects/CppApplication_1'
mkdir -p build/Debug/MinGW-Windows
make.exe[2]: mkdir: Command not found
make.exe[2]: *** [build/Debug/MinGW-Windows/main.o] Error 127
make.exe[2]: Leaving directory `/m/Documents/NetBeansProjects/CppApplication_1'
make.exe[1]: *** [.build-conf] Error 2
make.exe[1]: Leaving directory `/m/Documents/NetBeansProjects/CppApplication_1'
make.exe": *** [.build-impl] Error 2
Run Code Online (Sandbox Code Playgroud)
我已经尝试将make命令更改为包含make的任何内容,但是无论如何都没有,任何帮助都会受到大力赞赏.
作为更广泛项目的一部分,我给出了一个角度,需要转换为弧度进行一些计算.
到目前为止,我有以下内容:
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
feature1()
{
double angle = 90.0000, angle2;
angle2 = convert_to_rad(angle);
printf("%lf", &angle);
}
double convert_to_rad(double angle_in_deg)
{
double angle_in_rad;
angle_in_rad = (angle_in_deg * M_PI) / 180;
return angle_in_rad;
}
Run Code Online (Sandbox Code Playgroud)
在NetBeans中编译文件时,我收到以下错误:
note: previous implicit declaration of 'convert_to_rad' was here.
error: conflicting types for 'convert_to_rad
Run Code Online (Sandbox Code Playgroud)