avr-llvm / clang

[MERGED UPSTREAM] Clang frontend supporting AVR
Other
11 stars 1 forks source link

TableGen.cpp:244:37: error: too few arguments to function call #11

Closed Crazor closed 8 years ago

Crazor commented 8 years ago

I'm compiling avr-llvm (06faf0a) as per the wiki, with clang (ee44fb6) checked out into the tools/ folder. I'm compiling on OS X 10.11.6 with Xcode 7.3.1. make stops with the following message:

[ 67%] Building CXX object tools/clang/utils/TableGen/CMakeFiles/obj.clang-tblgen.dir/TableGen.cpp.o /Users/crazor/llvm/tools/clang/utils/TableGen/TableGen.cpp:244:37: error: too few arguments to function call, at least argument 'Argv0' must be specified sys::PrintStackTraceOnErrorSignal();

/Users/crazor/llvm/include/llvm/Support/Signals.h:47:3: note: 'PrintStackTraceOnErrorSignal'
      declared here
  void PrintStackTraceOnErrorSignal(StringRef Argv0,
  ^
1 error generated.
make[2]: *** [tools/clang/utils/TableGen/CMakeFiles/obj.clang-tblgen.dir/TableGen.cpp.o] Error 1
make[1]: *** [tools/clang/utils/TableGen/CMakeFiles/obj.clang-tblgen.dir/all] Error 2
make: *** [all] Error 2
6,08s user 3,71s system 91% cpu 10,667s total
Asher- commented 8 years ago

Similar experience here. That error can be resolved by adding StringRef() as a single argument for the call to PrintStackTraceOnErrorSignal.

Then an error occurs in tools/clang/lib/CodeGen/CGBuiltin.cpp for symbols r600_rsq and AMDGPU_ldexp. Commenting out the legacy AMD section resolves the error (but obviously isn't a general solution).

Then an error occurs in tools/clang/lib/CodeGen/CGClass.cpp for llvm::Intrinsic::bitset_test, which does not appear to be defined anywhere. Presumably this is because of a version mismatch related to merging from upstream, as llvm/clang trunk compiles without problem but does not contain any reference to llvm::Intrinsic::bitset_test or the functions in CGClass.cpp that refer to llvm::Intrinsic::bitset_test.

Not sure where to go from there.

dylanmckay commented 8 years ago

Should be able to be fixed by updating LLVM+clang, I'll do that tonight.

RadhikaG commented 8 years ago

Similar experience here as well. I came up with a few hacky solutions to try and get the build working, but was stumped at the llvm::Intrinsic part too.

dylanmckay commented 8 years ago

Updated LLVM and Clang, build went fine on my local machine :)

Asher- commented 8 years ago

New issues with Xcode 8.

See: https://github.com/avr-llvm/clang/issues/12

Crazor commented 8 years ago

Could build on 10.11.6 with Xcode 8 today.

Am Donnerstag, 15. September 2016 schrieb Asher :

New issues with Xcode 8.

See: #12 https://github.com/avr-llvm/clang/issues/12

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/avr-llvm/clang/issues/11#issuecomment-247419304, or mute the thread https://github.com/notifications/unsubscribe-auth/AAH1JwlOw9zcLfruxOFYpwwNnJgajMr5ks5qqZUKgaJpZM4Jt31I .

Asher- commented 8 years ago

Any suggestions for what to try?

Asher- commented 8 years ago

For some reason, git pull for clang had not properly updated. Trying again now, I'm guessing it will work. Will report back.

Asher- commented 8 years ago

That was the problem. Success!

RadhikaG commented 8 years ago

@dylanmckay thank you very much!

After successfully completing at 100%, the build somehow generates an empty clang-4.0 executable, and no clang executable at all in llvm/build/bin. Would any of you have an idea why? I'm on Linux, if that's any help.

dylanmckay commented 8 years ago

What happens when you delete the executable and run make again @RadhikaG?

RadhikaG commented 8 years ago

Worked like a charm, thanks!