mirror of
https://github.com/tobast/libunwind-eh_elf.git
synced 2024-12-23 12:03:41 +01:00
libunwind-arm: fix build failure due to asm()
mesa3d on ARM build with libunwind support enabled fail to build due to asm() function used when building with -std=c99. The gcc documentation [1] suggest to use __asm__ instead of asm. Fixes: https://urldefense.proofpoint.com/v2/url?u=http-3A__autobuild.buildroot.net_results_3ef_3efe156b6494e4392b6c31de447ee2c72acc1a53&d=DwICAg&c=5VD0RTtNlTh3ycd41b3MUw&r=vou6lT5jmE_fWQWZZgNrsMWu4RT87QAB9V07tPHlP5U&m=BlAszRQ0vewy5vW7raCh9FmNOACKez_juz55zoiNfUs&s=4sXL6_rFriQz7qi5ygKXBIVHMc7YSdCBnkkHoi347CU&e= [1] https://gcc.gnu.org/onlinedocs/gcc/Alternate-Keywords.html#Alternate-Keywords Signed-off-by: Romain Naour <romain.naour@smile.fr> Cc: Bernd Kuhls <bernd.kuhls@t-online.de>
This commit is contained in:
parent
38b2bdab33
commit
ca6b6f3ad9
1 changed files with 2 additions and 2 deletions
|
@ -265,7 +265,7 @@ unw_tdep_context_t;
|
|||
#ifndef __thumb__
|
||||
#define unw_tdep_getcontext(uc) (({ \
|
||||
unw_tdep_context_t *unw_ctx = (uc); \
|
||||
register unsigned long *unw_base asm ("r0") = unw_ctx->regs; \
|
||||
register unsigned long *unw_base __asm__ ("r0") = unw_ctx->regs; \
|
||||
__asm__ __volatile__ ( \
|
||||
"stmia %[base], {r0-r15}" \
|
||||
: : [base] "r" (unw_base) : "memory"); \
|
||||
|
@ -273,7 +273,7 @@ unw_tdep_context_t;
|
|||
#else /* __thumb__ */
|
||||
#define unw_tdep_getcontext(uc) (({ \
|
||||
unw_tdep_context_t *unw_ctx = (uc); \
|
||||
register unsigned long *unw_base asm ("r0") = unw_ctx->regs; \
|
||||
register unsigned long *unw_base __asm__ ("r0") = unw_ctx->regs; \
|
||||
__asm__ __volatile__ ( \
|
||||
".align 2\nbx pc\nnop\n.code 32\n" \
|
||||
"stmia %[base], {r0-r15}\n" \
|
||||
|
|
Loading…
Reference in a new issue