Gcc complains sigcontext structures in files /usr/include/bits/sigcontext.h and /usr/include/asm-sparc/sigcontext.h, although the structure is defined identically in both files. Hence, I just added: #ifndef #define around sigcontext structure in /usr/include/bits/sigcontext.h. And in /usr/include/asm-sparc/sigcontext.h, I added #ifndef , to make sure that only struct from one of the 2 file's is getting included.