OSDN Git Service

PR target/33700
authordanglin <danglin@138bc75d-0d04-0410-961f-82ee72b054a4>
Sun, 14 Oct 2007 22:22:25 +0000 (22:22 +0000)
committerdanglin <danglin@138bc75d-0d04-0410-961f-82ee72b054a4>
Sun, 14 Oct 2007 22:22:25 +0000 (22:22 +0000)
* inclhack.def (hpux11_pthread_const): New.
* fixincl.x: Regenerate.
* tests/base/sys/pthread.h: Update.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@129304 138bc75d-0d04-0410-961f-82ee72b054a4

fixincludes/ChangeLog
fixincludes/fixincl.x
fixincludes/inclhack.def
fixincludes/tests/base/sys/pthread.h

index 0d5b2a1..1df6596 100644 (file)
@@ -1,3 +1,10 @@
+2007-10-14  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
+
+       PR target/33700
+       * inclhack.def (hpux11_pthread_const): New.
+       * fixincl.x: Regenerate.
+       * tests/base/sys/pthread.h: Update.
+
 2007-10-12  Kai Tietz  <kai.tietz@onevision.com>
 
        * configure.ac: x86_64 mingw target uses twoprocess.
 2007-10-12  Kai Tietz  <kai.tietz@onevision.com>
 
        * configure.ac: x86_64 mingw target uses twoprocess.
index 599bb21..a0daa2a 100644 (file)
@@ -2,11 +2,11 @@
  * 
  * DO NOT EDIT THIS FILE   (fixincl.x)
  * 
  * 
  * DO NOT EDIT THIS FILE   (fixincl.x)
  * 
- * It has been AutoGen-ed  Monday October  8, 2007 at 12:36:37 PM PDT
+ * It has been AutoGen-ed  Sunday October 14, 2007 at 06:17:05 PM EDT
  * From the definitions    inclhack.def
  * and the template file   fixincl
  */
  * From the definitions    inclhack.def
  * and the template file   fixincl
  */
-/* DO NOT SVN-MERGE THIS FILE, EITHER Mon Oct  8 12:36:37 PDT 2007
+/* DO NOT SVN-MERGE THIS FILE, EITHER Sun Oct 14 18:17:05 EDT 2007
  *
  * You must regenerate it.  Use the ./genfixes script.
  *
  *
  * You must regenerate it.  Use the ./genfixes script.
  *
@@ -15,7 +15,7 @@
  * certain ANSI-incompatible system header files which are fixed to work
  * correctly with ANSI C and placed in a directory that GNU C will search.
  *
  * certain ANSI-incompatible system header files which are fixed to work
  * correctly with ANSI C and placed in a directory that GNU C will search.
  *
- * This file contains 209 fixup descriptions.
+ * This file contains 210 fixup descriptions.
  *
  * See README for more information.
  *
  *
  * See README for more information.
  *
@@ -26,7 +26,8 @@
  *  
  *  You may redistribute it and/or modify it under the terms of the
  *  GNU General Public License, as published by the Free Software
  *  
  *  You may redistribute it and/or modify it under the terms of the
  *  GNU General Public License, as published by the Free Software
- *  Foundation; either version 2, or (at your option) any later version.
+ *  Foundation; either version 2 of the License, or (at your option)
+ *  any later version.
  *  
  *  inclhack is distributed in the hope that it will be useful,
  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
  *  
  *  inclhack is distributed in the hope that it will be useful,
  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
  *  See the GNU General Public License for more details.
  *  
  *  You should have received a copy of the GNU General Public License
  *  See the GNU General Public License for more details.
  *  
  *  You should have received a copy of the GNU General Public License
- *  along with inclhack.  See the file "COPYING".  If not,
- *  write to:  The Free Software Foundation, Inc.,
- *             59 Temple Place - Suite 330,
- *             Boston,  MA  02111-1307, USA.
+ *  along with inclhack.  If not, write to:
+ *     The Free Software Foundation, Inc.,
+ *     51 Franklin Street, Fifth Floor
+ *     Boston, MA  02110-1301, USA.
  */
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  */
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
@@ -3419,6 +3420,43 @@ extern \"C\" {\n\
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
+ *  Description of Hpux11_Pthread_Const fix
+ */
+tSCC zHpux11_Pthread_ConstName[] =
+     "hpux11_pthread_const";
+
+/*
+ *  File name selection pattern
+ */
+tSCC zHpux11_Pthread_ConstList[] =
+  "sys/pthread.h\0";
+/*
+ *  Machine/OS name selection pattern
+ */
+tSCC* apzHpux11_Pthread_ConstMachs[] = {
+        "*-hp-hpux11.[0-3]*",
+        (const char*)NULL };
+
+/*
+ *  content selection pattern - do fix if pattern found
+ */
+tSCC zHpux11_Pthread_ConstSelect0[] =
+       "^#define[ \t]*__POINTER_SET[ \t]*\\(\\(void \\*\\) 1LL\\)";
+
+#define    HPUX11_PTHREAD_CONST_TEST_CT  1
+static tTestDesc aHpux11_Pthread_ConstTests[] = {
+  { TT_EGREP,    zHpux11_Pthread_ConstSelect0, (regex_t*)NULL }, };
+
+/*
+ *  Fix Command Arguments for Hpux11_Pthread_Const
+ */
+static const char* apzHpux11_Pthread_ConstPatch[] = {
+    "format",
+    "#define __POINTER_SET\t\t((void *) 1L)",
+    (char*)NULL };
+
+/* * * * * * * * * * * * * * * * * * * * * * * * * *
+ *
  *  Description of Hpux_Pthread_Initializers fix
  */
 tSCC zHpux_Pthread_InitializersName[] =
  *  Description of Hpux_Pthread_Initializers fix
  */
 tSCC zHpux_Pthread_InitializersName[] =
