1

我正在尝试将一个工作项目从 Visual c 转移到我刚刚安装的 netbeans。但是,它不是在构建。以下是留言。

    "/usr/bin/make" -f nbproject/Makefile-Debug.mk QMAKE= SUBPROJECTS= .build-conf
make[1]: Entering directory '/cygdrive/c/Users/sam/Documents/NetBeansProjects/timerDAC'
"/usr/bin/make"  -f nbproject/Makefile-Debug.mk dist/Debug/Cygwin_4.x-Windows/timerdac.exe
make[2]: Entering directory '/cygdrive/c/Users/sam/Documents/NetBeansProjects/timerDAC'



cygwin warning:
      MS-DOS style path detected: /cygdrive/D/timer DAC code/EOGTester/DaqInTesteing\(New\)Out.c
      Preferred POSIX equivalent is: /cygdrive/D/timer DAC code/EOGTester/DaqInTesteing/(New/)Out.c
      CYGWIN environment variable option "nodosfilewarning" turns off this warning.
      Consult the user's guide for more details about POSIX paths:
        http://cygwin.com/cygwin-ug-net/using.html#using-pathnames


make[2]: *** No rule to make target '/cygdrive/D/timer DAC code/EOGTester/DaqInTesteing\(New\)Out.c', needed by 'build/Debug/Cygwin_4.x-Windows/_ext/1013452424/DaqInTesteing_New_Out.o'.  Stop.
make[2]: Leaving directory '/cygdrive/c/Users/sam/Documents/NetBeansProjects/timerDAC'
nbproject/Makefile-Debug.mk:60: recipe for target '.build-conf' failed
make[1]: *** [.build-conf] Error 2
make[1]: Leaving directory '/cygdrive/c/Users/sam/Documents/NetBeansProjects/timerDAC'
nbproject/Makefile-impl.mk:39: recipe for target '.build-impl' failed
make: *** [.build-impl] Error 2


BUILD FAILED (exit value 2, total time: 1s)

我读到

没有制定目标的规则

错误通常是由于拼写错误。但是,这是我正在导入的其他人的项目,我必须知道如何找到拼写错误的位置?

此外,cygwin 警告令人费解,其中“检测到的 MS-DOS 样式路径”和“首选 POSIX 等效项”仅相差“/”和“\”?

4

1 回答 1

1

First, you should never use pathnames that contain whitespace with make. Make simply doesn't support this in any real way. Rename your directory timer DAC code so it does not contain whitespace.

Second, the backslashes here are SUPPOSED to be escaping the parentheses, so ignore that warning. Cygwin is assuming that you meant to use them as directory separators but you didn't.

I'm not that familiar with the Cygwin port of make, but I believe that the backslashes are not being interpreted correctly. Personally if I were you I'd rename these files so they didn't contain any special characters at all, such as parenthesis.

If you can't do that, then you should switch to quoting to escape them, rather than backslashes. So, change instances of DaqInTesteing\(New\)Out.c to 'DaqInTesteing(New)Out.c' (using single quotes around the word instead of backslashes to quote the special characters).

I'm assuming that the odd spelling DaqInTesteing, rather than DaqInTesting, is intentional.

If these things don't help we'll need to see the part of the makefile which is responsible for building these targets.

于 2013-10-17T23:02:15.720 回答