[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
07/07: patch: WIP.
From: |
Jan Nieuwenhuizen |
Subject: |
07/07: patch: WIP. |
Date: |
Tue, 18 Sep 2018 04:56:44 -0400 (EDT) |
janneke pushed a commit to branch wip-bootstrap
in repository guix.
commit ac4c0b1bd70cb260f72047d46de6337e78d3923e
Author: Jan Nieuwenhuizen <address@hidden>
Date: Tue Sep 18 10:39:25 2018 +0200
patch: WIP.
---
gnu/packages/commencement.scm | 19 +--
gnu/packages/patches/gcc-boot-4.7.4.patch | 6 +-
gnu/packages/patches/gcc-core-boot-2.95.3.patch | 202 ------------------------
3 files changed, 5 insertions(+), 222 deletions(-)
diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm
index 3fb0a69..1ef0958 100644
--- a/gnu/packages/commencement.scm
+++ b/gnu/packages/commencement.scm
@@ -706,7 +706,7 @@
(uri (string-append "mirror://gnu/gcc/gcc-2.95.3/gcc-core-"
version
".tar.gz"))
- (patches (search-patches "gcc-core-boot-2.95.3.patch"))
+ (patches (search-patches "gcc-boot-2.95.3.patch"))
(sha256
(base32
"1xvfy4pqhrd5v2cv8lzf63iqg92k09g6z9n2ah6ndd4h17k1x0an"))))
@@ -957,8 +957,6 @@ ac_cv_c_float_format='IEEE (little-endian)'
(package
(inherit gcc-core-mesboot)
(name "gcc-mesboot0")
- (source (origin (inherit (package-source gcc-core-mesboot))
- (patches (search-patches "gcc-boot-2.95.3.patch"))))
(native-inputs `(("binutils" ,binutils-mesboot0)
("gcc" ,gcc-core-mesboot)
("libc" ,glibc-mesboot0)
@@ -981,11 +979,6 @@ ac_cv_c_float_format='IEEE (little-endian)'
(kernel-headers (assoc-ref %build-inputs
"kernel-headers")))
(setenv "CONFIG_SHELL" (string-append bash "/bin/sh"))
(format (current-error-port) "C_INCLUDE_PATH=~a\n" (getenv
"C_INCLUDE_PATH"))
- ;; FIXME
- ;; (setenv "C_INCLUDE_PATH" (string-join
- ;; (list (string-append glibc
"/include")
- ;; (getenv "C_INCLUDE_PATH"))
- ;; ":"))
(setenv "C_INCLUDE_PATH" (string-append
gcc
"/lib/gcc-lib/i686-unknown-linux-gnu/2.95.3/include"
":" kernel-headers "/include"
@@ -1231,12 +1224,6 @@ ac_cv_c_float_format='IEEE (little-endian)'
"--disable-shared"
"--enable-threads=single"
- ;; libstdc++ cannot be built at this stage
- ;; ("Link tests are not allowed after
- ;; GCC_NO_EXECUTABLES.").
-;;; We NEED this later -- possibly add it in next gcc-mesboot...?
-;;;'"--disable-libstdc__-v3"
-
;; No pre-compiled libstdc++ headers, to save space.
"--disable-libstdcxx-pch"
@@ -1334,10 +1321,6 @@ exec " gcc "/bin/" program
(headers (assoc-ref %build-inputs "headers")))
(list
(string-append "--prefix=" out)
- ;; Build RPC support. It seems we either need rpc/*.h,
- ;; or should patch
- ;; include/netdb.h:32:24: fatal error: rpc/netdb.h: No such file
or directory
- ;; "--enable-sanity-checks"
"--disable-obsolete-rpc"
"--host=i686-unknown-linux-gnu"
(string-append "--with-headers=" headers "/include")
diff --git a/gnu/packages/patches/gcc-boot-4.7.4.patch
b/gnu/packages/patches/gcc-boot-4.7.4.patch
index 9aa9296..3e51e31 100644
--- a/gnu/packages/patches/gcc-boot-4.7.4.patch
+++ b/gnu/packages/patches/gcc-boot-4.7.4.patch
@@ -6,7 +6,9 @@ This patch enables building gcc-4.7.4 using gcc-2.95.3 and
glibc-2.2.5
upstream and can be removed with the next Mes release.
* Remove -fbuilding-libgcc flag, it assumes features being present from a
newer gcc or glibc.
- * [MES_GCC_BOOTSTRAP]: Disable threads harder.
+ * [MES_BOOTSTRAP_GCC]: Disable threads harder.
+
+Upstream status: not presented upstream.
diff --git a/gcc/Makefile.in b/gcc/Makefile.in
index f3cc49fdb18..bc5718fc9a6 100644
@@ -60,7 +62,7 @@ index bbe6dd12b5a..1d1d48223d7 100644
can build glibc. */
-#ifndef inhibit_libc
-+#if 0 // !defined (inhibit_libc) && !MES_GCC_BOOTSTRAP
++#if 0 //!defined (inhibit_libc) && !MES_BOOTSTRAP_GCC
#include <errno.h>
#include <pthread.h>
diff --git a/gnu/packages/patches/gcc-core-boot-2.95.3.patch
b/gnu/packages/patches/gcc-core-boot-2.95.3.patch
deleted file mode 100644
index 1cb8340..0000000
--- a/gnu/packages/patches/gcc-core-boot-2.95.3.patch
+++ /dev/null
@@ -1,202 +0,0 @@
-diff -purN -x foo.c -x BOOT -x BOOT-2 -x BOOT-strict -x .git -x Makefile -x
config.status -x config.h -x BOOT -x BOOT-GCC ../gcc-2.95.3/gcc/crtstuff.c
gcc-2.95.3/gcc/crtstuff.c
---- ../gcc-2.95.3/gcc/crtstuff.c 1999-03-23 01:43:51.000000000 +0100
-+++ gcc-2.95.3/gcc/crtstuff.c 2018-06-19 19:52:06.151175995 +0200
-@@ -54,8 +54,12 @@ Boston, MA 02111-1307, USA. */
- #include "tm.h"
- #include "defaults.h"
- #include <stddef.h>
-+
-+#define FIRST_PSEUDO_REGISTER 17
-+
- #include "frame.h"
-
-+
- /* We do not want to add the weak attribute to the declarations of these
- routines in frame.h because that will cause the definition of these
- symbols to be weak as well.
-diff -purN -x foo.c -x BOOT -x BOOT-2 -x BOOT-strict -x .git -x Makefile -x
config.status -x config.h -x BOOT -x BOOT-GCC ../gcc-2.95.3/gcc/libgcc2.c
gcc-2.95.3/gcc/libgcc2.c
---- ../gcc-2.95.3/gcc/libgcc2.c 1999-06-11 05:11:43.000000000 +0200
-+++ gcc-2.95.3/gcc/libgcc2.c 2018-06-19 19:52:06.151175995 +0200
-@@ -48,6 +48,43 @@ Boston, MA 02111-1307, USA. */
- #include <stddef.h>
- #endif
-
-+/*
-+ mysteriously missing decls
-+*/
-+
-+#ifndef stderr
-+#define stderr 2
-+#endif
-+
-+#ifndef BITS_PER_UNIT
-+#define BITS_PER_UNIT 8
-+#endif
-+
-+#ifndef LONG_MIN
-+#define LONG_MIN -2147483648
-+#endif
-+
-+#ifndef EOF
-+#define EOF -1
-+#endif
-+
-+#if __GNUC__
-+// typedef unsigned short word_type;
-+
-+#if !defined (SIZE_T) && !defined (_SIZE_T) && !defined (__MES_SIZE_T)
-+#define SIZE_T
-+#define _SIZE_T
-+typedef long unsigned int size_t;
-+#endif
-+
-+#endif // __GNUC__
-+
-+#if !defined (_FILE_T) && !defined (__MES_FILE_T)
-+#define FILE_T
-+#define _FILE_T
-+typedef int *FILE;
-+#endif
-+
- /* Don't use `fancy_abort' here even if config.h says to use it. */
- #ifdef abort
- #undef abort
-diff -purN -x foo.c -x BOOT -x BOOT-2 -x BOOT-strict -x .git -x Makefile -x
config.status -x config.h -x BOOT -x BOOT-GCC ../gcc-2.95.3/gcc/machmode.h
gcc-2.95.3/gcc/machmode.h
---- ../gcc-2.95.3/gcc/machmode.h 1999-04-08 09:27:26.000000000 +0200
-+++ gcc-2.95.3/gcc/machmode.h 2018-06-19 19:52:06.151175995 +0200
-@@ -21,6 +21,9 @@ Boston, MA 02111-1307, USA. */
- #ifndef HAVE_MACHINE_MODES
- #define HAVE_MACHINE_MODES
-
-+#undef PROTO
-+#define PROTO(args) args
-+
- /* Strictly speaking, this isn't the proper place to include these
definitions,
- but this file is included by every GCC file. */
-
-diff -purN -x foo.c -x BOOT -x BOOT-2 -x BOOT-strict -x .git -x Makefile -x
config.status -x config.h -x BOOT -x BOOT-GCC ../gcc-2.95.3/gcc/Makefile.in
gcc-2.95.3/gcc/Makefile.in
---- ../gcc-2.95.3/gcc/Makefile.in 2001-01-25 15:02:58.000000000 +0100
-+++ gcc-2.95.3/gcc/Makefile.in 2018-06-23 11:46:03.525159181 +0200
-@@ -221,7 +221,7 @@ RANLIB_TEST_FOR_TARGET = \
- SYSTEM_HEADER_DIR = /usr/include
-
- # Control whether to run fixproto.
--STMP_FIXPROTO = stmp-fixproto
-+# STMP_FIXPROTO = stmp-fixproto
-
- # Test to see whether <limits.h> exists in the system header files.
- LIMITS_H_TEST = [ -f $(SYSTEM_HEADER_DIR)/limits.h ]
-@@ -958,6 +958,7 @@ libgcc1.cross:
- # fragments.
- libgcc1.a: libgcc1.c $(CONFIG_H) $(LIB1FUNCS_EXTRA) config.status
- -rm -f tmplibgcc1.a
-+ mkdir -p libgcc1-o
- # Actually build it in tmplibgcc1.a, then rename at end,
- # so that libgcc1.a itself remains nonexistent if compilation is aborted.
- # -e causes any failing command to make this rule fail.
-@@ -974,6 +975,7 @@ libgcc1.a: libgcc1.c $(CONFIG_H) $(LIB1F
- if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
- mv libgcc1$(objext) $${name}$(objext); \
- $(OLDAR) $(OLDAR_FLAGS) tmplibgcc1.a $${name}$(objext); \
-+ mv $${name}$(objext) libgcc1-o; \
- rm -f $${name}$(objext); \
- done
- # Some shells crash when a loop has no items.
-@@ -994,6 +996,7 @@ libgcc1.a: libgcc1.c $(CONFIG_H) $(LIB1F
- if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
- $(OLDAR) $(OLDAR_FLAGS) tmplibgcc1.a $${name}$(objext); \
- if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
-+ mv $${name}$(objext) libgcc1-o; \
- rm -f $${name}.s $${name}$(objext); \
- else true; \
- fi; \
-@@ -1024,6 +1027,7 @@ libgcc1-asm.a: libgcc2.ready config.stat
- if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
- mv libgcc1$(objext) $${name}$(objext); \
- $(AR_FOR_TARGET) $(AR_FLAGS_FOR_TARGET) tmplibgcc1.a
$${name}$(objext); \
-+ mv $${name}$(objext) libgcc1-o; \
- rm -f $${name}$(objext); \
- done
- -rm -f libgcc1.S
-@@ -1062,6 +1066,7 @@ libgcc2.a: libgcc2.c libgcc2.ready $(CON
- # Actually build it in tmplibgcc2.a, then rename at end,
- # so that libgcc2.a itself remains nonexistent if compilation is aborted.
- -rm -f tmplibgcc2.a
-+ mkdir -p libgcc2-o
- # -e causes any failing command to make this rule fail.
- # -e doesn't work in certain shells, so we test $$? as well.
- # lynx has a broken ar, it always complains when the initial library is
-@@ -1139,6 +1144,7 @@ libgcc2.a: libgcc2.c libgcc2.ready $(CON
- $(GCC_FOR_TARGET) $(LIBGCC2_CFLAGS) $(INCLUDES) -c $${file}; \
- if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
- $(AR_FOR_TARGET) $(AR_FLAGS_FOR_TARGET) tmplibgcc2.a
$${oname}$(objext); \
-+ mv $${oname}$(objext) libgcc2-o;\
- rm -f $${name}.s $${oname}$(objext); \
- fi; \
- done
-@@ -1156,7 +1162,7 @@ libgcc.a: $(LIBGCC1) $(LIBGCC2)
- -rm -rf tmplibgcc.a libgcc.a tmpcopy
- mkdir tmpcopy
- -if [ x$(LIBGCC1) != x ]; \
-- then (cd tmpcopy; $(AR_FOR_TARGET) x ../$(LIBGCC1)); \
-+ then cp -v libgcc1-o/*.o tmpcopy; \
- else true; \
- fi
- # Some versions of ar (specifically the one in RISC/os 5.x), create an
-@@ -1164,7 +1170,7 @@ libgcc.a: $(LIBGCC1) $(LIBGCC2)
- # the second ar command tries to overwrite this file. To avoid the error
- # message from ar, we make sure all files are writable.
- -(cd tmpcopy; chmod +w * > /dev/null 2>&1)
-- (cd tmpcopy; $(AR_FOR_TARGET) x ../$(LIBGCC2))
-+ cp -v libgcc2-o/*.o tmpcopy
- (cd tmpcopy; $(AR_FOR_TARGET) $(AR_FLAGS_FOR_TARGET) ../tmplibgcc.a
*$(objext))
- rm -rf tmpcopy
- -if $(RANLIB_TEST_FOR_TARGET) ; then \
-@@ -2093,14 +2099,18 @@ gcov$(exeext): $(GCOV_OBJS) $(LIBDEPS)
- # s-* so that mostlyclean does not force the include directory to
- # be rebuilt.
-
-+# STMP_FIXINC = @STMP_FIXINC@
-+STMP_FIXINC = stmp-fixinc
-+
- # Build the include directory including float.h (which no longer depends upon
- # enquire).
--stmp-int-hdrs: stmp-fixinc $(USER_H) xlimits.h
-+stmp-int-hdrs: $(STMP_FIXINC) $(USER_H) xlimits.h
- # Copy in the headers provided with gcc.
- # The sed command gets just the last file name component;
- # this is necessary because VPATH could add a dirname.
- # Using basename would be simpler, but some systems don't have it.
- # The touch command is here to workaround an AIX/Linux NFS bug.
-+ -if [ -d include ] ; then true; else mkdir include; chmod a+rx include;
fi
- for file in .. $(USER_H); do \
- if [ X$$file != X.. ]; then \
- realfile=`echo $$file | sed -e 's|.*/\([^/]*\)$$|\1|'`; \
-@@ -2265,16 +2275,17 @@ stmp-fixproto: fixhdr.ready fixproto stm
- #
- # Remake the info files.
-
--doc: info
--info: cpp.info gcc.info lang.info
--
--cpp.info: $(srcdir)/cpp.texi
-- $(MAKEINFO) $(MAKEINFOFLAGS) -I$(srcdir) -o cpp.info $(srcdir)/cpp.texi
--
--gcc.info: $(srcdir)/gcc.texi $(srcdir)/extend.texi $(srcdir)/install.texi \
-- $(srcdir)/invoke.texi $(srcdir)/md.texi $(srcdir)/rtl.texi \
-- $(srcdir)/tm.texi $(srcdir)/gcov.texi
-- $(MAKEINFO) $(MAKEINFOFLAGS) -I$(srcdir) -o gcc.info $(srcdir)/gcc.texi
-+doc:
-+# doc: info
-+# info: cpp.info gcc.info lang.info
-+
-+# cpp.info: $(srcdir)/cpp.texi
-+# $(MAKEINFO) $(MAKEINFOFLAGS) -I$(srcdir) -o cpp.info $(srcdir)/cpp.texi
-+
-+# gcc.info: $(srcdir)/gcc.texi $(srcdir)/extend.texi $(srcdir)/install.texi \
-+# $(srcdir)/invoke.texi $(srcdir)/md.texi $(srcdir)/rtl.texi \
-+# $(srcdir)/tm.texi $(srcdir)/gcov.texi
-+# $(MAKEINFO) $(MAKEINFOFLAGS) -I$(srcdir) -o gcc.info $(srcdir)/gcc.texi
-
- dvi: gcc.dvi cpp.dvi lang.dvi
-
- branch wip-bootstrap updated (2e0ae3f -> ac4c0b1), Jan Nieuwenhuizen, 2018/09/18
- 01/07: patch: doc, Jan Nieuwenhuizen, 2018/09/18
- 02/07: patch doc, Jan Nieuwenhuizen, 2018/09/18
- 05/07: bootstrap: tcc update WIP, Jan Nieuwenhuizen, 2018/09/18
- 03/07: bootstrap: cleanup, document patches WIP, Jan Nieuwenhuizen, 2018/09/18
- 04/07: patch, Jan Nieuwenhuizen, 2018/09/18
- 07/07: patch: WIP.,
Jan Nieuwenhuizen <=
- 06/07: patch: wip, Jan Nieuwenhuizen, 2018/09/18