gnu.gcc.help
[Top] [All Lists]

Re: Build and install GCC-3.2.3

Subject: Re: Build and install GCC-3.2.3
From:
Date: Tue, 27 May 2008 13:15:49 -0700 PDT
Newsgroups: gnu.gcc.help

Thanks again for your reply.

However, I ran into below errors. I'm at the src directory /usr/local/
src/gcc-3.2.3/gcc/

Please help..

patch -p0 <patch
patching file read-rtl.c
Hunk #1 FAILED at 659.
1 out of 1 hunk FAILED -- saving rejects to file read-rtl.c.rej
patching file system.h
Hunk #1 FAILED at 578.
1 out of 1 hunk FAILED -- saving rejects to file system.h.rej
missing header for unified diff at line 28 of patch
can't find file to patch at input line 28
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|
| /* Note autoconf checks for prototype declarations and includes
--------------------------
File to patch:


[root@rhel5-build gcc]# cat patch
Index: read-rtl.c
===================================================================
--- read-rtl.c  (revision 131336)
+++ read-rtl.c  (working copy)
@@ -659,7 +659,7 @@
            {
              ungetc (c, infile);
              list_counter++;
-             obstack_ptr_grow (&vector_stack, (PTR) read_rtx
(infile));
+             obstack_ptr_grow (&vector_stack, read_rtx (infile));
            }
          if (list_counter > 0)
            {
Index: system.h
===================================================================
--- system.h    (revision 131336)
+++ system.h    (working copy)
@@ -578,6 +578,7 @@
 #define really_call_calloc calloc
 #define really_call_realloc realloc


+
 #if (GCC_VERSION >= 3000)


 /* Note autoconf checks for prototype declarations and includes
@@ -589,7 +590,9 @@
 #undef realloc
 #undef calloc
 #undef strdup
+#if ! (defined(FLEX_SCANNER) || defined(YYBISON) || defined(YYBYACC))
  #pragma GCC poison malloc realloc calloc strdup
+#endif


 /* Old target macros that have moved to the target hooks structure.
*/
  #pragma GCC poison ASM_OPEN_PAREN
ASM_CLOSE_PAREN                     \
@@ -628,4 +631,11 @@


 #endif /* GCC >= 3.0 */


+#if defined(FLEX_SCANNER) || defined(YYBISON) || defined(YYBYACC)
+/* Flex and bison use malloc and realloc.  Yuk.  Note that this means
+   really_call_* cannot be used in a .l or .y file.  */
+#define malloc xmalloc
+#define realloc xrealloc
+#endif
+
 #endif /* ! GCC_SYSTEM_H */





<Prev in Thread] Current Thread [Next in Thread>
Privacy Policy