Clang не компилирует простой файл c - PullRequest
1 голос
/ 24 февраля 2012

Я только что установил clang в cygwin: clang версии 3.1 (транк 151024) TargetL i386-pc-cygwin Модель потока: posix

Однако при попытке скомпилировать простой файл c (только основной)произошла ошибка:

clang version 3.1 (trunk 151024)
Target: i386-pc-cygwin
Thread model: posix
 "/usr/local/bin/clang" -cc1 -triple i386-pc-cygwin -S -disable-free -main-file-name t.c -mrelocation-model static -mdisable-fp-elim -mconstructor-aliases -target-cpu pentium4 -momit-leaf-frame-pointer -v -resource-dir /usr/local/bin/../lib/clang/3.1 -fmodule-cache-path /var/tmp/clang-module-cache -fno-dwarf-directory-asm -fdebug-compilation-dir /toolchain4 -ferror-limit 19 -fmessage-length 0 -mstackrealign -fno-use-cxa-atexit -fgnu-runtime -fobjc-runtime-has-arc -fobjc-runtime-has-weak -fobjc-fragile-abi -fdiagnostics-show-option -o /cygdrive/c/Users/Br0ther/AppData/Local/Temp/t-zyOz8h.s -x c t.c
clang: error: unable to execute command: Program could not be executed
clang: error: clang frontend command failed due to signal (use -v to see invocation)
clang: note: diagnostic msg: Please submit a bug report to http://llvm.org/bugs/ and include command line arguments and all diagnostic information.
clang: error: unable to execute command: Program could not be executed
clang: note: diagnostic msg: Error generating preprocessed source(s).

Любое тело знает, что является причиной проблемы?Я понятия не имею, что означает сообщение:

clang: error: unable to execute command: Program could not be executed
clang: error: clang frontend command failed due to signal (use -v to see invocation)

Ваша помощь очень ценится NK

Ответы [ 2 ]

1 голос
/ 29 февраля 2012

Спасибо за все предложения. Тем не менее проблема устранена путем увеличения размера кучи cygwin.

Спасибо

1 голос
/ 24 февраля 2012

Если эти две строки вас беспокоят:

clang: error: unable to execute command: Program could not be executed
clang: error: clang frontend command failed due to signal
    (use -v to see invocation)

тогда я могу предложить вам (как предложено в сообщении об ошибке) изменить вашу команду, чтобы увидеть строку вызова, которую она использует:

"/usr/local/bin/clang" -v -cc1 -triple i386-pc-cygwin ...

Тогда вы узнаете название программы и сможете выяснить, почему она не находится на вашем пути (например).

...