On 04/17/17 05:10 PM, Waldemar Brodkorb wrote: > Hi developers, > > with Buildroot we have some compile issues when using uClibc-ng or > musl toolchains. The reason is the x86 specific code is using > deprecated sigreturn and setcontext functions. > > With the attached patch I could compile libunwind with the uClibc-ng > toolchain. > > But the best solution would be if the code would use a direct > syscall to rt_sigreturn as the x86_64 code does: > http://git.savannah.gnu.org/gitweb/?p=libunwind.git;a=blob;f=src/x86_64/Gos-linux.c;h=6f70d3ffdb1e514a567d0c2146c852765bda953d;hb=HEAD#l148 > > What do you think? > > I think sigreturn() is a noop in GNU C Library for x86 and x86_64.
The attached patch won't work - unw_getcontext/setcontext functions don't save/restore the signal mask. Normally we don't need to, except for signal return functions - which sigreturn does for us using the sigmask saved by the kernel. I agree the best fix would probably be to call the syscall directly as in the x86_64. Want to provide a patch to do that? Thanks _______________________________________________ Libunwind-devel mailing list [email protected] https://lists.nongnu.org/mailman/listinfo/libunwind-devel