@@ -8501,9 +8539,9 @@ static const char* apzX11_SprintfPatch[] = {
  *
  *  List of all fixes
  */
  *
  *  List of all fixes
  */
-#define REGEX_COUNT          252
+#define REGEX_COUNT          253
 #define MACH_LIST_SIZE_LIMIT 261
 #define MACH_LIST_SIZE_LIMIT 261
-#define FIX_COUNT            209
+#define FIX_COUNT            210
 
 /*
  *  Enumerate the fixes
 
 /*
  *  Enumerate the fixes
@@ -8589,6 +8627,7 @@ typedef enum {
     HPUX11_EXTERN_SENDFILE_FIXIDX,
     HPUX11_EXTERN_SENDPATH_FIXIDX,
     HPUX_EXTERN_ERRNO_FIXIDX,
     HPUX11_EXTERN_SENDFILE_FIXIDX,
     HPUX11_EXTERN_SENDPATH_FIXIDX,
     HPUX_EXTERN_ERRNO_FIXIDX,
+    HPUX11_PTHREAD_CONST_FIXIDX,
     HPUX_PTHREAD_INITIALIZERS_FIXIDX,
     HUGE_VAL_HEX_FIXIDX,
     HUGE_VALF_HEX_FIXIDX,
     HPUX_PTHREAD_INITIALIZERS_FIXIDX,
     HUGE_VAL_HEX_FIXIDX,
     HUGE_VALF_HEX_FIXIDX,
@@ -9121,6 +9160,11 @@ tFixDesc fixDescList[ FIX_COUNT ] = {
      HPUX_EXTERN_ERRNO_TEST_CT, FD_MACH_ONLY | FD_SUBROUTINE,
      aHpux_Extern_ErrnoTests,   apzHpux_Extern_ErrnoPatch, 0 },
 
      HPUX_EXTERN_ERRNO_TEST_CT, FD_MACH_ONLY | FD_SUBROUTINE,
      aHpux_Extern_ErrnoTests,   apzHpux_Extern_ErrnoPatch, 0 },
 
+  {  zHpux11_Pthread_ConstName,    zHpux11_Pthread_ConstList,
+     apzHpux11_Pthread_ConstMachs,
+     HPUX11_PTHREAD_CONST_TEST_CT, FD_MACH_ONLY | FD_SUBROUTINE,
+     aHpux11_Pthread_ConstTests,   apzHpux11_Pthread_ConstPatch, 0 },
+
   {  zHpux_Pthread_InitializersName,    zHpux_Pthread_InitializersList,
      apzHpux_Pthread_InitializersMachs,
      HPUX_PTHREAD_INITIALIZERS_TEST_CT, FD_MACH_ONLY,
   {  zHpux_Pthread_InitializersName,    zHpux_Pthread_InitializersList,
      apzHpux_Pthread_InitializersMachs,
      HPUX_PTHREAD_INITIALIZERS_TEST_CT, FD_MACH_ONLY,
index 08989c9..75f8347 100644 (file)
@@ -1952,6 +1952,20 @@ fix = {
 };
 
 /*
 };
 
 /*
+ *  Fix C99 constant in __POINTER_SET define.
+ */
+fix = {
+    hackname  = hpux11_pthread_const;
+    mach      = "*-hp-hpux11.[0-3]*";
+    files     = sys/pthread.h;
+    select    = "^#define[ \t]*__POINTER_SET[ \t]*\\(\\(void \\*\\) 1LL\\)";
+
+    c_fix     = format;
+    c_fix_arg = "#define __POINTER_SET\t\t((void *) 1L)";
+    test_text = "#define __POINTER_SET\t\t((void *) 1LL)";
+};
+
+/*
  *  Add missing braces to pthread initializer defines.
  */
 fix = {
  *  Add missing braces to pthread initializer defines.
  */
 fix = {
index 9948288..8b893cf 100644 (file)
@@ -9,6 +9,11 @@
 
 
 
 
 
 
+#if defined( HPUX11_PTHREAD_CONST_CHECK )
+#define __POINTER_SET          ((void *) 1L)
+#endif  /* HPUX11_PTHREAD_CONST_CHECK */
+
+
 #if defined( HPUX_PTHREAD_INITIALIZERS_CHECK )
 #define PTHREAD_MUTEX_INITIALIZER  {                                   \
        { __PTHREAD_MUTEX_VALID, 0 },                                   \
 #if defined( HPUX_PTHREAD_INITIALIZERS_CHECK )
 #define PTHREAD_MUTEX_INITIALIZER  {                                   \
        { __PTHREAD_MUTEX_VALID, 0 },                                   \