1 1.2.8.1 thorpej /* $NetBSD: cdefs.h,v 1.2.8.1 1997/10/22 06:16:44 thorpej Exp $ */ 2 1.1 ws 3 1.1 ws #ifndef _MACHINE_CDEFS_H_ 4 1.1 ws #define _MACHINE_CDEFS_H_ 5 1.1 ws 6 1.2 thorpej #define _C_LABEL(x) _STRING(x) 7 1.2.8.1 thorpej 8 1.2.8.1 thorpej #ifdef __GNUC__ 9 1.2.8.1 thorpej #define __RENAME(x) __asm__(x) 10 1.2.8.1 thorpej #endif 11 1.2 thorpej 12 1.2 thorpej #define __DO_NOT_DO_WEAK__ /* NO WEAK SYMS IN LIBC YET */ 13 1.2 thorpej 14 1.2 thorpej #ifndef __DO_NOT_DO_WEAK__ 15 1.2 thorpej #define __indr_reference(sym, alias) /* use weak symbols instead */ 16 1.1 ws #endif 17 1.1 ws 18 1.2 thorpej #ifdef __STDC__ 19 1.2 thorpej 20 1.2 thorpej #ifndef __DO_NOT_DO_WEAK__ 21 1.2 thorpej #define __weak_alias(alias, sym) \ 22 1.2 thorpej __asm__(".weak " #alias " ; " #alias " = " #sym) 23 1.1 ws #endif 24 1.2 thorpej 25 1.2 thorpej #define __warn_references(sym, msg) \ 26 1.2 thorpej __asm__(".section .gnu.warning." #sym " ; .ascii \"" msg "\" ; .text") 27 1.2 thorpej 28 1.2 thorpej #else /* ! __STDC__ */ 29 1.2 thorpej 30 1.2 thorpej #ifndef __DO_NOT_DO_WEAK__ 31 1.2 thorpej #define __weak_alias(alias, sym) \ 32 1.2 thorpej __asm__(".weak alias ; alias = sym") 33 1.1 ws #endif 34 1.2 thorpej 35 1.2 thorpej #define __warn_references(sym, msg) \ 36 1.2 thorpej __asm__(".section .gnu.warning.sym ; .ascii msg ; .text") 37 1.2 thorpej 38 1.2 thorpej #endif /* __STDC__ */ 39 1.1 ws 40 1.1 ws #endif /* !_MACHINE_CDEFS_H_ */ 41