summaryrefslogtreecommitdiff
path: root/libc/sysdeps/linux
diff options
context:
space:
mode:
authorDavid McCullough <davidm@snapgear.com>2001-07-11 13:47:45 +0000
committerDavid McCullough <davidm@snapgear.com>2001-07-11 13:47:45 +0000
commitce8ee8d9b401c9c2828df3457815c2f4ceed4900 (patch)
treefc27874f9403ddfd24357f56d87d6ffe08d8ae19 /libc/sysdeps/linux
parent5882811b88767f26c75913ca2b2fffd05595a7b5 (diff)
Added __BEGIN_DECLS and __END_DECLS to the files that didn't have
it and that I could see needed it. Should be pretty low impact as these are only defined when using C++.
Diffstat (limited to 'libc/sysdeps/linux')
-rw-r--r--libc/sysdeps/linux/arm/bits/dlfcn.h2
-rw-r--r--libc/sysdeps/linux/arm/bits/errno.h2
-rw-r--r--libc/sysdeps/linux/arm/bits/mathcalls.h4
-rw-r--r--libc/sysdeps/linux/arm/bits/sigset.h4
-rw-r--r--libc/sysdeps/linux/arm/bits/sigthread.h4
-rw-r--r--libc/sysdeps/linux/arm/bits/sockaddr.h3
-rw-r--r--libc/sysdeps/linux/i386/bits/cmathcalls.h3
-rw-r--r--libc/sysdeps/linux/i386/bits/errno.h4
-rw-r--r--libc/sysdeps/linux/i386/bits/mathcalls.h3
-rw-r--r--libc/sysdeps/linux/i386/bits/sigset.h3
-rw-r--r--libc/sysdeps/linux/i386/bits/sigthread.h4
-rw-r--r--libc/sysdeps/linux/i386/bits/sockaddr.h3
-rw-r--r--libc/sysdeps/linux/m68k/bits/cmathcalls.h4
-rw-r--r--libc/sysdeps/linux/m68k/bits/errno.h4
-rw-r--r--libc/sysdeps/linux/m68k/bits/setjmp.h2
-rw-r--r--libc/sysdeps/linux/m68k/bits/sigthread.h4
-rw-r--r--libc/sysdeps/linux/m68k/bits/sockaddr.h3
-rw-r--r--libc/sysdeps/linux/m68k/bits/socket.h2
-rw-r--r--libc/sysdeps/linux/mips/bits/cmathcalls.h3
-rw-r--r--libc/sysdeps/linux/mips/bits/dlfcn.h2
-rw-r--r--libc/sysdeps/linux/mips/bits/errno.h6
-rw-r--r--libc/sysdeps/linux/mips/bits/libc-lock.h3
-rw-r--r--libc/sysdeps/linux/mips/bits/sigset.h3
-rw-r--r--libc/sysdeps/linux/mips/bits/sigthread.h4
-rw-r--r--libc/sysdeps/linux/powerpc/bits/dlfcn.h2
-rw-r--r--libc/sysdeps/linux/powerpc/bits/errno.h6
-rw-r--r--libc/sysdeps/linux/powerpc/bits/sigset.h3
-rw-r--r--libc/sysdeps/linux/powerpc/bits/sigthread.h4
-rw-r--r--libc/sysdeps/linux/powerpc/bits/sockaddr.h3
-rw-r--r--libc/sysdeps/linux/sh/bits/cmathcalls.h3
-rw-r--r--libc/sysdeps/linux/sh/bits/errno.h6
-rw-r--r--libc/sysdeps/linux/sh/bits/sigset.h3
-rw-r--r--libc/sysdeps/linux/sh/bits/sigthread.h4
-rw-r--r--libc/sysdeps/linux/sh/bits/sockaddr.h3
-rw-r--r--libc/sysdeps/linux/sparc/bits/cmathcalls.h3
-rw-r--r--libc/sysdeps/linux/sparc/bits/errno.h6
-rw-r--r--libc/sysdeps/linux/sparc/bits/sigset.h3
-rw-r--r--libc/sysdeps/linux/sparc/bits/sigthread.h4
-rw-r--r--libc/sysdeps/linux/sparc/bits/sockaddr.h3
39 files changed, 133 insertions, 2 deletions
diff --git a/libc/sysdeps/linux/arm/bits/dlfcn.h b/libc/sysdeps/linux/arm/bits/dlfcn.h
index 0039eda14..f724d0fdf 100644
--- a/libc/sysdeps/linux/arm/bits/dlfcn.h
+++ b/libc/sysdeps/linux/arm/bits/dlfcn.h
@@ -55,5 +55,7 @@
(_dl_mcount_wrapper_check (fctp), (*(fctp)) args)
/* This function calls the profiling functions. */
+__BEGIN_DECLS
extern void _dl_mcount_wrapper_check (void *__selfpc) __THROW;
+__END_DECLS
#endif
diff --git a/libc/sysdeps/linux/arm/bits/errno.h b/libc/sysdeps/linux/arm/bits/errno.h
index 0c33c9c0a..ba3049599 100644
--- a/libc/sysdeps/linux/arm/bits/errno.h
+++ b/libc/sysdeps/linux/arm/bits/errno.h
@@ -32,6 +32,7 @@
# define ECANCELED 125
# ifndef __ASSEMBLER__
+ __BEGIN_DECLS
/* We now need a declaration of the `errno' variable. */
extern int errno;
@@ -47,6 +48,7 @@ extern int *__errno_location (void) __attribute__ ((__const__));
/* When using threads, errno is a per-thread value. */
# define errno (*__errno_location ())
# endif
+ __END_DECLS
# endif /* !__ASSEMBLER__ */
#endif /* _ERRNO_H */
diff --git a/libc/sysdeps/linux/arm/bits/mathcalls.h b/libc/sysdeps/linux/arm/bits/mathcalls.h
index 9334e7fa4..a3ab88785 100644
--- a/libc/sysdeps/linux/arm/bits/mathcalls.h
+++ b/libc/sysdeps/linux/arm/bits/mathcalls.h
@@ -48,6 +48,7 @@
#endif
+__BEGIN_DECLS
/* Trigonometric functions. */
/* Arc cosine of X. */
@@ -338,4 +339,7 @@ __MATHDECL_1 (int, __signbit,, (_Mdouble_ __value))
/* Multiply-add function computed as a ternary operation. */
__MATHCALL (fma,, (_Mdouble_ __x, _Mdouble_ __y, _Mdouble_ __z));
+
#endif /* Use ISO C99. */
+
+__END_DECLS
diff --git a/libc/sysdeps/linux/arm/bits/sigset.h b/libc/sysdeps/linux/arm/bits/sigset.h
index 66a9c51c5..0c751af50 100644
--- a/libc/sysdeps/linux/arm/bits/sigset.h
+++ b/libc/sysdeps/linux/arm/bits/sigset.h
@@ -32,7 +32,6 @@ typedef struct
#endif
-
/* We only want to define these functions if <signal.h> was actually
included; otherwise we were included just to define the types. Since we
are namespace-clean, it wouldn't hurt to define extra macros. But
@@ -97,6 +96,8 @@ typedef struct
# endif
# endif
+__BEGIN_DECLS
+
/* These functions needn't check for a bogus signal number -- error
checking is done in the non __ versions. */
@@ -121,5 +122,6 @@ __SIGSETFN (__sigdelset, ((__set->__val[__word] &= ~__mask), 0), )
# undef __SIGSETFN
# endif
+__END_DECLS
#endif /* ! _SIGSET_H_fns. */
diff --git a/libc/sysdeps/linux/arm/bits/sigthread.h b/libc/sysdeps/linux/arm/bits/sigthread.h
index c9b1dcf1b..c213614be 100644
--- a/libc/sysdeps/linux/arm/bits/sigthread.h
+++ b/libc/sysdeps/linux/arm/bits/sigthread.h
@@ -24,6 +24,8 @@
# error "Never include this file directly. Use <pthread.h> instead"
#endif
+__BEGIN_DECLS
+
/* Functions for handling signals. */
/* Modify the signal mask for the calling thread. The arguments have
@@ -34,4 +36,6 @@ extern int pthread_sigmask __P ((int __how, __const __sigset_t *__newmask,
/* Send signal SIGNO to the given thread. */
extern int pthread_kill __P ((pthread_t __thread, int __signo));
+__END_DECLS
+
#endif /* bits/sigthread.h */
diff --git a/libc/sysdeps/linux/arm/bits/sockaddr.h b/libc/sysdeps/linux/arm/bits/sockaddr.h
index 1c523444b..8078963a8 100644
--- a/libc/sysdeps/linux/arm/bits/sockaddr.h
+++ b/libc/sysdeps/linux/arm/bits/sockaddr.h
@@ -24,6 +24,7 @@
#ifndef _BITS_SOCKADDR_H
#define _BITS_SOCKADDR_H 1
+__BEGIN_DECLS
/* POSIX.1g specifies this type name for the `sa_family' member. */
typedef unsigned short int sa_family_t;
@@ -41,4 +42,6 @@ typedef unsigned short int sa_family_t;
#define SA_LEN(_x) __libc_sa_len((_x)->sa_family)
extern int __libc_sa_len __P ((sa_family_t __af));
+__END_DECLS
+
#endif /* bits/sockaddr.h */
diff --git a/libc/sysdeps/linux/i386/bits/cmathcalls.h b/libc/sysdeps/linux/i386/bits/cmathcalls.h
index f063042b0..c1b0781b0 100644
--- a/libc/sysdeps/linux/i386/bits/cmathcalls.h
+++ b/libc/sysdeps/linux/i386/bits/cmathcalls.h
@@ -47,6 +47,7 @@
#define _Mdouble_complex_ _Mdouble_ _Complex
+__BEGIN_DECLS
/* Trigonometric functions. */
@@ -155,3 +156,5 @@ __MATH_PRECNAME(conj) (_Mdouble_complex_ __z)
}
#endif
+
+__END_DECLS
diff --git a/libc/sysdeps/linux/i386/bits/errno.h b/libc/sysdeps/linux/i386/bits/errno.h
index 35bd61109..992358eb7 100644
--- a/libc/sysdeps/linux/i386/bits/errno.h
+++ b/libc/sysdeps/linux/i386/bits/errno.h
@@ -24,6 +24,8 @@
# undef ERANGE
# include <linux/errno.h>
+__BEGIN_DECLS
+
/* Linux has no ENOTSUP error code. */
# define ENOTSUP EOPNOTSUPP
@@ -50,6 +52,8 @@ extern int *__errno_location __P ((void)) __attribute__ ((__const__));
# endif /* !__ASSEMBLER__ */
#endif /* _ERRNO_H */
+__END_DECLS
+
#if !defined _ERRNO_H && defined __need_Emath
/* This is ugly but the kernel header is not clean enough. We must
define only the values EDOM and ERANGE in case __need_Emath is
diff --git a/libc/sysdeps/linux/i386/bits/mathcalls.h b/libc/sysdeps/linux/i386/bits/mathcalls.h
index 97bda451a..f261ace0f 100644
--- a/libc/sysdeps/linux/i386/bits/mathcalls.h
+++ b/libc/sysdeps/linux/i386/bits/mathcalls.h
@@ -47,6 +47,7 @@
#error "Never include <bits/mathcalls.h> directly; include <math.h> instead."
#endif
+__BEGIN_DECLS
/* Trigonometric functions. */
@@ -334,3 +335,5 @@ __MATHDECL_1 (int, __signbit,, (_Mdouble_ __value))
/* Multiply-add function computed as a ternary operation. */
__MATHCALL (fma,, (_Mdouble_ __x, _Mdouble_ __y, _Mdouble_ __z));
#endif /* Use ISO C 9X. */
+
+__END_DECLS
diff --git a/libc/sysdeps/linux/i386/bits/sigset.h b/libc/sysdeps/linux/i386/bits/sigset.h
index 66a9c51c5..de852a8a0 100644
--- a/libc/sysdeps/linux/i386/bits/sigset.h
+++ b/libc/sysdeps/linux/i386/bits/sigset.h
@@ -97,6 +97,8 @@ typedef struct
# endif
# endif
+__BEGIN_DECLS
+
/* These functions needn't check for a bogus signal number -- error
checking is done in the non __ versions. */
@@ -121,5 +123,6 @@ __SIGSETFN (__sigdelset, ((__set->__val[__word] &= ~__mask), 0), )
# undef __SIGSETFN
# endif
+__END_DECLS
#endif /* ! _SIGSET_H_fns. */
diff --git a/libc/sysdeps/linux/i386/bits/sigthread.h b/libc/sysdeps/linux/i386/bits/sigthread.h
index c9b1dcf1b..a63319c52 100644
--- a/libc/sysdeps/linux/i386/bits/sigthread.h
+++ b/libc/sysdeps/linux/i386/bits/sigthread.h
@@ -26,6 +26,8 @@
/* Functions for handling signals. */
+__BEGIN_DECLS
+
/* Modify the signal mask for the calling thread. The arguments have
the same meaning as for sigprocmask(2). */
extern int pthread_sigmask __P ((int __how, __const __sigset_t *__newmask,
@@ -34,4 +36,6 @@ extern int pthread_sigmask __P ((int __how, __const __sigset_t *__newmask,
/* Send signal SIGNO to the given thread. */
extern int pthread_kill __P ((pthread_t __thread, int __signo));
+__END_DECLS
+
#endif /* bits/sigthread.h */
diff --git a/libc/sysdeps/linux/i386/bits/sockaddr.h b/libc/sysdeps/linux/i386/bits/sockaddr.h
index 1c523444b..1cddab4d8 100644
--- a/libc/sysdeps/linux/i386/bits/sockaddr.h
+++ b/libc/sysdeps/linux/i386/bits/sockaddr.h
@@ -24,6 +24,7 @@
#ifndef _BITS_SOCKADDR_H
#define _BITS_SOCKADDR_H 1
+__BEGIN_DECLS
/* POSIX.1g specifies this type name for the `sa_family' member. */
typedef unsigned short int sa_family_t;
@@ -39,6 +40,8 @@ typedef unsigned short int sa_family_t;
/* Return the length of a `sockaddr' structure. */
#define SA_LEN(_x) __libc_sa_len((_x)->sa_family)
+
extern int __libc_sa_len __P ((sa_family_t __af));
+__END_DECLS
#endif /* bits/sockaddr.h */
diff --git a/libc/sysdeps/linux/m68k/bits/cmathcalls.h b/libc/sysdeps/linux/m68k/bits/cmathcalls.h
index f063042b0..842d2c135 100644
--- a/libc/sysdeps/linux/m68k/bits/cmathcalls.h
+++ b/libc/sysdeps/linux/m68k/bits/cmathcalls.h
@@ -47,6 +47,7 @@
#define _Mdouble_complex_ _Mdouble_ _Complex
+__BEGIN_DECLS
/* Trigonometric functions. */
@@ -153,5 +154,6 @@ __MATH_PRECNAME(conj) (_Mdouble_complex_ __z)
{
return ~__z;
}
-
#endif
+
+__END_DECLS
diff --git a/libc/sysdeps/linux/m68k/bits/errno.h b/libc/sysdeps/linux/m68k/bits/errno.h
index 35bd61109..7a0bd8150 100644
--- a/libc/sysdeps/linux/m68k/bits/errno.h
+++ b/libc/sysdeps/linux/m68k/bits/errno.h
@@ -24,6 +24,8 @@
# undef ERANGE
# include <linux/errno.h>
+__BEGIN_DECLS
+
/* Linux has no ENOTSUP error code. */
# define ENOTSUP EOPNOTSUPP
@@ -58,3 +60,5 @@ extern int *__errno_location __P ((void)) __attribute__ ((__const__));
# define EILSEQ 84 /* Illegal byte sequence. */
# define ERANGE 34 /* Math result not representable. */
#endif /* !_ERRNO_H && __need_Emath */
+
+__END_DECLS
diff --git a/libc/sysdeps/linux/m68k/bits/setjmp.h b/libc/sysdeps/linux/m68k/bits/setjmp.h
index 5680ffe04..08b2d2500 100644
--- a/libc/sysdeps/linux/m68k/bits/setjmp.h
+++ b/libc/sysdeps/linux/m68k/bits/setjmp.h
@@ -49,8 +49,10 @@ typedef struct
/* Simple version of sigsetjmp and siglongjmp */
+__BEGIN_DECLS
extern int __setjmp(__jmp_buf __buf);
extern int __longjmp(__jmp_buf __buf, int __val);
+__END_DECLS
#define longjmp(buf, val) __longjmp(buf, val)
diff --git a/libc/sysdeps/linux/m68k/bits/sigthread.h b/libc/sysdeps/linux/m68k/bits/sigthread.h
index c9b1dcf1b..c213614be 100644
--- a/libc/sysdeps/linux/m68k/bits/sigthread.h
+++ b/libc/sysdeps/linux/m68k/bits/sigthread.h
@@ -24,6 +24,8 @@
# error "Never include this file directly. Use <pthread.h> instead"
#endif
+__BEGIN_DECLS
+
/* Functions for handling signals. */
/* Modify the signal mask for the calling thread. The arguments have
@@ -34,4 +36,6 @@ extern int pthread_sigmask __P ((int __how, __const __sigset_t *__newmask,
/* Send signal SIGNO to the given thread. */
extern int pthread_kill __P ((pthread_t __thread, int __signo));
+__END_DECLS
+
#endif /* bits/sigthread.h */
diff --git a/libc/sysdeps/linux/m68k/bits/sockaddr.h b/libc/sysdeps/linux/m68k/bits/sockaddr.h
index 1c523444b..8078963a8 100644
--- a/libc/sysdeps/linux/m68k/bits/sockaddr.h
+++ b/libc/sysdeps/linux/m68k/bits/sockaddr.h
@@ -24,6 +24,7 @@
#ifndef _BITS_SOCKADDR_H
#define _BITS_SOCKADDR_H 1
+__BEGIN_DECLS
/* POSIX.1g specifies this type name for the `sa_family' member. */
typedef unsigned short int sa_family_t;
@@ -41,4 +42,6 @@ typedef unsigned short int sa_family_t;
#define SA_LEN(_x) __libc_sa_len((_x)->sa_family)
extern int __libc_sa_len __P ((sa_family_t __af));
+__END_DECLS
+
#endif /* bits/sockaddr.h */
diff --git a/libc/sysdeps/linux/m68k/bits/socket.h b/libc/sysdeps/linux/m68k/bits/socket.h
index dc2d58cfc..a4b090e2b 100644
--- a/libc/sysdeps/linux/m68k/bits/socket.h
+++ b/libc/sysdeps/linux/m68k/bits/socket.h
@@ -244,8 +244,10 @@ struct cmsghdr
+ CMSG_ALIGN (sizeof (struct cmsghdr)))
#define CMSG_LEN(len) (CMSG_ALIGN (sizeof (struct cmsghdr)) + (len))
+__BEGIN_DECLS
extern struct cmsghdr *__cmsg_nxthdr __P ((struct msghdr *__mhdr,
struct cmsghdr *__cmsg));
+__END_DECLS
#ifdef __USE_EXTERN_INLINES
# ifndef _EXTERN_INLINE
# define _EXTERN_INLINE extern __inline
diff --git a/libc/sysdeps/linux/mips/bits/cmathcalls.h b/libc/sysdeps/linux/mips/bits/cmathcalls.h
index 2d186c41e..6679500be 100644
--- a/libc/sysdeps/linux/mips/bits/cmathcalls.h
+++ b/libc/sysdeps/linux/mips/bits/cmathcalls.h
@@ -47,6 +47,7 @@
#define _Mdouble_complex_ _Mdouble_ _Complex
+__BEGIN_DECLS
/* Trigonometric functions. */
@@ -156,3 +157,5 @@ __MATH_PRECNAME(conj) (_Mdouble_complex_ __z) __THROW
}
#endif
+
+__END_DECLS
diff --git a/libc/sysdeps/linux/mips/bits/dlfcn.h b/libc/sysdeps/linux/mips/bits/dlfcn.h
index 006eeb683..21aac6542 100644
--- a/libc/sysdeps/linux/mips/bits/dlfcn.h
+++ b/libc/sysdeps/linux/mips/bits/dlfcn.h
@@ -54,6 +54,8 @@
# define DL_CALL_FCT(fctp, args) \
(_dl_mcount_wrapper_check (fctp), (*(fctp)) args)
+__BEGIN_DECLS
/* This function calls the profiling functions. */
extern void _dl_mcount_wrapper_check (void *__selfpc) __THROW;
+__END_DECLS
#endif
diff --git a/libc/sysdeps/linux/mips/bits/errno.h b/libc/sysdeps/linux/mips/bits/errno.h
index e0c1dc5c6..53db5dd7b 100644
--- a/libc/sysdeps/linux/mips/bits/errno.h
+++ b/libc/sysdeps/linux/mips/bits/errno.h
@@ -28,6 +28,9 @@
# define ENOTSUP EOPNOTSUPP
# ifndef __ASSEMBLER__
+
+__BEGIN_DECLS
+
/* We now need a declaration of the `errno' variable. */
extern int errno;
@@ -43,6 +46,9 @@ extern int *__errno_location (void);
/* When using threads, errno is a per-thread value. */
# define errno (*__errno_location ())
# endif
+
+__END_DECLS
+
# endif /* !__ASSEMBLER__ */
#endif /* _ERRNO_H */
diff --git a/libc/sysdeps/linux/mips/bits/libc-lock.h b/libc/sysdeps/linux/mips/bits/libc-lock.h
index dbd9cc14f..fa43d4839 100644
--- a/libc/sysdeps/linux/mips/bits/libc-lock.h
+++ b/libc/sysdeps/linux/mips/bits/libc-lock.h
@@ -200,6 +200,8 @@ typedef pthread_key_t __libc_key_t;
/* Functions that are used by this file and are internal to the GNU C
library. */
+__BEGIN_DECLS
+
extern int __pthread_mutex_init (pthread_mutex_t *__mutex,
__const pthread_mutexattr_t *__mutex_attr);
@@ -250,6 +252,7 @@ extern int __pthread_atfork (void (*__prepare) (void),
void (*__parent) (void),
void (*__child) (void));
+__END_DECLS
/* Make the pthread functions weak so that we can elide them from
diff --git a/libc/sysdeps/linux/mips/bits/sigset.h b/libc/sysdeps/linux/mips/bits/sigset.h
index 66a9c51c5..de852a8a0 100644
--- a/libc/sysdeps/linux/mips/bits/sigset.h
+++ b/libc/sysdeps/linux/mips/bits/sigset.h
@@ -97,6 +97,8 @@ typedef struct
# endif
# endif
+__BEGIN_DECLS
+
/* These functions needn't check for a bogus signal number -- error
checking is done in the non __ versions. */
@@ -121,5 +123,6 @@ __SIGSETFN (__sigdelset, ((__set->__val[__word] &= ~__mask), 0), )
# undef __SIGSETFN
# endif
+__END_DECLS
#endif /* ! _SIGSET_H_fns. */
diff --git a/libc/sysdeps/linux/mips/bits/sigthread.h b/libc/sysdeps/linux/mips/bits/sigthread.h
index b86e75f20..8ca688c59 100644
--- a/libc/sysdeps/linux/mips/bits/sigthread.h
+++ b/libc/sysdeps/linux/mips/bits/sigthread.h
@@ -24,6 +24,8 @@
# error "Never include this file directly. Use <pthread.h> instead"
#endif
+__BEGIN_DECLS
+
/* Functions for handling signals. */
/* Modify the signal mask for the calling thread. The arguments have
@@ -35,4 +37,6 @@ extern int pthread_sigmask (int __how,
/* Send signal SIGNO to the given thread. */
extern int pthread_kill (pthread_t __thread, int __signo) __THROW;
+__END_DECLS
+
#endif /* bits/sigthread.h */
diff --git a/libc/sysdeps/linux/powerpc/bits/dlfcn.h b/libc/sysdeps/linux/powerpc/bits/dlfcn.h
index 0039eda14..f724d0fdf 100644
--- a/libc/sysdeps/linux/powerpc/bits/dlfcn.h
+++ b/libc/sysdeps/linux/powerpc/bits/dlfcn.h
@@ -55,5 +55,7 @@
(_dl_mcount_wrapper_check (fctp), (*(fctp)) args)
/* This function calls the profiling functions. */
+__BEGIN_DECLS
extern void _dl_mcount_wrapper_check (void *__selfpc) __THROW;
+__END_DECLS
#endif
diff --git a/libc/sysdeps/linux/powerpc/bits/errno.h b/libc/sysdeps/linux/powerpc/bits/errno.h
index 7da7daf79..a5365caba 100644
--- a/libc/sysdeps/linux/powerpc/bits/errno.h
+++ b/libc/sysdeps/linux/powerpc/bits/errno.h
@@ -32,6 +32,9 @@
# define ECANCELED 125
# ifndef __ASSEMBLER__
+
+__BEGIN_DECLS
+
/* We now need a declaration of the `errno' variable. */
extern int errno;
@@ -47,6 +50,9 @@ extern int *__errno_location (void);
/* When using threads, errno is a per-thread value. */
# define errno (*__errno_location ())
# endif
+
+__END_DECLS
+
# endif /* !__ASSEMBLER__ */
#endif /* _ERRNO_H */
diff --git a/libc/sysdeps/linux/powerpc/bits/sigset.h b/libc/sysdeps/linux/powerpc/bits/sigset.h
index 66a9c51c5..de852a8a0 100644
--- a/libc/sysdeps/linux/powerpc/bits/sigset.h
+++ b/libc/sysdeps/linux/powerpc/bits/sigset.h
@@ -97,6 +97,8 @@ typedef struct
# endif
# endif
+__BEGIN_DECLS
+
/* These functions needn't check for a bogus signal number -- error
checking is done in the non __ versions. */
@@ -121,5 +123,6 @@ __SIGSETFN (__sigdelset, ((__set->__val[__word] &= ~__mask), 0), )
# undef __SIGSETFN
# endif
+__END_DECLS
#endif /* ! _SIGSET_H_fns. */
diff --git a/libc/sysdeps/linux/powerpc/bits/sigthread.h b/libc/sysdeps/linux/powerpc/bits/sigthread.h
index c9b1dcf1b..c213614be 100644
--- a/libc/sysdeps/linux/powerpc/bits/sigthread.h
+++ b/libc/sysdeps/linux/powerpc/bits/sigthread.h
@@ -24,6 +24,8 @@
# error "Never include this file directly. Use <pthread.h> instead"
#endif
+__BEGIN_DECLS
+
/* Functions for handling signals. */
/* Modify the signal mask for the calling thread. The arguments have
@@ -34,4 +36,6 @@ extern int pthread_sigmask __P ((int __how, __const __sigset_t *__newmask,
/* Send signal SIGNO to the given thread. */
extern int pthread_kill __P ((pthread_t __thread, int __signo));
+__END_DECLS
+
#endif /* bits/sigthread.h */
diff --git a/libc/sysdeps/linux/powerpc/bits/sockaddr.h b/libc/sysdeps/linux/powerpc/bits/sockaddr.h
index 1c523444b..8078963a8 100644
--- a/libc/sysdeps/linux/powerpc/bits/sockaddr.h
+++ b/libc/sysdeps/linux/powerpc/bits/sockaddr.h
@@ -24,6 +24,7 @@
#ifndef _BITS_SOCKADDR_H
#define _BITS_SOCKADDR_H 1
+__BEGIN_DECLS
/* POSIX.1g specifies this type name for the `sa_family' member. */
typedef unsigned short int sa_family_t;
@@ -41,4 +42,6 @@ typedef unsigned short int sa_family_t;
#define SA_LEN(_x) __libc_sa_len((_x)->sa_family)
extern int __libc_sa_len __P ((sa_family_t __af));
+__END_DECLS
+
#endif /* bits/sockaddr.h */
diff --git a/libc/sysdeps/linux/sh/bits/cmathcalls.h b/libc/sysdeps/linux/sh/bits/cmathcalls.h
index f063042b0..c1b0781b0 100644
--- a/libc/sysdeps/linux/sh/bits/cmathcalls.h
+++ b/libc/sysdeps/linux/sh/bits/cmathcalls.h
@@ -47,6 +47,7 @@
#define _Mdouble_complex_ _Mdouble_ _Complex
+__BEGIN_DECLS
/* Trigonometric functions. */
@@ -155,3 +156,5 @@ __MATH_PRECNAME(conj) (_Mdouble_complex_ __z)
}
#endif
+
+__END_DECLS
diff --git a/libc/sysdeps/linux/sh/bits/errno.h b/libc/sysdeps/linux/sh/bits/errno.h
index 35bd61109..968e178ea 100644
--- a/libc/sysdeps/linux/sh/bits/errno.h
+++ b/libc/sysdeps/linux/sh/bits/errno.h
@@ -32,6 +32,9 @@
# define ECANCELED 125
# ifndef __ASSEMBLER__
+
+__BEGIN_DECLS
+
/* We now need a declaration of the `errno' variable. */
extern int errno;
@@ -47,6 +50,9 @@ extern int *__errno_location __P ((void)) __attribute__ ((__const__));
/* When using threads, errno is a per-thread value. */
# define errno (*__errno_location ())
# endif
+
+__END_DECLS
+
# endif /* !__ASSEMBLER__ */
#endif /* _ERRNO_H */
diff --git a/libc/sysdeps/linux/sh/bits/sigset.h b/libc/sysdeps/linux/sh/bits/sigset.h
index 66a9c51c5..de852a8a0 100644
--- a/libc/sysdeps/linux/sh/bits/sigset.h
+++ b/libc/sysdeps/linux/sh/bits/sigset.h
@@ -97,6 +97,8 @@ typedef struct
# endif
# endif
+__BEGIN_DECLS
+
/* These functions needn't check for a bogus signal number -- error
checking is done in the non __ versions. */
@@ -121,5 +123,6 @@ __SIGSETFN (__sigdelset, ((__set->__val[__word] &= ~__mask), 0), )
# undef __SIGSETFN
# endif
+__END_DECLS
#endif /* ! _SIGSET_H_fns. */
diff --git a/libc/sysdeps/linux/sh/bits/sigthread.h b/libc/sysdeps/linux/sh/bits/sigthread.h
index c9b1dcf1b..c213614be 100644
--- a/libc/sysdeps/linux/sh/bits/sigthread.h
+++ b/libc/sysdeps/linux/sh/bits/sigthread.h
@@ -24,6 +24,8 @@
# error "Never include this file directly. Use <pthread.h> instead"
#endif
+__BEGIN_DECLS
+
/* Functions for handling signals. */
/* Modify the signal mask for the calling thread. The arguments have
@@ -34,4 +36,6 @@ extern int pthread_sigmask __P ((int __how, __const __sigset_t *__newmask,
/* Send signal SIGNO to the given thread. */
extern int pthread_kill __P ((pthread_t __thread, int __signo));
+__END_DECLS
+
#endif /* bits/sigthread.h */
diff --git a/libc/sysdeps/linux/sh/bits/sockaddr.h b/libc/sysdeps/linux/sh/bits/sockaddr.h
index 1c523444b..8078963a8 100644
--- a/libc/sysdeps/linux/sh/bits/sockaddr.h
+++ b/libc/sysdeps/linux/sh/bits/sockaddr.h
@@ -24,6 +24,7 @@
#ifndef _BITS_SOCKADDR_H
#define _BITS_SOCKADDR_H 1
+__BEGIN_DECLS
/* POSIX.1g specifies this type name for the `sa_family' member. */
typedef unsigned short int sa_family_t;
@@ -41,4 +42,6 @@ typedef unsigned short int sa_family_t;
#define SA_LEN(_x) __libc_sa_len((_x)->sa_family)
extern int __libc_sa_len __P ((sa_family_t __af));
+__END_DECLS
+
#endif /* bits/sockaddr.h */
diff --git a/libc/sysdeps/linux/sparc/bits/cmathcalls.h b/libc/sysdeps/linux/sparc/bits/cmathcalls.h
index f063042b0..c1b0781b0 100644
--- a/libc/sysdeps/linux/sparc/bits/cmathcalls.h
+++ b/libc/sysdeps/linux/sparc/bits/cmathcalls.h
@@ -47,6 +47,7 @@
#define _Mdouble_complex_ _Mdouble_ _Complex
+__BEGIN_DECLS
/* Trigonometric functions. */
@@ -155,3 +156,5 @@ __MATH_PRECNAME(conj) (_Mdouble_complex_ __z)
}
#endif
+
+__END_DECLS
diff --git a/libc/sysdeps/linux/sparc/bits/errno.h b/libc/sysdeps/linux/sparc/bits/errno.h
index 35bd61109..968e178ea 100644
--- a/libc/sysdeps/linux/sparc/bits/errno.h
+++ b/libc/sysdeps/linux/sparc/bits/errno.h
@@ -32,6 +32,9 @@
# define ECANCELED 125
# ifndef __ASSEMBLER__
+
+__BEGIN_DECLS
+
/* We now need a declaration of the `errno' variable. */
extern int errno;
@@ -47,6 +50,9 @@ extern int *__errno_location __P ((void)) __attribute__ ((__const__));
/* When using threads, errno is a per-thread value. */
# define errno (*__errno_location ())
# endif
+
+__END_DECLS
+
# endif /* !__ASSEMBLER__ */
#endif /* _ERRNO_H */
diff --git a/libc/sysdeps/linux/sparc/bits/sigset.h b/libc/sysdeps/linux/sparc/bits/sigset.h
index 66a9c51c5..de852a8a0 100644
--- a/libc/sysdeps/linux/sparc/bits/sigset.h
+++ b/libc/sysdeps/linux/sparc/bits/sigset.h
@@ -97,6 +97,8 @@ typedef struct
# endif
# endif
+__BEGIN_DECLS
+
/* These functions needn't check for a bogus signal number -- error
checking is done in the non __ versions. */
@@ -121,5 +123,6 @@ __SIGSETFN (__sigdelset, ((__set->__val[__word] &= ~__mask), 0), )
# undef __SIGSETFN
# endif
+__END_DECLS
#endif /* ! _SIGSET_H_fns. */
diff --git a/libc/sysdeps/linux/sparc/bits/sigthread.h b/libc/sysdeps/linux/sparc/bits/sigthread.h
index c9b1dcf1b..c213614be 100644
--- a/libc/sysdeps/linux/sparc/bits/sigthread.h
+++ b/libc/sysdeps/linux/sparc/bits/sigthread.h
@@ -24,6 +24,8 @@
# error "Never include this file directly. Use <pthread.h> instead"
#endif
+__BEGIN_DECLS
+
/* Functions for handling signals. */
/* Modify the signal mask for the calling thread. The arguments have
@@ -34,4 +36,6 @@ extern int pthread_sigmask __P ((int __how, __const __sigset_t *__newmask,
/* Send signal SIGNO to the given thread. */
extern int pthread_kill __P ((pthread_t __thread, int __signo));
+__END_DECLS
+
#endif /* bits/sigthread.h */
diff --git a/libc/sysdeps/linux/sparc/bits/sockaddr.h b/libc/sysdeps/linux/sparc/bits/sockaddr.h
index 1c523444b..8078963a8 100644
--- a/libc/sysdeps/linux/sparc/bits/sockaddr.h
+++ b/libc/sysdeps/linux/sparc/bits/sockaddr.h
@@ -24,6 +24,7 @@
#ifndef _BITS_SOCKADDR_H
#define _BITS_SOCKADDR_H 1
+__BEGIN_DECLS
/* POSIX.1g specifies this type name for the `sa_family' member. */
typedef unsigned short int sa_family_t;
@@ -41,4 +42,6 @@ typedef unsigned short int sa_family_t;
#define SA_LEN(_x) __libc_sa_len((_x)->sa_family)
extern int __libc_sa_len __P ((sa_family_t __af));
+__END_DECLS
+
#endif /* bits/sockaddr.h */