guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

02/03: HACK commencement: tcc-boot0: Patch for mes-0.23.


From: guix-commits
Subject: 02/03: HACK commencement: tcc-boot0: Patch for mes-0.23.
Date: Sun, 3 Jan 2021 14:03:47 -0500 (EST)

janneke pushed a commit to branch wip-full-source-bootstrap
in repository guix.

commit ba73945676f3c870b28f9ba851d191c7e25a59ea
Author: Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
AuthorDate: Sun Jan 3 16:15:10 2021 +0100

    HACK commencement: tcc-boot0: Patch for mes-0.23.
    
    * gnu/packages/commencement.scm (tcc-boot0)[arguments]: Add 
'mes-0.23-fixups'
    phase.
---
 gnu/packages/commencement.scm | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)

diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm
index 420951b..cf8584c 100644
--- a/gnu/packages/commencement.scm
+++ b/gnu/packages/commencement.scm
@@ -539,6 +539,25 @@ M1, and M2-Planet.")
                        (string-append "--elfinterp=" interpreter)
                        "--crtprefix=."
                        "--tccdir=."))))
+         (add-after 'configure 'mes-0.23-fixups
+           (lambda _
+             (substitute* "bootstrap.sh"
+               (("cp -f \\$\\{MES_PREFIX\\}/lib/libtcc1.c .*" all)
+                (string-append all "sed -i -e s',HAVE_FLOAT_STUB,1,' -e 
s',HAVE_FLOAT,1,' -e 's,__attribute__((weak)),,' libtcc1.c
+")))
+             (let ((config.h (open-file "config.h" "a")))
+               (display "
+// FIXME: mes-0.23 (TBR) only defines these if __SIZEOF_LONG_LONG__ != 8
+// but that requires patching of tcc's elf.h
+// and the updated tcc-boot-0.9.26-1136-g0fbeb2dd breaks floats
+typedef unsigned long long uint64_t;
+typedef long long int64_t;
+typedef unsigned long long ino64_t;
+typedef unsigned long long off64_t;
+"
+                        config.h)
+               (close config.h))
+             #t))
          (replace 'build
            (lambda _
              (substitute* "bootstrap.sh" ; Show some progress



reply via email to

[Prev in Thread] Current Thread [Next in Thread]