Renato Golin via llvm-dev
2016-Nov-16 10:06 UTC
[llvm-dev] Clang 3.8 can't compile libunwind 3.9
Hi Logan, So, I just realised clang 3.8 comes with an unwind.h which doesn't have _URC_OK defined (introduced in r262178, just after 3.8 split). But on that commit, the personality routine depends on it for EHABI calls, which is defined by default on ARM environments. The end result is that I can only use Clang 3.9+ to compile libunwind 3.9+. http://buildmaster.tcwglab.linaro.org/builders/clang-cmake-armv7-a15-full/builds/1788/steps/build%20stage%201/logs/stdio compiler-rt/lib/builtins/gcc_personality_v0.c:149:57: error: use of undeclared identifier '_URC_OK'; did you mean '_UVRSR_OK'? if (__gnu_unwind_frame(exceptionObject, context) != _URC_OK) ^~~~~~~ Do we take this as an ABI break and document it? Or do we try to fix it? cheers, --renato
Joerg Sonnenberger via llvm-dev
2016-Nov-16 10:42 UTC
[llvm-dev] Clang 3.8 can't compile libunwind 3.9
On Wed, Nov 16, 2016 at 10:06:19AM +0000, Renato Golin via llvm-dev wrote:> Do we take this as an ABI break and document it? Or do we try to fix it?It is an API change. It doesn't involve the ABI. Joerg
Renato Golin via llvm-dev
2016-Nov-16 10:45 UTC
[llvm-dev] [cfe-dev] Clang 3.8 can't compile libunwind 3.9
On 16 November 2016 at 10:42, Joerg Sonnenberger via cfe-dev <cfe-dev at lists.llvm.org> wrote:> It is an API change. It doesn't involve the ABI.Right, that's what I meant, sorry. Just to make sure we're on the same page... If we treat this as an acceptable API change, we'll have to document. This will force people to bootstrap Clang (if using pre-3.9 for stage one), and only compile libunwind on stage 2. If we try to fix, there should be some #ifdef clang < 3.9 #define _URC_OK 0 #endif in the personality routine, or something similar. Unless there's a better fix... --renato