summaryrefslogtreecommitdiff
path: root/debian/patches/sys-auxv-header.diff
blob: 1c4f598c97d96ad8ed7839ab04b2fe1ee3612f03 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
# DP: Check for the sys/auxv.h header file.

Index: b/src/gcc/configure.ac
===================================================================
--- a/src/gcc/configure.ac
+++ b/src/gcc/configure.ac
@@ -942,6 +942,7 @@ AC_HEADER_SYS_WAIT
 AC_CHECK_HEADERS(limits.h stddef.h string.h strings.h stdlib.h time.h iconv.h \
 		 fcntl.h unistd.h sys/file.h sys/time.h sys/mman.h \
 		 sys/resource.h sys/param.h sys/times.h sys/stat.h \
+		 sys/auxv.h \
 		 direct.h malloc.h langinfo.h ldfcn.h locale.h wchar.h)
 
 # Check for thread headers.
Index: b/src/gcc/config.in
===================================================================
--- a/src/gcc/config.in
+++ b/src/gcc/config.in
@@ -1452,6 +1452,12 @@
 #endif
 
 
+/* Define to 1 if you have the <sys/auxv.h> header file. */
+#ifndef USED_FOR_TARGET
+#undef HAVE_SYS_AUXV_H
+#endif
+
+
 /* Define to 1 if you have the <sys/file.h> header file. */
 #ifndef USED_FOR_TARGET
 #undef HAVE_SYS_FILE_H
Index: b/src/gcc/config/rs6000/driver-rs6000.c
===================================================================
--- a/src/gcc/config/rs6000/driver-rs6000.c
+++ b/src/gcc/config/rs6000/driver-rs6000.c
@@ -31,6 +31,10 @@ along with GCC; see the file COPYING3.
 # include <link.h>
 #endif
 
+#ifdef HAVE_SYS_AUXV_H
+# include <sys/auxv.h>
+#endif
+
 #if defined (__APPLE__) || (__FreeBSD__)
 # include <sys/types.h>
 # include <sys/sysctl.h>