]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Add include guards to dl-procinfo.h
authorSiddhesh Poyarekar <siddhesh@sourceware.org>
Wed, 7 Jun 2017 05:23:49 +0000 (10:53 +0530)
committerSiddhesh Poyarekar <siddhesh@sourceware.org>
Wed, 7 Jun 2017 05:41:38 +0000 (11:11 +0530)
The dl-procinfo.h for linux/s390 and linux/i386 don't have include
guards, which causes them to fail since addition of LD_HWCAP_MASK to
tunables.  Add _DL_I386_PROCINFO_H guard to avoid redefining
_dl_procinfo on multiple includes and also allow the subsequent
include of another dl-procinfo.h to work.

Verified with a build test on i686.

* sysdeps/unix/sysv/linux/i386/dl-procinfo.h: Add include
guard.
* sysdeps/unix/sysv/linux/s390/dl-procinfo.h: Likewise.

ChangeLog
sysdeps/unix/sysv/linux/i386/dl-procinfo.h
sysdeps/unix/sysv/linux/s390/dl-procinfo.h

index 7a42c789323119ac2dea9ee56c225aabf39fb5e8..26393d59e8a5cc237cb00fb1ccd8b0b4357554f0 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2017-06-07  Siddhesh Poyarekar  <siddhesh@sourceware.org>
 
+       * sysdeps/unix/sysv/linux/i386/dl-procinfo.h: Add include
+       guard.
+       * sysdeps/unix/sysv/linux/s390/dl-procinfo.h: Likewise.
+
        * elf/dl-tunables.list: Add glibc.tune.hwcap_mask.
        * scripts/gen-tunables.awk: Include dl-procinfo.h.
        * manual/tunables.texi: Document glibc.tune.hwcap_mask.
index a3a5f9d2775f80dc37d64a301e6cc545560f4bab..c590896ddf39db935768412fe5f9dc7298229b91 100644 (file)
@@ -17,6 +17,8 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+#ifndef _DL_I386_PROCINFO_H
+#define _DL_I386_PROCINFO_H    1
 #include <sysdeps/x86/dl-procinfo.h>
 
 #undef _dl_procinfo
@@ -42,3 +44,4 @@ _dl_procinfo (unsigned int type, unsigned long int word)
 
   return 0;
 }
+#endif
index e75666310799ec1fbced199960b86de44b8402c4..7cbce0a04397c931f82cc4e4289cfbdec75c7bb4 100644 (file)
@@ -17,6 +17,8 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+#ifndef _DL_S390_PROCINFO_H
+#define _DL_S390_PROCINFO_H    1
 #include <sysdeps/s390/dl-procinfo.h>
 #include <ldsodefs.h>
 
@@ -44,3 +46,4 @@ _dl_procinfo (unsigned int type, unsigned long int word)
 
   return 0;
 }
+#endif