diff --git a/build.sh b/build.sh index c2fe70d9..75c0de10 100755 --- a/build.sh +++ b/build.sh @@ -1,7 +1,7 @@ #! /bin/sh # Mes --- Maxwell Equations of Software -# Copyright © 2017 Jan Nieuwenhuizen +# Copyright © 2017,2018 Jan Nieuwenhuizen # # This file is part of Mes. # @@ -59,6 +59,10 @@ $M1 --LittleEndian --Architecture=1 -f\ -f $MES_SEED/libc+tcc-mes.M1\ -o libc+tcc-mes.hex2 +cp crt1.hex2 lib +cp libc-mes.hex2 lib +cp libc+tcc-mes.hex2 lib + # TODO: after building from seed, build from src/mes.c # build-aux/mes-snarf.scm --mes src/gc.c # build-aux/mes-snarf.scm --mes src/lib.c diff --git a/check-mescc.sh b/check-mescc.sh index 3fba6974..d71f27e9 100755 --- a/check-mescc.sh +++ b/check-mescc.sh @@ -1,5 +1,27 @@ #! /bin/sh +# Mes --- Maxwell Equations of Software +# Copyright © 2017,2018 Jan Nieuwenhuizen +# +# This file is part of Mes. +# +# Mes is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3 of the License, or (at +# your option) any later version. +# +# Mes is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with Mes. If not, see . + +export MES=${MES-src/mes.gcc} +export MESCC=${MESCC-scripts/mescc.mes} +#export MES_ARENA=${MES_ARENA-200000000} > 12GB mem + GUILE=${GUILE-guile} MES=${MES-./mes} M1=${M1-M1} @@ -7,6 +29,19 @@ HEX2=${HEX2-hex2} MESCC=${MESCC-guile/mescc.scm} MES_PREFIX=${MES_PREFIX-.} +# $MESCC -E -o lib/crt1.E lib/crt1.c +# $MESCC -c -o lib/crt1.M1 lib/crt1.E +# $M1 --LittleEndian --Architecture=1 \ +# -f stage0/x86.M1\ +# -f lib/crt1.M1\ +# > lib/crt1.hex2 +# $MESCC -E -o lib/libc-mes.E lib/libc-mes.c +# $MESCC -c -o lib/libc-mes.M1 lib/libc-mes.E +# $M1 --LittleEndian --Architecture=1\ +# -f stage0/x86.M1\ +# -f lib/libc-mes.M1\ +# > lib/libc-mes.hex2 + tests=" t 00-exit-0 diff --git a/test.sh b/test.sh index 37dfc7b1..e617f005 100755 --- a/test.sh +++ b/test.sh @@ -1,5 +1,23 @@ #! /bin/sh +# Mes --- Maxwell Equations of Software +# Copyright © 2017,2018 Jan Nieuwenhuizen +# +# This file is part of Mes. +# +# Mes is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3 of the License, or (at +# your option) any later version. +# +# Mes is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with Mes. If not, see . + set -ex t=${1-t} @@ -8,7 +26,7 @@ rm -f "$t".mes-out M1=${M1-M1} HEX2=${HEX2-hex2} -MESCC=${MESCC-sh guile/mescc.scm} +MESCC=${MESCC-guile/mescc.scm} $MESCC -E -o scaffold/tests/$t.E scaffold/tests/$t.c $MESCC -c -o scaffold/tests/$t.M1 scaffold/tests/$t.E @@ -17,18 +35,18 @@ $M1 --LittleEndian --Architecture=1\ -f scaffold/tests/$t.M1\ > scaffold/tests/$t.hex2 -$MESCC -E -o lib/crt1.E lib/crt1.c -$MESCC -c -o lib/crt1.M1 lib/crt1.E -$M1 --LittleEndian --Architecture=1 \ - -f stage0/x86.M1\ - -f lib/crt1.M1\ - > lib/crt1.hex2 -$MESCC -E -o lib/libc-mes.E lib/libc-mes.c -$MESCC -c -o lib/libc-mes.M1 lib/libc-mes.E -$M1 --LittleEndian --Architecture=1\ - -f stage0/x86.M1\ - -f lib/libc-mes.M1\ - > lib/libc-mes.hex2 +# $MESCC -E -o lib/crt1.E lib/crt1.c +# $MESCC -c -o lib/crt1.M1 lib/crt1.E +# $M1 --LittleEndian --Architecture=1 \ +# -f stage0/x86.M1\ +# -f lib/crt1.M1\ +# > lib/crt1.hex2 +# $MESCC -E -o lib/libc-mes.E lib/libc-mes.c +# $MESCC -c -o lib/libc-mes.M1 lib/libc-mes.E +# $M1 --LittleEndian --Architecture=1\ +# -f stage0/x86.M1\ +# -f lib/libc-mes.M1\ +# > lib/libc-mes.hex2 $HEX2 --LittleEndian --Architecture=1 --BaseAddress=0x1000000\ -f stage0/elf32-header.hex2\