From 89a83bcdb1b9bbdd885d0047efc901348233668a Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 20:12:57 +0000 Subject: [PATCH 01/49] add tcc_bootstrap_alt-0.1 source and kaem build script --- steps/tcc_bootstrap_alt-0.1/sources | 1 + .../tcc_bootstrap_alt-0.1.kaem | 31 +++++++++++++++++++ 2 files changed, 32 insertions(+) create mode 100644 steps/tcc_bootstrap_alt-0.1/sources create mode 100644 steps/tcc_bootstrap_alt-0.1/tcc_bootstrap_alt-0.1.kaem diff --git a/steps/tcc_bootstrap_alt-0.1/sources b/steps/tcc_bootstrap_alt-0.1/sources new file mode 100644 index 00000000..c0ee3721 --- /dev/null +++ b/steps/tcc_bootstrap_alt-0.1/sources @@ -0,0 +1 @@ +https://github.com/cosinusoidally/tcc_bootstrap_alt/releases/download/0.1/tcc_bootstrap_alt-0.1.tar.gz 578f5025a2f4d3e3967ded2cf5b03423cd19ed176bf3f2c4dcd19354b7ccc739 diff --git a/steps/tcc_bootstrap_alt-0.1/tcc_bootstrap_alt-0.1.kaem b/steps/tcc_bootstrap_alt-0.1/tcc_bootstrap_alt-0.1.kaem new file mode 100644 index 00000000..2a996ab1 --- /dev/null +++ b/steps/tcc_bootstrap_alt-0.1/tcc_bootstrap_alt-0.1.kaem @@ -0,0 +1,31 @@ +#!/bin/sh + +# SPDX-FileCopyrightText: 2024 Liam Wilson +# +# SPDX-License-Identifier: GPL-3.0-or-later + +set -ex + +TCC_BOOTSTRAP_ALT_PKG=tcc_bootstrap_alt-0.1 + +# Check tarball checksums +checksum-transcriber sources +sha256sum -c sources.SHA256SUM + +# Unpack +mkdir src + +cd src +ungz --file ${distfiles}/${TCC_BOOTSTRAP_ALT_PKG}.tar.gz --output ${TCC_BOOTSTRAP_ALT_PKG}.tar + +untar --non-strict --file ./${TCC_BOOTSTRAP_ALT_PKG}.tar + +# Build +cd ./${TCC_BOOTSTRAP_ALT_PKG} +/bootstrap-seeds/POSIX/x86/hex0-seed ./x86/hex0_x86.hex0 ./x86/artifact/hex0-seed +chmod 755 ./x86/artifact/hex0-seed +/bootstrap-seeds/POSIX/x86/hex0-seed ./x86/kaem-minimal.hex0 ./x86/artifact/kaem-optional-seed +chmod 755 ./x86/artifact/kaem-optional-seed +kaem --file kaem.x86 +cp artifacts/tcc_27_boot_static.exe /usr/bin/tcc-boot0 +chmod 755 /usr/bin/tcc-boot0 From b4068aaba50cbf9169ad50e355612d7ac17f02c1 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 20:17:03 +0000 Subject: [PATCH 02/49] temp abort after 0.9.27 build --- steps/tcc-0.9.27/pass1.kaem | 3 +++ 1 file changed, 3 insertions(+) diff --git a/steps/tcc-0.9.27/pass1.kaem b/steps/tcc-0.9.27/pass1.kaem index b7fcf21c..e7fa478f 100755 --- a/steps/tcc-0.9.27/pass1.kaem +++ b/steps/tcc-0.9.27/pass1.kaem @@ -84,3 +84,6 @@ if match x${UPDATE_CHECKSUMS} xTrue; then else sha256sum -c ${pkg}.checksums fi + +# LJW HACK stop here +exit 1 From 331262575fbb63dbfaf2b39cefcf0475d512a9be Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 20:30:36 +0000 Subject: [PATCH 03/49] start adding option to run tcc_bootstrap_alt --- steps/manifest | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/steps/manifest b/steps/manifest index 91cc4555..3c2f63a7 100644 --- a/steps/manifest +++ b/steps/manifest @@ -30,7 +30,8 @@ build: checksum-transcriber-1.0 build: simple-patch-1.0 -build: mes-0.25 +build: mes-0.25 ( TCC_BOOTSTRAP_ALT == False ) +build: tcc_bootstrap_alt-0.1 ( TCC_BOOTSTRAP_ALT == True ) build: tcc-0.9.26 build: tcc-0.9.27 define: BUILD_FIWIX = ( KERNEL_BOOTSTRAP == True || BUILD_KERNELS == True ) From 1f9971d39830313992dd21287e9859e12e1a5503 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 20:36:37 +0000 Subject: [PATCH 04/49] more TCC_BOOTSTRAP_ALT config --- rootfs.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/rootfs.py b/rootfs.py index 5a9e7988..c17aeab0 100755 --- a/rootfs.py +++ b/rootfs.py @@ -43,6 +43,7 @@ def create_configuration_file(args): config.write("DISK=sda1\n") config.write("KERNEL_BOOTSTRAP=False\n") config.write(f"BUILD_KERNELS={args.update_checksums or args.build_kernels}\n") + config.write(f"TCC_BOOTSTRAP_ALT={args.tcc_bootstrap_alt}\n") # pylint: disable=too-many-statements def main(): @@ -100,6 +101,9 @@ def main(): parser.add_argument("-b", "--bare-metal", help="Build images for bare metal", action="store_true") + parser.add_argument("--tcc_bootstrap_alt", + help="Use tcc_bootstrap_alt.", + action="store_true") args = parser.parse_args() From fd096b7d731e87f40b546c281efd2bc28cd6e538 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 20:51:42 +0000 Subject: [PATCH 05/49] test alt bootstrap path via github ci --- .github/workflows/bwrap.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/bwrap.yml b/.github/workflows/bwrap.yml index 66cea846..bb8e925b 100644 --- a/.github/workflows/bwrap.yml +++ b/.github/workflows/bwrap.yml @@ -43,7 +43,7 @@ jobs: distfiles key: cache-${{ hashFiles('steps/*/sources') }} - name: Run bootstrap - run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 + run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 --tcc_bootstrap_alt - name: Archive created packages if: failure() # archive failed builds progress uses: actions/upload-artifact@v3 From a8df00f21d8dbe50eccec73cc666bef5ed58d909 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 20:58:11 +0000 Subject: [PATCH 06/49] fix kaem name --- .../{tcc_bootstrap_alt-0.1.kaem => pass1.kaem} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename steps/tcc_bootstrap_alt-0.1/{tcc_bootstrap_alt-0.1.kaem => pass1.kaem} (100%) diff --git a/steps/tcc_bootstrap_alt-0.1/tcc_bootstrap_alt-0.1.kaem b/steps/tcc_bootstrap_alt-0.1/pass1.kaem similarity index 100% rename from steps/tcc_bootstrap_alt-0.1/tcc_bootstrap_alt-0.1.kaem rename to steps/tcc_bootstrap_alt-0.1/pass1.kaem From 6c6ab74a4aeb04006dd40673356d6daa1998818e Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 21:13:08 +0000 Subject: [PATCH 07/49] update pass1.kaem --- steps/tcc_bootstrap_alt-0.1/pass1.kaem | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/steps/tcc_bootstrap_alt-0.1/pass1.kaem b/steps/tcc_bootstrap_alt-0.1/pass1.kaem index 2a996ab1..d4413b63 100644 --- a/steps/tcc_bootstrap_alt-0.1/pass1.kaem +++ b/steps/tcc_bootstrap_alt-0.1/pass1.kaem @@ -6,8 +6,6 @@ set -ex -TCC_BOOTSTRAP_ALT_PKG=tcc_bootstrap_alt-0.1 - # Check tarball checksums checksum-transcriber sources sha256sum -c sources.SHA256SUM @@ -16,12 +14,12 @@ sha256sum -c sources.SHA256SUM mkdir src cd src -ungz --file ${distfiles}/${TCC_BOOTSTRAP_ALT_PKG}.tar.gz --output ${TCC_BOOTSTRAP_ALT_PKG}.tar +ungz --file ${DISTFILES}/${pkg}.tar.gz --output ${pkg}.tar -untar --non-strict --file ./${TCC_BOOTSTRAP_ALT_PKG}.tar +untar --non-strict --file ./${pkg}.tar # Build -cd ./${TCC_BOOTSTRAP_ALT_PKG} +cd ./${pkg} /bootstrap-seeds/POSIX/x86/hex0-seed ./x86/hex0_x86.hex0 ./x86/artifact/hex0-seed chmod 755 ./x86/artifact/hex0-seed /bootstrap-seeds/POSIX/x86/hex0-seed ./x86/kaem-minimal.hex0 ./x86/artifact/kaem-optional-seed From e1738d93c9f657cb8ef5cc220de715c22f71f284 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 21:18:31 +0000 Subject: [PATCH 08/49] re-enable mes-0.25 --- steps/manifest | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/steps/manifest b/steps/manifest index 3c2f63a7..b185c0bb 100644 --- a/steps/manifest +++ b/steps/manifest @@ -30,7 +30,7 @@ build: checksum-transcriber-1.0 build: simple-patch-1.0 -build: mes-0.25 ( TCC_BOOTSTRAP_ALT == False ) +build: mes-0.25 build: tcc_bootstrap_alt-0.1 ( TCC_BOOTSTRAP_ALT == True ) build: tcc-0.9.26 build: tcc-0.9.27 From dc96cc9cb0677cf9392c343b3b2d456cd84de8d8 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 21:24:53 +0000 Subject: [PATCH 09/49] skip parts of mes-0.25/pass1.kaem if TCC_BOOTSTRAP_ALT is True --- steps/mes-0.25/pass1.kaem | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/steps/mes-0.25/pass1.kaem b/steps/mes-0.25/pass1.kaem index b727e349..f45233f9 100755 --- a/steps/mes-0.25/pass1.kaem +++ b/steps/mes-0.25/pass1.kaem @@ -60,6 +60,7 @@ rm mes/module/mes/psyntax.pp mes/module/mes/psyntax.pp.header cp mes/module/srfi/srfi-9-struct.mes mes/module/srfi/srfi-9.mes cp mes/module/srfi/srfi-9/gnu-struct.mes mes/module/srfi/srfi-9/gnu.mes +if match x${TCC_BOOTSTRAP_ALT} xFalse; then # Build mes-m2 kaem --verbose --strict --file kaem.${MES_ARCH} cp bin/mes-m2 ${BINDIR}/mes-m2 @@ -265,10 +266,14 @@ mescc lib/linux/stat.c catm ${LIBDIR}/${MES_ARCH}-mes/libc+tcc.a ${LIBDIR}/${MES_ARCH}-mes/libc.a islower.o isupper.o tolower.o toupper.o abtod.o dtoab.o search-path.o execvp.o fclose.o fdopen.o ferror.o fflush.o fopen.o fprintf.o fread.o fseek.o ftell.o fwrite.o printf.o remove.o snprintf.o sprintf.o sscanf.o vfprintf.o vprintf.o vsnprintf.o vsprintf.o vsscanf.o calloc.o qsort.o strtod.o strtof.o strtol.o strtold.o strtoll.o strtoul.o strtoull.o memmem.o strcat.o strchr.o strlwr.o strncpy.o strrchr.o strstr.o strupr.o sigaction.o ldexp.o mprotect.o localtime.o sigemptyset.o setjmp.o close.o rmdir.o stat.o catm ${LIBDIR}/${MES_ARCH}-mes/libc+tcc.s ${LIBDIR}/${MES_ARCH}-mes/libc.s islower.s isupper.s tolower.s toupper.s abtod.s dtoab.s search-path.s execvp.s fclose.s fdopen.s ferror.s fflush.s fopen.s fprintf.s fread.s fseek.s ftell.s fwrite.s printf.s remove.s snprintf.s sprintf.s sscanf.s vfprintf.s vprintf.s vsnprintf.s vsprintf.s vsscanf.s calloc.s qsort.s strtod.s strtof.s strtol.s strtold.s strtoll.s strtoul.s strtoull.s memmem.s strcat.s strchr.s strlwr.s strncpy.s strrchr.s strstr.s strupr.s sigaction.s ldexp.s mprotect.s localtime.s sigemptyset.s setjmp.s close.s rmdir.s stat.s +fi + # Make directories mkdir ${PREFIX}/lib/linux ${INCDIR}/mes ${INCDIR}/sys ${INCDIR}/linux ${INCDIR}/arch mkdir ${PREFIX}/lib/${MES_ARCH}-mes ${PREFIX}/lib/linux/${MES_ARCH}-mes ${INCDIR}/linux/${MES_ARCH} +if match x${TCC_BOOTSTRAP_ALT} xFalse; then + # Install libraries cp ${LIBDIR}/${MES_ARCH}-mes/libc.a ${PREFIX}/lib/${MES_ARCH}-mes/ cp ${LIBDIR}/${MES_ARCH}-mes/libc+tcc.a ${PREFIX}/lib/${MES_ARCH}-mes/ @@ -282,6 +287,8 @@ cp ${LIBDIR}/${MES_ARCH}-mes/crt1.s ${PREFIX}/lib/${MES_ARCH}-mes/ cp ${LIBDIR}/linux/${MES_ARCH}-mes/elf${ARCH_BITS}-footer-single-main.hex2 ${PREFIX}/lib/linux/${MES_ARCH}-mes/ cp ${LIBDIR}/linux/${MES_ARCH}-mes/elf${ARCH_BITS}-header.hex2 ${PREFIX}/lib/linux/${MES_ARCH}-mes/ +fi + # Install header files cp include/alloca.h ${INCDIR}/alloca.h cp include/argz.h ${INCDIR}/argz.h @@ -355,6 +362,7 @@ cp include/sys/wait.h ${INCDIR}/sys/wait.h cd ../.. +if match x${TCC_BOOTSTRAP_ALT} xFalse; then # Checksums if match x${UPDATE_CHECKSUMS} xTrue; then sha256sum -o ${pkg}.${ARCH}.checksums \ @@ -377,3 +385,4 @@ if match x${UPDATE_CHECKSUMS} xTrue; then else sha256sum -c ${pkg}.${ARCH}.checksums fi +fi From 37421bd50094acc234bb35c4db520b2f3ce539af Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 21:33:01 +0000 Subject: [PATCH 10/49] tweak conditional --- steps/mes-0.25/pass1.kaem | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/steps/mes-0.25/pass1.kaem b/steps/mes-0.25/pass1.kaem index f45233f9..47034fe2 100755 --- a/steps/mes-0.25/pass1.kaem +++ b/steps/mes-0.25/pass1.kaem @@ -362,7 +362,9 @@ cp include/sys/wait.h ${INCDIR}/sys/wait.h cd ../.. -if match x${TCC_BOOTSTRAP_ALT} xFalse; then +if match x${TCC_BOOTSTRAP_ALT} xTrue; then + +else # Checksums if match x${UPDATE_CHECKSUMS} xTrue; then sha256sum -o ${pkg}.${ARCH}.checksums \ From e22a43a3ba3b512cf1aec39361d882d6943b4548 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 21:40:31 +0000 Subject: [PATCH 11/49] seems to be some issue with nesting conditionals --- steps/mes-0.25/pass1.kaem | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/steps/mes-0.25/pass1.kaem b/steps/mes-0.25/pass1.kaem index 47034fe2..59b4b40c 100755 --- a/steps/mes-0.25/pass1.kaem +++ b/steps/mes-0.25/pass1.kaem @@ -362,11 +362,8 @@ cp include/sys/wait.h ${INCDIR}/sys/wait.h cd ../.. -if match x${TCC_BOOTSTRAP_ALT} xTrue; then - -else # Checksums -if match x${UPDATE_CHECKSUMS} xTrue; then +if match x${UPDATE_CHECKSUMS}${TCC_BOOTSTRAP_ALT} xTrueFalse; then sha256sum -o ${pkg}.${ARCH}.checksums \ /usr/bin/mes \ /usr/bin/mes-m2 \ @@ -387,4 +384,3 @@ if match x${UPDATE_CHECKSUMS} xTrue; then else sha256sum -c ${pkg}.${ARCH}.checksums fi -fi From 4d2537cd2157cb34c562e99e03251616c10d0d2f Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 21:43:02 +0000 Subject: [PATCH 12/49] conditional tweak --- steps/mes-0.25/pass1.kaem | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/steps/mes-0.25/pass1.kaem b/steps/mes-0.25/pass1.kaem index 59b4b40c..2fe2f978 100755 --- a/steps/mes-0.25/pass1.kaem +++ b/steps/mes-0.25/pass1.kaem @@ -381,6 +381,7 @@ if match x${UPDATE_CHECKSUMS}${TCC_BOOTSTRAP_ALT} xTrueFalse; then /usr/lib/linux/${MES_ARCH}-mes/elf${ARCH_BITS}-footer-single-main.hex2 cp ${pkg}.${ARCH}.checksums ${SRCDIR} -else +fi +if match x${UPDATE_CHECKSUMS}${TCC_BOOTSTRAP_ALT} xFalseFalse; then sha256sum -c ${pkg}.${ARCH}.checksums fi From 977290a444b8439513502b75368973731ed15fc2 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 22:03:12 +0000 Subject: [PATCH 13/49] start adapting tcc-0.9.26/pass1.kaem to optionally run tcc_bootstrap_alt --- steps/tcc-0.9.26/pass1.kaem | 36 ++++++++++++++++++++++++++++++++++-- 1 file changed, 34 insertions(+), 2 deletions(-) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index be93e55a..60ee3ad6 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -62,7 +62,9 @@ if match ${ARCH} riscv64; then HAVE_LONG_LONG=1 fi +if match x${TCC_BOOTSTRAP_ALT} xTrue; then +else ${MES} --no-auto-compile -e main ${BINDIR}/mescc.scm -- \ -S \ -o tcc.s \ @@ -97,6 +99,8 @@ chmod 755 ${BINDIR}/tcc-mes # test tcc-mes tcc-mes -version +fi + # Recompile the mes C library cd ../${MES_PKG} @@ -105,12 +109,18 @@ cd lib catm ../unified-libc.c ctype/isalnum.c ctype/isalpha.c ctype/isascii.c ctype/iscntrl.c ctype/isdigit.c ctype/isgraph.c ctype/islower.c ctype/isnumber.c ctype/isprint.c ctype/ispunct.c ctype/isspace.c ctype/isupper.c ctype/isxdigit.c ctype/tolower.c ctype/toupper.c dirent/closedir.c dirent/__getdirentries.c dirent/opendir.c dirent/readdir.c linux/access.c linux/brk.c linux/chdir.c linux/chmod.c linux/clock_gettime.c linux/close.c linux/dup2.c linux/dup.c linux/execve.c linux/fcntl.c linux/fork.c linux/fsync.c linux/fstat.c linux/_getcwd.c linux/getdents.c linux/getegid.c linux/geteuid.c linux/getgid.c linux/getpid.c linux/getppid.c linux/getrusage.c linux/gettimeofday.c linux/getuid.c linux/ioctl.c linux/ioctl3.c linux/kill.c linux/link.c linux/lseek.c linux/lstat.c linux/malloc.c linux/mkdir.c linux/mknod.c linux/nanosleep.c linux/_open3.c linux/pipe.c linux/_read.c linux/readlink.c linux/rename.c linux/rmdir.c linux/setgid.c linux/settimer.c linux/setuid.c linux/signal.c linux/sigprogmask.c linux/symlink.c linux/stat.c linux/time.c linux/unlink.c linux/waitpid.c linux/wait4.c linux/${MES_ARCH}-mes-${MES_LIBC_SUFFIX}/_exit.c linux/${MES_ARCH}-mes-${MES_LIBC_SUFFIX}/syscall.c linux/${MES_ARCH}-mes-${MES_LIBC_SUFFIX}/_write.c math/ceil.c math/fabs.c math/floor.c mes/abtod.c mes/abtol.c mes/__assert_fail.c mes/assert_msg.c mes/__buffered_read.c mes/__init_io.c mes/cast.c mes/dtoab.c mes/eputc.c mes/eputs.c mes/fdgetc.c mes/fdgets.c mes/fdputc.c mes/fdputs.c mes/fdungetc.c mes/globals.c mes/itoa.c mes/ltoab.c mes/ltoa.c mes/__mes_debug.c mes/mes_open.c mes/ntoab.c mes/oputc.c mes/oputs.c mes/search-path.c mes/ultoa.c mes/utoa.c posix/alarm.c posix/buffered-read.c posix/execl.c posix/execlp.c posix/execv.c posix/execvp.c posix/getcwd.c posix/getenv.c posix/isatty.c posix/mktemp.c posix/open.c posix/raise.c posix/sbrk.c posix/setenv.c posix/sleep.c posix/unsetenv.c posix/wait.c posix/write.c stdio/clearerr.c stdio/fclose.c stdio/fdopen.c stdio/feof.c stdio/ferror.c stdio/fflush.c stdio/fgetc.c stdio/fgets.c stdio/fileno.c stdio/fopen.c stdio/fprintf.c stdio/fputc.c stdio/fputs.c stdio/fread.c stdio/freopen.c stdio/fscanf.c stdio/fseek.c stdio/ftell.c stdio/fwrite.c stdio/getc.c stdio/getchar.c stdio/perror.c stdio/printf.c stdio/putc.c stdio/putchar.c stdio/remove.c stdio/snprintf.c stdio/sprintf.c stdio/sscanf.c stdio/ungetc.c stdio/vfprintf.c stdio/vfscanf.c stdio/vprintf.c stdio/vsnprintf.c stdio/vsprintf.c stdio/vsscanf.c stdlib/abort.c stdlib/abs.c stdlib/alloca.c stdlib/atexit.c stdlib/atof.c stdlib/atoi.c stdlib/atol.c stdlib/calloc.c stdlib/__exit.c stdlib/exit.c stdlib/free.c stdlib/mbstowcs.c stdlib/puts.c stdlib/qsort.c stdlib/realloc.c stdlib/strtod.c stdlib/strtof.c stdlib/strtol.c stdlib/strtold.c stdlib/strtoll.c stdlib/strtoul.c stdlib/strtoull.c string/bcmp.c string/bcopy.c string/bzero.c string/index.c string/memchr.c string/memcmp.c string/memcpy.c string/memmem.c string/memmove.c string/memset.c string/rindex.c string/strcat.c string/strchr.c string/strcmp.c string/strcpy.c string/strcspn.c string/strdup.c string/strerror.c string/strlen.c string/strlwr.c string/strncat.c string/strncmp.c string/strncpy.c string/strpbrk.c string/strrchr.c string/strspn.c string/strstr.c string/strupr.c stub/atan2.c stub/bsearch.c stub/chown.c stub/__cleanup.c stub/cos.c stub/ctime.c stub/exp.c stub/fpurge.c stub/freadahead.c stub/frexp.c stub/getgrgid.c stub/getgrnam.c stub/getlogin.c stub/getpgid.c stub/getpgrp.c stub/getpwnam.c stub/getpwuid.c stub/gmtime.c stub/ldexp.c stub/localtime.c stub/log.c stub/mktime.c stub/modf.c stub/mprotect.c stub/pclose.c stub/popen.c stub/pow.c stub/rand.c stub/rewind.c stub/setbuf.c stub/setgrent.c stub/setlocale.c stub/setvbuf.c stub/sigaction.c stub/sigaddset.c stub/sigblock.c stub/sigdelset.c stub/sigemptyset.c stub/sigsetmask.c stub/sin.c stub/sys_siglist.c stub/system.c stub/sqrt.c stub/strftime.c stub/times.c stub/ttyname.c stub/umask.c stub/utime.c ${MES_ARCH}-mes-${MES_LIBC_SUFFIX}/setjmp.c cd .. +if match x${TCC_BOOTSTRAP_ALT} xTrue; then + +else # crt1.o tcc-mes -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crt1.o lib/linux/${MES_ARCH}-mes-${MES_LIBC_SUFFIX}/crt1.c catm ${LIBDIR}/crtn.o catm ${LIBDIR}/crti.o -if match ${ARCH} x86; then + +fi + +if match ${ARCH}${TCC_BOOTSTRAP_ALT} x86False; then # crtn.o tcc-mes -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crtn.o lib/linux/${MES_ARCH}-mes-gcc/crtn.c @@ -118,6 +128,14 @@ if match ${ARCH} x86; then tcc-mes -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crti.o lib/linux/${MES_ARCH}-mes-gcc/crti.c fi +if match ${ARCH}${TCC_BOOTSTRAP_ALT} x86True; then + tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${libdir}/crtn.o lib/linux/${MES_ARCH}-mes-gcc/crtn.c + tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${libdir}/crti.o lib/linux/${MES_ARCH}-mes-gcc/crti.c +fi + +if match x${TCC_BOOTSTRAP_ALT} xTrue; then + +else # libc+gcc.a tcc-mes -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o unified-libc.o unified-libc.c tcc-mes -ar cr ${LIBDIR}/libc.a unified-libc.o @@ -125,19 +143,31 @@ tcc-mes -ar cr ${LIBDIR}/libc.a unified-libc.o # libtcc1.a mkdir ${LIBDIR}/tcc tcc-mes -c -D HAVE_CONFIG_H=1 -D HAVE_LONG_LONG=1 -D HAVE_FLOAT=1 -I include -I include/linux/${MES_ARCH} -o libtcc1.o lib/libtcc1.c +fi + if match ${ARCH} riscv64; then tcc-mes -c -D HAVE_CONFIG_H=1 -D HAVE_LONG_LONG=1 -D HAVE_FLOAT=1 -I include -I include/linux/${MES_ARCH} -o lib-arm64.o ../${TCC_PKG}/lib/lib-arm64.c tcc-mes -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o lib-arm64.o -else +fi + +# LJW FIXME breaks other arches +if match x${ARCH}${TCC_BOOTSTRAP_ALT} xx86False; then tcc-mes -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o fi # libgetopt.a +if match x${TCC_BOOTSTRAP_ALT} xTrue; then + +else tcc-mes -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} lib/posix/getopt.c tcc-mes -ar cr ${LIBDIR}/libgetopt.a getopt.o +fi cd ../${TCC_PKG} +if match x${TCC_BOOTSTRAP_ALT} xTrue; then + +else # boot0 (ref comments here for all boot*) # compile tcc-mes \ @@ -170,6 +200,8 @@ tcc-mes \ tcc.c # Install cp tcc-boot0 ${BINDIR}/ +fi + chmod 755 ${BINDIR}/tcc-boot0 cd ../${MES_PKG} # Recompile libc: crt{1,n,i}, libtcc.a, libc.a From ddefe9fc0432752677ec359e224703c09fd7991b Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 22:13:13 +0000 Subject: [PATCH 14/49] more changes --- steps/tcc-0.9.26/pass1.kaem | 45 +++++++++++++++++++++++++++++++++---- 1 file changed, 41 insertions(+), 4 deletions(-) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index 60ee3ad6..cecffd4a 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -110,7 +110,8 @@ catm ../unified-libc.c ctype/isalnum.c ctype/isalpha.c ctype/isascii.c ctype/isc cd .. if match x${TCC_BOOTSTRAP_ALT} xTrue; then - +# Recompile libc: crt{1,n,i}, libtcc.a, libc.a +tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${libdir}/crt1.o lib/linux/${MES_ARCH}-mes-${MES_LIBC_SUFFIX}/crt1.c else # crt1.o tcc-mes -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crt1.o lib/linux/${MES_ARCH}-mes-${MES_LIBC_SUFFIX}/crt1.c @@ -134,7 +135,7 @@ if match ${ARCH}${TCC_BOOTSTRAP_ALT} x86True; then fi if match x${TCC_BOOTSTRAP_ALT} xTrue; then - +tcc-boot0 -c -D HAVE_CONFIG_H=1 -D HAVE_LONG_LONG=1 -D HAVE_FLOAT=1 -I include -I include/linux/${MES_ARCH} -o libtcc1.o lib/libtcc1.c else # libc+gcc.a tcc-mes -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o unified-libc.o unified-libc.c @@ -155,10 +156,10 @@ if match x${ARCH}${TCC_BOOTSTRAP_ALT} xx86False; then tcc-mes -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o fi -# libgetopt.a if match x${TCC_BOOTSTRAP_ALT} xTrue; then - +tcc-boot0 -c -D__linux__ -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o unified-libc.o unified-libc.c else +# libgetopt.a tcc-mes -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} lib/posix/getopt.c tcc-mes -ar cr ${LIBDIR}/libgetopt.a getopt.o fi @@ -166,6 +167,42 @@ fi cd ../${TCC_PKG} if match x${TCC_BOOTSTRAP_ALT} xTrue; then +mkdir /usr/lib/mes/tcc/ +# boot1 +tcc-boot0 \ + -nostdinc \ + -c \ + -o tcc-boot1.o \ + -D __linux__ \ + -D BOOTSTRAP=1 \ + -D HAVE_FLOAT=1 \ + -D HAVE_BITFIELD=1 \ + -D HAVE_LONG_LONG=0 \ + -D HAVE_SETJMP=1 \ + -I /usr/include/ \ + -I . \ + -I ${prefix}/include \ + -D TCC_TARGET_${TCC_TARGET_ARCH}=1 \ + -D CONFIG_TCCDIR=\"${libdir}/tcc\" \ + -D CONFIG_TCC_CRTPREFIX=\"${libdir}\" \ + -D CONFIG_TCC_ELFINTERP=\"/mes/loader\" \ + -D CONFIG_TCC_LIBPATHS=\"${libdir}:${libdir}/tcc\" \ + -D CONFIG_TCC_SYSINCLUDEPATHS=\"${prefix}/include\" \ + -D TCC_LIBGCC=\"${libdir}/libc.a\" \ + -D TCC_LIBTCC1=\"libtcc1.a\" \ + -D CONFIG_TCCBOOT=1 \ + -D CONFIG_TCC_STATIC=1 \ + -D CONFIG_USE_LIBGCC=1 \ + -D TCC_VERSION=\"0.9.26\" \ + -D ONE_SOURCE=1 \ + tcc.c + +tcc-boot0 -static -nostdlib /usr/lib/mes/crt1.o ../mes-0.25/unified-libc.o ../mes-0.25/libtcc1.o tcc-boot1.o -o tcc-boot0-new + +#replace tcc-boot0 with full one + +cp tcc-boot0-new ${bindir}/tcc-boot0 + else # boot0 (ref comments here for all boot*) From a2dd7888d4be0703c9c9a6051ece197f7bc51a39 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 22:25:37 +0000 Subject: [PATCH 15/49] update include directory --- steps/tcc-0.9.26/pass1.kaem | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index cecffd4a..7a8dc66f 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -187,7 +187,7 @@ tcc-boot0 \ -D CONFIG_TCC_CRTPREFIX=\"${libdir}\" \ -D CONFIG_TCC_ELFINTERP=\"/mes/loader\" \ -D CONFIG_TCC_LIBPATHS=\"${libdir}:${libdir}/tcc\" \ - -D CONFIG_TCC_SYSINCLUDEPATHS=\"${prefix}/include\" \ + -D CONFIG_TCC_SYSINCLUDEPATHS=\"${prefix}/include/mes\" \ -D TCC_LIBGCC=\"${libdir}/libc.a\" \ -D TCC_LIBTCC1=\"libtcc1.a\" \ -D CONFIG_TCCBOOT=1 \ From 46efeb6e123034d4d4e024ff3372f169e25248ec Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 22:38:19 +0000 Subject: [PATCH 16/49] fix env vars --- steps/tcc-0.9.26/pass1.kaem | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index 7a8dc66f..f63a9c32 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -111,7 +111,7 @@ cd .. if match x${TCC_BOOTSTRAP_ALT} xTrue; then # Recompile libc: crt{1,n,i}, libtcc.a, libc.a -tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${libdir}/crt1.o lib/linux/${MES_ARCH}-mes-${MES_LIBC_SUFFIX}/crt1.c +tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crt1.o lib/linux/${MES_ARCH}-mes-${MES_LIBC_SUFFIX}/crt1.c else # crt1.o tcc-mes -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crt1.o lib/linux/${MES_ARCH}-mes-${MES_LIBC_SUFFIX}/crt1.c @@ -130,8 +130,8 @@ if match ${ARCH}${TCC_BOOTSTRAP_ALT} x86False; then fi if match ${ARCH}${TCC_BOOTSTRAP_ALT} x86True; then - tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${libdir}/crtn.o lib/linux/${MES_ARCH}-mes-gcc/crtn.c - tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${libdir}/crti.o lib/linux/${MES_ARCH}-mes-gcc/crti.c + tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crtn.o lib/linux/${MES_ARCH}-mes-gcc/crtn.c + tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crti.o lib/linux/${MES_ARCH}-mes-gcc/crti.c fi if match x${TCC_BOOTSTRAP_ALT} xTrue; then @@ -181,14 +181,14 @@ tcc-boot0 \ -D HAVE_SETJMP=1 \ -I /usr/include/ \ -I . \ - -I ${prefix}/include \ + -I ${PREFIX}/include \ -D TCC_TARGET_${TCC_TARGET_ARCH}=1 \ - -D CONFIG_TCCDIR=\"${libdir}/tcc\" \ - -D CONFIG_TCC_CRTPREFIX=\"${libdir}\" \ + -D CONFIG_TCCDIR=\"${LIBDIR}/tcc\" \ + -D CONFIG_TCC_CRTPREFIX=\"${LIBDIR}\" \ -D CONFIG_TCC_ELFINTERP=\"/mes/loader\" \ - -D CONFIG_TCC_LIBPATHS=\"${libdir}:${libdir}/tcc\" \ - -D CONFIG_TCC_SYSINCLUDEPATHS=\"${prefix}/include/mes\" \ - -D TCC_LIBGCC=\"${libdir}/libc.a\" \ + -D CONFIG_TCC_LIBPATHS=\"${LIBDIR}:${LIBDIR}/tcc\" \ + -D CONFIG_TCC_SYSINCLUDEPATHS=\"${PREFIX}/include/mes\" \ + -D TCC_LIBGCC=\"${LIBDIR}/libc.a\" \ -D TCC_LIBTCC1=\"libtcc1.a\" \ -D CONFIG_TCCBOOT=1 \ -D CONFIG_TCC_STATIC=1 \ @@ -201,7 +201,7 @@ tcc-boot0 -static -nostdlib /usr/lib/mes/crt1.o ../mes-0.25/unified-libc.o ../me #replace tcc-boot0 with full one -cp tcc-boot0-new ${bindir}/tcc-boot0 +cp tcc-boot0-new ${BINDIR}/tcc-boot0 else From a9fb3814e1c2d6ce5d2dcf33eea6641db6f8de0d Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 23:17:03 +0000 Subject: [PATCH 17/49] try to fix includes --- steps/tcc-0.9.26/pass1.kaem | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index f63a9c32..e67884a4 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -157,7 +157,7 @@ if match x${ARCH}${TCC_BOOTSTRAP_ALT} xx86False; then fi if match x${TCC_BOOTSTRAP_ALT} xTrue; then -tcc-boot0 -c -D__linux__ -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o unified-libc.o unified-libc.c +tcc-boot0 -c -D__linux__ -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -I /usr/include/mes/ -o unified-libc.o unified-libc.c else # libgetopt.a tcc-mes -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} lib/posix/getopt.c From 2f158fc9449dc9f993db2a768461be365fe12852 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 23:21:46 +0000 Subject: [PATCH 18/49] more include fixing --- steps/tcc-0.9.26/pass1.kaem | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index e67884a4..7d89d452 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -179,7 +179,7 @@ tcc-boot0 \ -D HAVE_BITFIELD=1 \ -D HAVE_LONG_LONG=0 \ -D HAVE_SETJMP=1 \ - -I /usr/include/ \ + -I /usr/include/mes/ \ -I . \ -I ${PREFIX}/include \ -D TCC_TARGET_${TCC_TARGET_ARCH}=1 \ From 33be2c00802444ad387b46e0604cd2b892296549 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 23:30:48 +0000 Subject: [PATCH 19/49] do not check checksums for tcc-0.9.26 when using tcc_bootstrap_alt --- steps/tcc-0.9.26/pass1.kaem | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index 7d89d452..272fb992 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -383,7 +383,7 @@ tcc -ar cr ${LIBDIR}/libgetopt.a getopt.o cd ../.. # Checksums -if match x${UPDATE_CHECKSUMS} xTrue; then +if match x${UPDATE_CHECKSUMS}${TCC_BOOTSTRAP_ALT} xTrueFalse; then sha256sum -o ${pkg}.checksums \ /usr/bin/tcc-mes \ /usr/bin/tcc-boot0 \ @@ -397,6 +397,7 @@ if match x${UPDATE_CHECKSUMS} xTrue; then /usr/lib/mes/tcc/libtcc1.a cp ${pkg}.checksums ${SRCDIR} -else +fi +if match x${UPDATE_CHECKSUMS}${TCC_BOOTSTRAP_ALT} xFalseFalse; then sha256sum -c ${pkg}.${ARCH}.checksums fi From 64e36591bc8c25d816a5071199d5426660f1d042 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 23:38:17 +0000 Subject: [PATCH 20/49] Revert "temp abort after 0.9.27 build" This reverts commit b4068aaba50cbf9169ad50e355612d7ac17f02c1. --- steps/tcc-0.9.27/pass1.kaem | 3 --- 1 file changed, 3 deletions(-) diff --git a/steps/tcc-0.9.27/pass1.kaem b/steps/tcc-0.9.27/pass1.kaem index e7fa478f..b7fcf21c 100755 --- a/steps/tcc-0.9.27/pass1.kaem +++ b/steps/tcc-0.9.27/pass1.kaem @@ -84,6 +84,3 @@ if match x${UPDATE_CHECKSUMS} xTrue; then else sha256sum -c ${pkg}.checksums fi - -# LJW HACK stop here -exit 1 From 876e0ed78df6a66e117aa44ee3284ea1cf360087 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 23:49:45 +0000 Subject: [PATCH 21/49] Revert "Revert "temp abort after 0.9.27 build"" This reverts commit 64e36591bc8c25d816a5071199d5426660f1d042. --- steps/tcc-0.9.27/pass1.kaem | 3 +++ 1 file changed, 3 insertions(+) diff --git a/steps/tcc-0.9.27/pass1.kaem b/steps/tcc-0.9.27/pass1.kaem index b7fcf21c..e7fa478f 100755 --- a/steps/tcc-0.9.27/pass1.kaem +++ b/steps/tcc-0.9.27/pass1.kaem @@ -84,3 +84,6 @@ if match x${UPDATE_CHECKSUMS} xTrue; then else sha256sum -c ${pkg}.checksums fi + +# LJW HACK stop here +exit 1 From a3368747af29dc7720f1e8c165f1a179fb69d094 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 10 Jan 2024 23:50:25 +0000 Subject: [PATCH 22/49] test non-tcc_bootstrap_alt path --- .github/workflows/bwrap.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/bwrap.yml b/.github/workflows/bwrap.yml index bb8e925b..66cea846 100644 --- a/.github/workflows/bwrap.yml +++ b/.github/workflows/bwrap.yml @@ -43,7 +43,7 @@ jobs: distfiles key: cache-${{ hashFiles('steps/*/sources') }} - name: Run bootstrap - run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 --tcc_bootstrap_alt + run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 - name: Archive created packages if: failure() # archive failed builds progress uses: actions/upload-artifact@v3 From c16e1fd52fa71a8176395b548dfcd130c408f216 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Thu, 11 Jan 2024 00:06:48 +0000 Subject: [PATCH 23/49] Revert "test non-tcc_bootstrap_alt path" This reverts commit a3368747af29dc7720f1e8c165f1a179fb69d094. --- .github/workflows/bwrap.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/bwrap.yml b/.github/workflows/bwrap.yml index 66cea846..bb8e925b 100644 --- a/.github/workflows/bwrap.yml +++ b/.github/workflows/bwrap.yml @@ -43,7 +43,7 @@ jobs: distfiles key: cache-${{ hashFiles('steps/*/sources') }} - name: Run bootstrap - run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 + run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 --tcc_bootstrap_alt - name: Archive created packages if: failure() # archive failed builds progress uses: actions/upload-artifact@v3 From 488904419ad13d4d7c9dc26dd8f13dd4648704b0 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Thu, 11 Jan 2024 00:07:21 +0000 Subject: [PATCH 24/49] allow run past tcc-0.9.27 to test full run --- steps/tcc-0.9.27/pass1.kaem | 3 --- 1 file changed, 3 deletions(-) diff --git a/steps/tcc-0.9.27/pass1.kaem b/steps/tcc-0.9.27/pass1.kaem index e7fa478f..b7fcf21c 100755 --- a/steps/tcc-0.9.27/pass1.kaem +++ b/steps/tcc-0.9.27/pass1.kaem @@ -84,6 +84,3 @@ if match x${UPDATE_CHECKSUMS} xTrue; then else sha256sum -c ${pkg}.checksums fi - -# LJW HACK stop here -exit 1 From 520656edc8257236286438a48e2ba3d15c78031d Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Thu, 11 Jan 2024 13:46:49 +0000 Subject: [PATCH 25/49] test mes bootstrap path to make sure it's not broken --- .github/workflows/bwrap.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/bwrap.yml b/.github/workflows/bwrap.yml index bb8e925b..66cea846 100644 --- a/.github/workflows/bwrap.yml +++ b/.github/workflows/bwrap.yml @@ -43,7 +43,7 @@ jobs: distfiles key: cache-${{ hashFiles('steps/*/sources') }} - name: Run bootstrap - run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 --tcc_bootstrap_alt + run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 - name: Archive created packages if: failure() # archive failed builds progress uses: actions/upload-artifact@v3 From 949d5b8c76b567bfb249422b6240a743e62116cb Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Thu, 11 Jan 2024 21:15:44 +0000 Subject: [PATCH 26/49] try checking tcc-0.9.26 checksums even when using the TCC_BOOTSTRAP_ALT path --- steps/tcc-0.9.26/pass1.kaem | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index 272fb992..7d89d452 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -383,7 +383,7 @@ tcc -ar cr ${LIBDIR}/libgetopt.a getopt.o cd ../.. # Checksums -if match x${UPDATE_CHECKSUMS}${TCC_BOOTSTRAP_ALT} xTrueFalse; then +if match x${UPDATE_CHECKSUMS} xTrue; then sha256sum -o ${pkg}.checksums \ /usr/bin/tcc-mes \ /usr/bin/tcc-boot0 \ @@ -397,7 +397,6 @@ if match x${UPDATE_CHECKSUMS}${TCC_BOOTSTRAP_ALT} xTrueFalse; then /usr/lib/mes/tcc/libtcc1.a cp ${pkg}.checksums ${SRCDIR} -fi -if match x${UPDATE_CHECKSUMS}${TCC_BOOTSTRAP_ALT} xFalseFalse; then +else sha256sum -c ${pkg}.${ARCH}.checksums fi From b19dff97bc35f16443286eb8af01df42d88bded6 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Thu, 11 Jan 2024 21:16:32 +0000 Subject: [PATCH 27/49] Revert "test mes bootstrap path to make sure it's not broken" This reverts commit 520656edc8257236286438a48e2ba3d15c78031d. --- .github/workflows/bwrap.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/bwrap.yml b/.github/workflows/bwrap.yml index 66cea846..bb8e925b 100644 --- a/.github/workflows/bwrap.yml +++ b/.github/workflows/bwrap.yml @@ -43,7 +43,7 @@ jobs: distfiles key: cache-${{ hashFiles('steps/*/sources') }} - name: Run bootstrap - run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 + run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 --tcc_bootstrap_alt - name: Archive created packages if: failure() # archive failed builds progress uses: actions/upload-artifact@v3 From 9623db5dc1136d60ee9738e7bfadc08a29b875be Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Thu, 11 Jan 2024 21:54:17 +0000 Subject: [PATCH 28/49] add dummy tcc-mes --- steps/tcc-0.9.26/pass1.kaem | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index 7d89d452..c180261c 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -168,6 +168,10 @@ cd ../${TCC_PKG} if match x${TCC_BOOTSTRAP_ALT} xTrue; then mkdir /usr/lib/mes/tcc/ + +# dummy tcc-mes +catm /usr/bin/tcc-mes + # boot1 tcc-boot0 \ -nostdinc \ From 3c840e66c738f3f15c4dabeabc168f15e7016011 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Fri, 12 Jan 2024 02:05:29 +0000 Subject: [PATCH 29/49] test rebuilding tcc-boot2 with itself --- steps/tcc-0.9.26/pass1.kaem | 49 +++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index c180261c..0b887806 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -368,6 +368,55 @@ tcc-boot2 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o unifi tcc-boot2 -ar cr ${LIBDIR}/libc.a unified-libc.o cd ../${TCC_PKG} +# rebuild tcc-boot2 with itself +tcc-boot2 \ + -g \ + -v \ + -static \ + -o tcc-boot2 \ + -D BOOTSTRAP=1 \ + -D HAVE_BITFIELD=1 \ + -D HAVE_FLOAT=1 \ + -D HAVE_LONG_LONG=1 \ + -D HAVE_SETJMP=1 \ + -I . \ + -I ${PREFIX}/include/mes \ + -D TCC_TARGET_${TCC_TARGET_ARCH}=1 \ + -D CONFIG_TCCDIR=\"${LIBDIR}/tcc\" \ + -D CONFIG_TCC_CRTPREFIX=\"${LIBDIR}\" \ + -D CONFIG_TCC_ELFINTERP=\"/mes/loader\" \ + -D CONFIG_TCC_LIBPATHS=\"${LIBDIR}:${LIBDIR}/tcc\" \ + -D CONFIG_TCC_SYSINCLUDEPATHS=\"${PREFIX}/include/mes\" \ + -D TCC_LIBGCC=\"${LIBDIR}/libc.a\" \ + -D TCC_LIBTCC1=\"libtcc1.a\" \ + -D CONFIG_TCCBOOT=1 \ + -D CONFIG_TCC_STATIC=1 \ + -D CONFIG_USE_LIBGCC=1 \ + -D TCC_VERSION=\"0.9.26\" \ + -D ONE_SOURCE=1 \ + -L . \ + tcc.c +cp tcc-boot2 ${BINDIR} +chmod 755 ${BINDIR}/tcc-boot2 +cd ../${MES_PKG} +tcc-boot2 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crt1.o lib/linux/${MES_ARCH}-mes-${MES_LIBC_SUFFIX}/crt1.c +if match ${ARCH} x86; then + tcc-boot2 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crtn.o lib/linux/${MES_ARCH}-mes-gcc/crtn.c + tcc-boot2 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crti.o lib/linux/${MES_ARCH}-mes-gcc/crti.c +fi + +tcc-boot2 -c -D HAVE_CONFIG_H=1 -D HAVE_LONG_LONG=1 -D HAVE_FLOAT=1 -I include -I include/linux/${MES_ARCH} -o libtcc1.o lib/libtcc1.c +if match ${ARCH} riscv64; then + tcc-boot2 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o lib-arm64.o ../${TCC_PKG}/lib/lib-arm64.c + tcc-boot2 -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o lib-arm64.o +else + tcc-boot2 -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o +fi + +tcc-boot2 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o unified-libc.o unified-libc.c +tcc-boot2 -ar cr ${LIBDIR}/libc.a unified-libc.o +cd ../${TCC_PKG} + # Test boot2 tcc-boot2 -version From e8c0b99a09f3f32dc58888d91a6c4222481657ba Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Fri, 12 Jan 2024 02:48:11 +0000 Subject: [PATCH 30/49] rebuild tcc-boot0 with itself --- steps/tcc-0.9.26/pass1.kaem | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index 0b887806..a41be089 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -264,6 +264,38 @@ tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o unifi tcc-boot0 -ar cr ${LIBDIR}/libc.a unified-libc.o cd ../${TCC_PKG} +# rebuild tcc-boot0 with itself +tcc-boot0 \ + -g \ + -v \ + -static \ + -o tcc-boot0 \ + -D BOOTSTRAP=1 \ + -D HAVE_FLOAT=1 \ + -D HAVE_BITFIELD=1 \ + -D HAVE_LONG_LONG=1 \ + -D HAVE_SETJMP=1 \ + -I . \ + -I ${PREFIX}/include/mes \ + -D TCC_TARGET_${TCC_TARGET_ARCH}=1 \ + -D CONFIG_TCCDIR=\"${LIBDIR}/tcc\" \ + -D CONFIG_TCC_CRTPREFIX=\"${LIBDIR}\" \ + -D CONFIG_TCC_ELFINTERP=\"/mes/loader\" \ + -D CONFIG_TCC_LIBPATHS=\"${LIBDIR}:${LIBDIR}/tcc\" \ + -D CONFIG_TCC_SYSINCLUDEPATHS=\"${PREFIX}/include/mes\" \ + -D TCC_LIBGCC=\"${LIBDIR}/libc.a\" \ + -D TCC_LIBTCC1=\"libtcc1.a\" \ + -D CONFIG_TCCBOOT=1 \ + -D CONFIG_TCC_STATIC=1 \ + -D CONFIG_USE_LIBGCC=1 \ + -D TCC_VERSION=\"0.9.26\" \ + -D ONE_SOURCE=1 \ + -L . \ + -L ${LIBDIR} \ + tcc.c +# Install +cp tcc-boot0 ${BINDIR}/ + # Test boot0 tcc-boot0 -version From 451435852ee2c857ad7bb36d9df6c7357e597ad7 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Fri, 12 Jan 2024 02:59:35 +0000 Subject: [PATCH 31/49] rebuilt tcc-boot0 again --- steps/tcc-0.9.26/pass1.kaem | 71 +++++++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index a41be089..2af86d06 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -296,6 +296,77 @@ tcc-boot0 \ # Install cp tcc-boot0 ${BINDIR}/ +chmod 755 ${BINDIR}/tcc-boot0 +cd ../${MES_PKG} +# Recompile libc: crt{1,n,i}, libtcc.a, libc.a +tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crt1.o lib/linux/${MES_ARCH}-mes-${MES_LIBC_SUFFIX}/crt1.c +if match ${ARCH} x86; then + tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crtn.o lib/linux/${MES_ARCH}-mes-gcc/crtn.c + tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crti.o lib/linux/${MES_ARCH}-mes-gcc/crti.c +fi + +tcc-boot0 -c -D HAVE_CONFIG_H=1 -D HAVE_LONG_LONG=1 -D HAVE_FLOAT=1 -I include -I include/linux/${MES_ARCH} -o libtcc1.o lib/libtcc1.c +if match ${ARCH} riscv64; then + tcc-boot0 -c -D HAVE_CONFIG_H=1 -D HAVE_LONG_LONG=1 -D HAVE_FLOAT=1 -I include -I include/linux/${MES_ARCH} -o lib-arm64.o ../${TCC_PKG}/lib/lib-arm64.c + tcc-boot0 -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o lib-arm64.o +else + tcc-boot0 -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o +fi + +tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o unified-libc.o unified-libc.c +tcc-boot0 -ar cr ${LIBDIR}/libc.a unified-libc.o + +# rebuild tcc-boot0 with itself again +tcc-boot0 \ + -g \ + -v \ + -static \ + -o tcc-boot0 \ + -D BOOTSTRAP=1 \ + -D HAVE_FLOAT=1 \ + -D HAVE_BITFIELD=1 \ + -D HAVE_LONG_LONG=1 \ + -D HAVE_SETJMP=1 \ + -I . \ + -I ${PREFIX}/include/mes \ + -D TCC_TARGET_${TCC_TARGET_ARCH}=1 \ + -D CONFIG_TCCDIR=\"${LIBDIR}/tcc\" \ + -D CONFIG_TCC_CRTPREFIX=\"${LIBDIR}\" \ + -D CONFIG_TCC_ELFINTERP=\"/mes/loader\" \ + -D CONFIG_TCC_LIBPATHS=\"${LIBDIR}:${LIBDIR}/tcc\" \ + -D CONFIG_TCC_SYSINCLUDEPATHS=\"${PREFIX}/include/mes\" \ + -D TCC_LIBGCC=\"${LIBDIR}/libc.a\" \ + -D TCC_LIBTCC1=\"libtcc1.a\" \ + -D CONFIG_TCCBOOT=1 \ + -D CONFIG_TCC_STATIC=1 \ + -D CONFIG_USE_LIBGCC=1 \ + -D TCC_VERSION=\"0.9.26\" \ + -D ONE_SOURCE=1 \ + -L . \ + -L ${LIBDIR} \ + tcc.c +# Install +cp tcc-boot0 ${BINDIR}/ + +chmod 755 ${BINDIR}/tcc-boot0 +cd ../${MES_PKG} +# Recompile libc: crt{1,n,i}, libtcc.a, libc.a +tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crt1.o lib/linux/${MES_ARCH}-mes-${MES_LIBC_SUFFIX}/crt1.c +if match ${ARCH} x86; then + tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crtn.o lib/linux/${MES_ARCH}-mes-gcc/crtn.c + tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crti.o lib/linux/${MES_ARCH}-mes-gcc/crti.c +fi + +tcc-boot0 -c -D HAVE_CONFIG_H=1 -D HAVE_LONG_LONG=1 -D HAVE_FLOAT=1 -I include -I include/linux/${MES_ARCH} -o libtcc1.o lib/libtcc1.c +if match ${ARCH} riscv64; then + tcc-boot0 -c -D HAVE_CONFIG_H=1 -D HAVE_LONG_LONG=1 -D HAVE_FLOAT=1 -I include -I include/linux/${MES_ARCH} -o lib-arm64.o ../${TCC_PKG}/lib/lib-arm64.c + tcc-boot0 -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o lib-arm64.o +else + tcc-boot0 -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o +fi + +tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o unified-libc.o unified-libc.c +tcc-boot0 -ar cr ${LIBDIR}/libc.a unified-libc.o # Test boot0 tcc-boot0 -version From b8d11bfe25a1ebdf6065046f48bd3b8376cc10e1 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Fri, 12 Jan 2024 03:05:52 +0000 Subject: [PATCH 32/49] missing cd --- steps/tcc-0.9.26/pass1.kaem | 1 + 1 file changed, 1 insertion(+) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index 2af86d06..8141ca95 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -315,6 +315,7 @@ fi tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o unified-libc.o unified-libc.c tcc-boot0 -ar cr ${LIBDIR}/libc.a unified-libc.o +cd ../${TCC_PKG} # rebuild tcc-boot0 with itself again tcc-boot0 \ From d2c5f8b51866d75060b79e68011d921a27c762ba Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Fri, 12 Jan 2024 03:11:07 +0000 Subject: [PATCH 33/49] another missing cd --- steps/tcc-0.9.26/pass1.kaem | 2 ++ 1 file changed, 2 insertions(+) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index 8141ca95..5f84e1bd 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -368,6 +368,8 @@ fi tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o unified-libc.o unified-libc.c tcc-boot0 -ar cr ${LIBDIR}/libc.a unified-libc.o +cd ../${TCC_PKG} + # Test boot0 tcc-boot0 -version From f4eda660f019804e05386794c5493dee6bb8e1ea Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Fri, 12 Jan 2024 03:22:47 +0000 Subject: [PATCH 34/49] revert tcc-boot0 rebuilds --- steps/tcc-0.9.26/pass1.kaem | 106 ------------------------------------ 1 file changed, 106 deletions(-) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index 5f84e1bd..0b887806 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -264,112 +264,6 @@ tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o unifi tcc-boot0 -ar cr ${LIBDIR}/libc.a unified-libc.o cd ../${TCC_PKG} -# rebuild tcc-boot0 with itself -tcc-boot0 \ - -g \ - -v \ - -static \ - -o tcc-boot0 \ - -D BOOTSTRAP=1 \ - -D HAVE_FLOAT=1 \ - -D HAVE_BITFIELD=1 \ - -D HAVE_LONG_LONG=1 \ - -D HAVE_SETJMP=1 \ - -I . \ - -I ${PREFIX}/include/mes \ - -D TCC_TARGET_${TCC_TARGET_ARCH}=1 \ - -D CONFIG_TCCDIR=\"${LIBDIR}/tcc\" \ - -D CONFIG_TCC_CRTPREFIX=\"${LIBDIR}\" \ - -D CONFIG_TCC_ELFINTERP=\"/mes/loader\" \ - -D CONFIG_TCC_LIBPATHS=\"${LIBDIR}:${LIBDIR}/tcc\" \ - -D CONFIG_TCC_SYSINCLUDEPATHS=\"${PREFIX}/include/mes\" \ - -D TCC_LIBGCC=\"${LIBDIR}/libc.a\" \ - -D TCC_LIBTCC1=\"libtcc1.a\" \ - -D CONFIG_TCCBOOT=1 \ - -D CONFIG_TCC_STATIC=1 \ - -D CONFIG_USE_LIBGCC=1 \ - -D TCC_VERSION=\"0.9.26\" \ - -D ONE_SOURCE=1 \ - -L . \ - -L ${LIBDIR} \ - tcc.c -# Install -cp tcc-boot0 ${BINDIR}/ - -chmod 755 ${BINDIR}/tcc-boot0 -cd ../${MES_PKG} -# Recompile libc: crt{1,n,i}, libtcc.a, libc.a -tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crt1.o lib/linux/${MES_ARCH}-mes-${MES_LIBC_SUFFIX}/crt1.c -if match ${ARCH} x86; then - tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crtn.o lib/linux/${MES_ARCH}-mes-gcc/crtn.c - tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crti.o lib/linux/${MES_ARCH}-mes-gcc/crti.c -fi - -tcc-boot0 -c -D HAVE_CONFIG_H=1 -D HAVE_LONG_LONG=1 -D HAVE_FLOAT=1 -I include -I include/linux/${MES_ARCH} -o libtcc1.o lib/libtcc1.c -if match ${ARCH} riscv64; then - tcc-boot0 -c -D HAVE_CONFIG_H=1 -D HAVE_LONG_LONG=1 -D HAVE_FLOAT=1 -I include -I include/linux/${MES_ARCH} -o lib-arm64.o ../${TCC_PKG}/lib/lib-arm64.c - tcc-boot0 -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o lib-arm64.o -else - tcc-boot0 -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o -fi - -tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o unified-libc.o unified-libc.c -tcc-boot0 -ar cr ${LIBDIR}/libc.a unified-libc.o -cd ../${TCC_PKG} - -# rebuild tcc-boot0 with itself again -tcc-boot0 \ - -g \ - -v \ - -static \ - -o tcc-boot0 \ - -D BOOTSTRAP=1 \ - -D HAVE_FLOAT=1 \ - -D HAVE_BITFIELD=1 \ - -D HAVE_LONG_LONG=1 \ - -D HAVE_SETJMP=1 \ - -I . \ - -I ${PREFIX}/include/mes \ - -D TCC_TARGET_${TCC_TARGET_ARCH}=1 \ - -D CONFIG_TCCDIR=\"${LIBDIR}/tcc\" \ - -D CONFIG_TCC_CRTPREFIX=\"${LIBDIR}\" \ - -D CONFIG_TCC_ELFINTERP=\"/mes/loader\" \ - -D CONFIG_TCC_LIBPATHS=\"${LIBDIR}:${LIBDIR}/tcc\" \ - -D CONFIG_TCC_SYSINCLUDEPATHS=\"${PREFIX}/include/mes\" \ - -D TCC_LIBGCC=\"${LIBDIR}/libc.a\" \ - -D TCC_LIBTCC1=\"libtcc1.a\" \ - -D CONFIG_TCCBOOT=1 \ - -D CONFIG_TCC_STATIC=1 \ - -D CONFIG_USE_LIBGCC=1 \ - -D TCC_VERSION=\"0.9.26\" \ - -D ONE_SOURCE=1 \ - -L . \ - -L ${LIBDIR} \ - tcc.c -# Install -cp tcc-boot0 ${BINDIR}/ - -chmod 755 ${BINDIR}/tcc-boot0 -cd ../${MES_PKG} -# Recompile libc: crt{1,n,i}, libtcc.a, libc.a -tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crt1.o lib/linux/${MES_ARCH}-mes-${MES_LIBC_SUFFIX}/crt1.c -if match ${ARCH} x86; then - tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crtn.o lib/linux/${MES_ARCH}-mes-gcc/crtn.c - tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o ${LIBDIR}/crti.o lib/linux/${MES_ARCH}-mes-gcc/crti.c -fi - -tcc-boot0 -c -D HAVE_CONFIG_H=1 -D HAVE_LONG_LONG=1 -D HAVE_FLOAT=1 -I include -I include/linux/${MES_ARCH} -o libtcc1.o lib/libtcc1.c -if match ${ARCH} riscv64; then - tcc-boot0 -c -D HAVE_CONFIG_H=1 -D HAVE_LONG_LONG=1 -D HAVE_FLOAT=1 -I include -I include/linux/${MES_ARCH} -o lib-arm64.o ../${TCC_PKG}/lib/lib-arm64.c - tcc-boot0 -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o lib-arm64.o -else - tcc-boot0 -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o -fi - -tcc-boot0 -c -D HAVE_CONFIG_H=1 -I include -I include/linux/${MES_ARCH} -o unified-libc.o unified-libc.c -tcc-boot0 -ar cr ${LIBDIR}/libc.a unified-libc.o -cd ../${TCC_PKG} - # Test boot0 tcc-boot0 -version From be89270ae09e59cce818e7e2e56590cf4b0f578e Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Fri, 12 Jan 2024 03:28:37 +0000 Subject: [PATCH 35/49] test mes mode again --- .github/workflows/bwrap.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/bwrap.yml b/.github/workflows/bwrap.yml index bb8e925b..66cea846 100644 --- a/.github/workflows/bwrap.yml +++ b/.github/workflows/bwrap.yml @@ -43,7 +43,7 @@ jobs: distfiles key: cache-${{ hashFiles('steps/*/sources') }} - name: Run bootstrap - run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 --tcc_bootstrap_alt + run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 - name: Archive created packages if: failure() # archive failed builds progress uses: actions/upload-artifact@v3 From 7ac17b5c5e79f6bffda3176f6a5a405dce220b27 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Fri, 12 Jan 2024 05:25:15 +0000 Subject: [PATCH 36/49] Revert "test mes mode again" This reverts commit be89270ae09e59cce818e7e2e56590cf4b0f578e. --- .github/workflows/bwrap.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/bwrap.yml b/.github/workflows/bwrap.yml index 66cea846..bb8e925b 100644 --- a/.github/workflows/bwrap.yml +++ b/.github/workflows/bwrap.yml @@ -43,7 +43,7 @@ jobs: distfiles key: cache-${{ hashFiles('steps/*/sources') }} - name: Run bootstrap - run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 + run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 --tcc_bootstrap_alt - name: Archive created packages if: failure() # archive failed builds progress uses: actions/upload-artifact@v3 From ba4c8b4ae7cad1cd338d26520b672ba0647f052e Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Fri, 12 Jan 2024 05:36:24 +0000 Subject: [PATCH 37/49] start splitting tcc-0.9.26 hashes --- steps/tcc-0.9.26/pass1.kaem | 9 ++++++--- steps/tcc-0.9.26/tcc-0.9.26.x86.checksums | 3 --- steps/tcc-0.9.26/tcc-0.9.26_mes.x86.checksums | 3 +++ 3 files changed, 9 insertions(+), 6 deletions(-) create mode 100644 steps/tcc-0.9.26/tcc-0.9.26_mes.x86.checksums diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index 0b887806..8aa4948e 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -369,6 +369,7 @@ tcc-boot2 -ar cr ${LIBDIR}/libc.a unified-libc.o cd ../${TCC_PKG} # rebuild tcc-boot2 with itself +# LJW FIXME find a neater way to repeat this step (maybe a separate kaem script) tcc-boot2 \ -g \ -v \ @@ -438,9 +439,6 @@ cd ../.. # Checksums if match x${UPDATE_CHECKSUMS} xTrue; then sha256sum -o ${pkg}.checksums \ - /usr/bin/tcc-mes \ - /usr/bin/tcc-boot0 \ - /usr/bin/tcc-boot1 \ /usr/bin/tcc \ /usr/lib/mes/libc.a \ /usr/lib/mes/libgetopt.a \ @@ -453,3 +451,8 @@ if match x${UPDATE_CHECKSUMS} xTrue; then else sha256sum -c ${pkg}.${ARCH}.checksums fi + +# LJW FIXME only check hashes for following files when doing mes builds: +# /usr/bin/tcc-mes \ +# /usr/bin/tcc-boot0 \ +# /usr/bin/tcc-boot1 \ diff --git a/steps/tcc-0.9.26/tcc-0.9.26.x86.checksums b/steps/tcc-0.9.26/tcc-0.9.26.x86.checksums index 0bbd8607..dd13baa3 100644 --- a/steps/tcc-0.9.26/tcc-0.9.26.x86.checksums +++ b/steps/tcc-0.9.26/tcc-0.9.26.x86.checksums @@ -1,6 +1,3 @@ -f3c51ecb0e5d0865822dd0e83dc459ccfd2576ecad845bc888558ab010e2a609 /usr/bin/tcc-mes -b758fff28f3d03b057b0414eb92da0c46e22bc8e9da29af33fbe65b01047d25d /usr/bin/tcc-boot0 -56e267e3031f548ea155d61a97fc3e6e8fff277159d7ae3273820a8c0f4582a0 /usr/bin/tcc-boot1 3404d1e8f61be09c1caeba03dcf99abae8881a485fe13160e6bb5fe44538d378 /usr/bin/tcc 3bfd10dfe347c4fb40fbf5f2f705cd806c77e0f80cf4ad1ecfd4beddada2937c /usr/lib/mes/libc.a 12c07ae103e7e3b390150a79e5c600d88de14e9bb73a066f6342582729ef5a3f /usr/lib/mes/libgetopt.a diff --git a/steps/tcc-0.9.26/tcc-0.9.26_mes.x86.checksums b/steps/tcc-0.9.26/tcc-0.9.26_mes.x86.checksums new file mode 100644 index 00000000..69e547ea --- /dev/null +++ b/steps/tcc-0.9.26/tcc-0.9.26_mes.x86.checksums @@ -0,0 +1,3 @@ +f3c51ecb0e5d0865822dd0e83dc459ccfd2576ecad845bc888558ab010e2a609 /usr/bin/tcc-mes +b758fff28f3d03b057b0414eb92da0c46e22bc8e9da29af33fbe65b01047d25d /usr/bin/tcc-boot0 +56e267e3031f548ea155d61a97fc3e6e8fff277159d7ae3273820a8c0f4582a0 /usr/bin/tcc-boot1 From a87e0b025e416bf53588fd4b1da6d4ecfa887e1a Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Fri, 12 Jan 2024 05:38:33 +0000 Subject: [PATCH 38/49] dummy tcc-mes file no longer needed --- steps/tcc-0.9.26/pass1.kaem | 3 --- 1 file changed, 3 deletions(-) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index 8aa4948e..43af783c 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -169,9 +169,6 @@ cd ../${TCC_PKG} if match x${TCC_BOOTSTRAP_ALT} xTrue; then mkdir /usr/lib/mes/tcc/ -# dummy tcc-mes -catm /usr/bin/tcc-mes - # boot1 tcc-boot0 \ -nostdinc \ From f6e4b5bc4ab9dc3e3051dbea4fdfbc902ec06f5f Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Fri, 12 Jan 2024 06:02:03 +0000 Subject: [PATCH 39/49] check sha256sum for tcc_bootstrap_alt-0.1 outpit artifact --- steps/tcc_bootstrap_alt-0.1/pass1.kaem | 10 ++++++++++ .../tcc_bootstrap_alt-0.1.x86.checksums | 1 + 2 files changed, 11 insertions(+) create mode 100644 steps/tcc_bootstrap_alt-0.1/tcc_bootstrap_alt-0.1.x86.checksums diff --git a/steps/tcc_bootstrap_alt-0.1/pass1.kaem b/steps/tcc_bootstrap_alt-0.1/pass1.kaem index d4413b63..1732dc73 100644 --- a/steps/tcc_bootstrap_alt-0.1/pass1.kaem +++ b/steps/tcc_bootstrap_alt-0.1/pass1.kaem @@ -27,3 +27,13 @@ chmod 755 ./x86/artifact/kaem-optional-seed kaem --file kaem.x86 cp artifacts/tcc_27_boot_static.exe /usr/bin/tcc-boot0 chmod 755 /usr/bin/tcc-boot0 + +# Checksums +if match x${UPDATE_CHECKSUMS} xTrue; then + sha256sum -o ${pkg}.${ARCH}.checksums \ + /usr/bin/tcc-boot0 + + cp ${pkg}.checksums ${SRCDIR} +else + sha256sum -c ${pkg}.${ARCH}.checksums +fi diff --git a/steps/tcc_bootstrap_alt-0.1/tcc_bootstrap_alt-0.1.x86.checksums b/steps/tcc_bootstrap_alt-0.1/tcc_bootstrap_alt-0.1.x86.checksums new file mode 100644 index 00000000..d08ca471 --- /dev/null +++ b/steps/tcc_bootstrap_alt-0.1/tcc_bootstrap_alt-0.1.x86.checksums @@ -0,0 +1 @@ +26268bc6b96b48e6d25e08abce0ce1ecaebb58c99f898f35a485ec696117f1ca /usr/bin/tcc-boot0 From 38800691421fd5707db02285d923da7c9d049eac Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Fri, 12 Jan 2024 06:06:29 +0000 Subject: [PATCH 40/49] document potential bug --- steps/tcc-0.9.26/pass1.kaem | 1 + 1 file changed, 1 insertion(+) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index 43af783c..2c545e18 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -435,6 +435,7 @@ cd ../.. # Checksums if match x${UPDATE_CHECKSUMS} xTrue; then +# LJW FIXME is this a bug? should it say pkg and ARCH? sha256sum -o ${pkg}.checksums \ /usr/bin/tcc \ /usr/lib/mes/libc.a \ From 94877fd5bd6ed6941d3ff975f415b9b8631d605a Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Fri, 12 Jan 2024 06:18:21 +0000 Subject: [PATCH 41/49] change to correct dir --- steps/tcc_bootstrap_alt-0.1/pass1.kaem | 2 ++ 1 file changed, 2 insertions(+) diff --git a/steps/tcc_bootstrap_alt-0.1/pass1.kaem b/steps/tcc_bootstrap_alt-0.1/pass1.kaem index 1732dc73..83d7cc9a 100644 --- a/steps/tcc_bootstrap_alt-0.1/pass1.kaem +++ b/steps/tcc_bootstrap_alt-0.1/pass1.kaem @@ -28,6 +28,8 @@ kaem --file kaem.x86 cp artifacts/tcc_27_boot_static.exe /usr/bin/tcc-boot0 chmod 755 /usr/bin/tcc-boot0 +cd ../.. + # Checksums if match x${UPDATE_CHECKSUMS} xTrue; then sha256sum -o ${pkg}.${ARCH}.checksums \ From 1009ea690512303b1c835f0b37e3e982ba937aaf Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Sat, 13 Jan 2024 00:05:00 +0000 Subject: [PATCH 42/49] check extra sha sums for tcc-mes --- steps/tcc-0.9.26/pass1.kaem | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index 2c545e18..f3e81a4e 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -450,7 +450,17 @@ else sha256sum -c ${pkg}.${ARCH}.checksums fi -# LJW FIXME only check hashes for following files when doing mes builds: -# /usr/bin/tcc-mes \ -# /usr/bin/tcc-boot0 \ -# /usr/bin/tcc-boot1 \ +# Check extra hashes when doing mes build +if match x${UPDATE_CHECKSUMS}${TCC_BOOTSTRAP_ALT} xTrueFalse; then +# LJW FIXME is this a bug? should it say pkg and ARCH? + sha256sum -o ${pkg}_mes.checksums \ + /usr/bin/tcc-mes \ + /usr/bin/tcc-boot0 \ + /usr/bin/tcc-boot1 + + cp ${pkg}.checksums ${SRCDIR} +fi + +if match x${UPDATE_CHECKSUMS}${TCC_BOOTSTRAP_ALT} xFalseFalse; then + sha256sum -c ${pkg}_mes.${ARCH}.checksums +fi From 8346a2b7e4db713f14129e94dc413bb98c251d80 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Sat, 13 Jan 2024 00:09:17 +0000 Subject: [PATCH 43/49] split riscv tcc-0.9.26 hashes to match with x86 --- steps/tcc-0.9.26/tcc-0.9.26.riscv64.checksums | 3 --- steps/tcc-0.9.26/tcc-0.9.26_mes.riscv64.checksums | 3 +++ 2 files changed, 3 insertions(+), 3 deletions(-) create mode 100644 steps/tcc-0.9.26/tcc-0.9.26_mes.riscv64.checksums diff --git a/steps/tcc-0.9.26/tcc-0.9.26.riscv64.checksums b/steps/tcc-0.9.26/tcc-0.9.26.riscv64.checksums index 09d88933..6975cf9b 100644 --- a/steps/tcc-0.9.26/tcc-0.9.26.riscv64.checksums +++ b/steps/tcc-0.9.26/tcc-0.9.26.riscv64.checksums @@ -1,6 +1,3 @@ -22c74eec2ee1694247fae2958979c2326bab41ecbf5ba279b38417f63bf8892d /usr/bin/tcc-mes -4aff7e61488c03322a682a086405831aa4d99681b2761ddc8b0a76888395a11b /usr/bin/tcc-boot0 -9973b5e730c0b9d65aa0ad2332a51adbb247546478d2e86697bba6de4f2f03fc /usr/bin/tcc-boot1 5b5b131cc6bb7f62b11bc99092a1e48c2975af00c7d22fb52de5f561dbdc749a /usr/bin/tcc 93fbb5473bfaf2abaf6598a21dd5f0ac3c6237bfa15bc0c85328608233de55bc /usr/lib/mes/libc.a 98e2d2d543a113c82c8de39f32d4d43b1fe7f3159c5956c5e3224e7f4162601f /usr/lib/mes/libgetopt.a diff --git a/steps/tcc-0.9.26/tcc-0.9.26_mes.riscv64.checksums b/steps/tcc-0.9.26/tcc-0.9.26_mes.riscv64.checksums new file mode 100644 index 00000000..42c01ca6 --- /dev/null +++ b/steps/tcc-0.9.26/tcc-0.9.26_mes.riscv64.checksums @@ -0,0 +1,3 @@ +22c74eec2ee1694247fae2958979c2326bab41ecbf5ba279b38417f63bf8892d /usr/bin/tcc-mes +4aff7e61488c03322a682a086405831aa4d99681b2761ddc8b0a76888395a11b /usr/bin/tcc-boot0 +9973b5e730c0b9d65aa0ad2332a51adbb247546478d2e86697bba6de4f2f03fc /usr/bin/tcc-boot1 From 6446c095767b247b66cd4f17a1f91aaa3b2342a4 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Sat, 13 Jan 2024 00:20:13 +0000 Subject: [PATCH 44/49] add alt_pass1 to ci --- .github/workflows/bwrap.yml | 48 ++++++++++++++++++++++++++++++++++++- 1 file changed, 47 insertions(+), 1 deletion(-) diff --git a/.github/workflows/bwrap.yml b/.github/workflows/bwrap.yml index bb8e925b..882ade15 100644 --- a/.github/workflows/bwrap.yml +++ b/.github/workflows/bwrap.yml @@ -12,6 +12,52 @@ on: - master jobs: + alt_pass1: + name: Alt Run up to Linux build under bubblewrap + runs-on: ubuntu-latest + steps: + - name: Install bubblewrap + run: sudo apt install bubblewrap + - name: Checkout repo + uses: actions/checkout@v3 + with: + submodules: recursive + # There is a strange bug(?) in nongnu, when you clone a git repository + # against a commit != HEAD with depth=1, it errors out. + fetch-depth: 0 + - name: Query cache for sources + id: cache + uses: actions/cache/restore@v3 + with: + path: | + distfiles + key: cache-${{ hashFiles('steps/*/sources') }} + - name: Get sources + if: steps.cache.outputs.cache-hit != 'true' + run: ./download-distfiles.sh + - name: Cache sources + if: steps.cache.outputs.cache-hit != 'true' + uses: actions/cache/save@v3 + with: + path: | + distfiles + key: cache-${{ hashFiles('steps/*/sources') }} + - name: Run bootstrap + run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 --tcc_bootstrap_alt + - name: Archive created packages + if: failure() # archive failed builds progress + uses: actions/upload-artifact@v3 + with: + name: alt_packages + path: target/external/repo/** + - name: Tar alt_pass1 image + run: tar -cf alt_pass1_image.tar target + - name: Archive alt_pass1_image + uses: actions/upload-artifact@v3 + with: + name: internal_alt_pass1_image + path: alt_pass1_image.tar + pass1: name: Run up to Linux build under bubblewrap runs-on: ubuntu-latest @@ -43,7 +89,7 @@ jobs: distfiles key: cache-${{ hashFiles('steps/*/sources') }} - name: Run bootstrap - run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 --tcc_bootstrap_alt + run: ./rootfs.py --bwrap --external-sources --build-kernels --cores 2 --internal-ci pass1 - name: Archive created packages if: failure() # archive failed builds progress uses: actions/upload-artifact@v3 From f67113dafab955e56e0ba30f9ced79fe233f1200 Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Sat, 13 Jan 2024 02:23:25 +0000 Subject: [PATCH 45/49] restore other arch support --- steps/tcc-0.9.26/pass1.kaem | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index f3e81a4e..7e210f2e 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -147,12 +147,14 @@ tcc-mes -c -D HAVE_CONFIG_H=1 -D HAVE_LONG_LONG=1 -D HAVE_FLOAT=1 -I include -I fi if match ${ARCH} riscv64; then + IS_RISCV64=True tcc-mes -c -D HAVE_CONFIG_H=1 -D HAVE_LONG_LONG=1 -D HAVE_FLOAT=1 -I include -I include/linux/${MES_ARCH} -o lib-arm64.o ../${TCC_PKG}/lib/lib-arm64.c tcc-mes -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o lib-arm64.o +else + IS_RISCV64=False fi -# LJW FIXME breaks other arches -if match x${ARCH}${TCC_BOOTSTRAP_ALT} xx86False; then +if match xIS_RISCV64${TCC_BOOTSTRAP_ALT} xFalseFalse; then tcc-mes -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o fi From c9862293348bb4eca788281267e9424624482d3d Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Sat, 13 Jan 2024 03:39:53 +0000 Subject: [PATCH 46/49] fix typo --- steps/tcc-0.9.26/pass1.kaem | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index 7e210f2e..9ce3672b 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -154,7 +154,7 @@ else IS_RISCV64=False fi -if match xIS_RISCV64${TCC_BOOTSTRAP_ALT} xFalseFalse; then +if match x${IS_RISCV64}${TCC_BOOTSTRAP_ALT} xFalseFalse; then tcc-mes -ar cr ${LIBDIR}/tcc/libtcc1.a libtcc1.o fi From c4add474fb2a69f48deea8716b88814d0af6b5ba Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 24 Jan 2024 18:15:19 +0000 Subject: [PATCH 47/49] move to tcc_bootstrap_alt-0.2 --- steps/manifest | 2 +- steps/tcc_bootstrap_alt-0.1/sources | 1 - steps/tcc_bootstrap_alt-0.1/tcc_bootstrap_alt-0.1.x86.checksums | 1 - .../{tcc_bootstrap_alt-0.1 => tcc_bootstrap_alt-0.2}/pass1.kaem | 0 steps/tcc_bootstrap_alt-0.2/sources | 1 + steps/tcc_bootstrap_alt-0.2/tcc_bootstrap_alt-0.2.x86.checksums | 1 + 6 files changed, 3 insertions(+), 3 deletions(-) delete mode 100644 steps/tcc_bootstrap_alt-0.1/sources delete mode 100644 steps/tcc_bootstrap_alt-0.1/tcc_bootstrap_alt-0.1.x86.checksums rename steps/{tcc_bootstrap_alt-0.1 => tcc_bootstrap_alt-0.2}/pass1.kaem (100%) create mode 100644 steps/tcc_bootstrap_alt-0.2/sources create mode 100644 steps/tcc_bootstrap_alt-0.2/tcc_bootstrap_alt-0.2.x86.checksums diff --git a/steps/manifest b/steps/manifest index 6b5afa35..c18acc0a 100644 --- a/steps/manifest +++ b/steps/manifest @@ -31,7 +31,7 @@ build: checksum-transcriber-1.0 build: simple-patch-1.0 build: mes-0.25 -build: tcc_bootstrap_alt-0.1 ( TCC_BOOTSTRAP_ALT == True ) +build: tcc_bootstrap_alt-0.2 ( TCC_BOOTSTRAP_ALT == True ) build: tcc-0.9.26 build: tcc-0.9.27 define: BUILD_FIWIX = ( KERNEL_BOOTSTRAP == True || BUILD_KERNELS == True ) diff --git a/steps/tcc_bootstrap_alt-0.1/sources b/steps/tcc_bootstrap_alt-0.1/sources deleted file mode 100644 index c0ee3721..00000000 --- a/steps/tcc_bootstrap_alt-0.1/sources +++ /dev/null @@ -1 +0,0 @@ -https://github.com/cosinusoidally/tcc_bootstrap_alt/releases/download/0.1/tcc_bootstrap_alt-0.1.tar.gz 578f5025a2f4d3e3967ded2cf5b03423cd19ed176bf3f2c4dcd19354b7ccc739 diff --git a/steps/tcc_bootstrap_alt-0.1/tcc_bootstrap_alt-0.1.x86.checksums b/steps/tcc_bootstrap_alt-0.1/tcc_bootstrap_alt-0.1.x86.checksums deleted file mode 100644 index d08ca471..00000000 --- a/steps/tcc_bootstrap_alt-0.1/tcc_bootstrap_alt-0.1.x86.checksums +++ /dev/null @@ -1 +0,0 @@ -26268bc6b96b48e6d25e08abce0ce1ecaebb58c99f898f35a485ec696117f1ca /usr/bin/tcc-boot0 diff --git a/steps/tcc_bootstrap_alt-0.1/pass1.kaem b/steps/tcc_bootstrap_alt-0.2/pass1.kaem similarity index 100% rename from steps/tcc_bootstrap_alt-0.1/pass1.kaem rename to steps/tcc_bootstrap_alt-0.2/pass1.kaem diff --git a/steps/tcc_bootstrap_alt-0.2/sources b/steps/tcc_bootstrap_alt-0.2/sources new file mode 100644 index 00000000..06a1d5e5 --- /dev/null +++ b/steps/tcc_bootstrap_alt-0.2/sources @@ -0,0 +1 @@ +https://github.com/cosinusoidally/tcc_bootstrap_alt/releases/download/0.1/tcc_bootstrap_alt-0.1.tar.gz b8afe6d054a7e3e17b7f18a80776eb7c69469913d21e96261eadc598de48484a diff --git a/steps/tcc_bootstrap_alt-0.2/tcc_bootstrap_alt-0.2.x86.checksums b/steps/tcc_bootstrap_alt-0.2/tcc_bootstrap_alt-0.2.x86.checksums new file mode 100644 index 00000000..28b0485b --- /dev/null +++ b/steps/tcc_bootstrap_alt-0.2/tcc_bootstrap_alt-0.2.x86.checksums @@ -0,0 +1 @@ +68339f674652b934929568b613a74f75668d3fee6664b4d528781d764f5e7750 /usr/bin/tcc-boot0 From b851f5587ce98c6f01bfbe57bd7048adca85652b Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Wed, 24 Jan 2024 18:28:59 +0000 Subject: [PATCH 48/49] bump 0.2 --- steps/tcc_bootstrap_alt-0.2/sources | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/steps/tcc_bootstrap_alt-0.2/sources b/steps/tcc_bootstrap_alt-0.2/sources index 06a1d5e5..c0d1c1e0 100644 --- a/steps/tcc_bootstrap_alt-0.2/sources +++ b/steps/tcc_bootstrap_alt-0.2/sources @@ -1 +1 @@ -https://github.com/cosinusoidally/tcc_bootstrap_alt/releases/download/0.1/tcc_bootstrap_alt-0.1.tar.gz b8afe6d054a7e3e17b7f18a80776eb7c69469913d21e96261eadc598de48484a +https://github.com/cosinusoidally/tcc_bootstrap_alt/releases/download/0.2/tcc_bootstrap_alt-0.2.tar.gz b8afe6d054a7e3e17b7f18a80776eb7c69469913d21e96261eadc598de48484a From c766b6030bfb34b438deb6b368e41aeb2d6e1d9a Mon Sep 17 00:00:00 2001 From: Liam Wilson Date: Fri, 2 Feb 2024 14:52:44 +0000 Subject: [PATCH 49/49] try and fix some UPDATE_CHECKSUMS --- steps/tcc-0.9.26/pass1.kaem | 2 +- steps/tcc_bootstrap_alt-0.2/pass1.kaem | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/steps/tcc-0.9.26/pass1.kaem b/steps/tcc-0.9.26/pass1.kaem index 9ce3672b..4367cc18 100755 --- a/steps/tcc-0.9.26/pass1.kaem +++ b/steps/tcc-0.9.26/pass1.kaem @@ -460,7 +460,7 @@ if match x${UPDATE_CHECKSUMS}${TCC_BOOTSTRAP_ALT} xTrueFalse; then /usr/bin/tcc-boot0 \ /usr/bin/tcc-boot1 - cp ${pkg}.checksums ${SRCDIR} + cp ${pkg}_mes.checksums ${SRCDIR} fi if match x${UPDATE_CHECKSUMS}${TCC_BOOTSTRAP_ALT} xFalseFalse; then diff --git a/steps/tcc_bootstrap_alt-0.2/pass1.kaem b/steps/tcc_bootstrap_alt-0.2/pass1.kaem index 83d7cc9a..84237065 100644 --- a/steps/tcc_bootstrap_alt-0.2/pass1.kaem +++ b/steps/tcc_bootstrap_alt-0.2/pass1.kaem @@ -35,7 +35,7 @@ if match x${UPDATE_CHECKSUMS} xTrue; then sha256sum -o ${pkg}.${ARCH}.checksums \ /usr/bin/tcc-boot0 - cp ${pkg}.checksums ${SRCDIR} + cp ${pkg}.${ARCH}.checksums ${SRCDIR} else sha256sum -c ${pkg}.${ARCH}.checksums fi