Jan (janneke) Nieuwenhuizen
8b2c4d48a9
mescc: Make sure includedir, libdir are set.
...
* scripts/mescc.in (prefix): New variable.
2021-01-23 08:40:55 +01:00
Jan (janneke) Nieuwenhuizen
8429a4b0b6
build: Bump MESCC_STACK.
...
This fixes running ./pre-inst-env mescc ...
* scripts/mescc.in (MES_STACK): Bump to 6000000.
2020-10-06 16:45:52 +02:00
Jan (janneke) Nieuwenhuizen
be87ada6b5
build: Resurrect running mescc from elsewhere.
...
After setting-up a buld environment, running something like
~/src/mes/wip/pre-inst-env mescc -v -v ~/src/mes/wip/scaffold/main.c
works again.
TODO: Make this less complex.
* The mescc-lib (and gcc-lib) build directories do not help;
these were introduced to support `wip-autotools'.
* We used to opt for short *PATH variables: "." rather than
/gnu/store/.... or /home/janneke/src/mes/master to avoid
filling the MES arena. XXX Has this been solved?
* In the Guix bootstrap, we run module/mescc.scm directly
$MES -e '(mescc)' module/mescc.scm
...so that's why these overrides started to appear in multiple
places.
* build-aux/pre-inst-env.in (MES_UNINSTALLED): New variable.
* scripts/mescc.in (includedir,libdir): Use it to override these.
* module/mescc/mescc.scm (arch-find): Use it to add <lib>-messc.
2020-10-06 10:44:50 +02:00
Jan Nieuwenhuizen
82c85c24da
build: Support mescc-tools 0.5.2.
...
* configure: Remove version check for mescc-tools.
Check for stage0 architecture flag type.
* configure.sh: Likewise.
* build-aux/build-scaffold.sh: Add stage0 flag type indirection.
* module/mescc/mescc.scm (arch-get-architecture): Likewise.
2019-12-07 14:39:19 +01:00
Jan Nieuwenhuizen
2c2f03c9e4
mescc: Honor --includedir, --libdir.
...
* guix/git/mes.scm (mes):
* module/mescc.scm (%includedir, %libdir): New variable.
(mescc:main): Add them to options.
* module/mescc/mescc.scm (mescc:preprocess, c->info): Add %includedir.
(arch-find): Use %libdir instead of
prefix-file.
(prefix-file): Remove.
* scripts/mescc.scm.in (%includedir, %libdir): Initialize from and set
in environment.
xx
* module/mescc/mescc.scm :
2019-11-24 11:14:14 +01:00
Jan Nieuwenhuizen
a56918eaa2
mescc: Environment setup.
...
* scripts/mescc.in (MES_ARENA, MES_MAX_ARENA, MES_STACK): Reduce defaults.
* build-aux/check.sh.in (MES_ARENA): Likewise. Export them.
* build-aux/bootstrap.sh.in (MES_STACK): Likewise.
(MES_PREFIX): Set default.
2019-09-06 23:24:23 +02:00
Jan Nieuwenhuizen
84ec4865df
mescc: Drop $@-workaround.
...
* scripts/mescc.in: Drop $@-workaround.
2019-06-10 23:43:35 +02:00
Jan Nieuwenhuizen
5dc245e739
build: Simplify.
...
core: Make mes src/ c files separate compilation units.
* include/mes/constants.h: New file.
* include/mes/macros.h: New file.
* include/mes/mes.h: New file.
* src/gc.c: Update.
* src/hash.c: Update.
* src/lib.c: Update.
* src/math.c: Update.
* src/mes.c: Update.
* src/module.c: Update.
* src/posix.c: Update.
* src/reader.c: Update.
* src/string.c: Update.
* src/struct.c: Update.
* src/vector.c: Update.
mes: Update datadir.
* src/mes.c (g_datadir): New global.
(open_boot): Rename from read_boot.
(read_boot): New function.
* mes/module/mes/boot-0.scm: Move from boot-0.scm.in
* configure: Update.
* configure.sh: Update.
mescc: Create libraries from separate files.
* .gitignore: Update.
* build-aux/bootstrap-mes.sh: Remove.
* build-aux/bootstrap.sh.in: Remove.
* build-aux/build-guile.sh: Update.
* build-aux/build-mes.sh: Update.
* build-aux/build-scaffold.sh: New file.
* build-aux/build.sh.in: Update.
* build-aux/cc.sh: Update.
* build-aux/check-tcc.sh: Remove.
* build-aux/config.sh.in: New file.
* build-aux/config.sh: Remove.
* build-aux/install.sh.in: Update.
* build-aux/test-boot.sh: New file.
* build-aux/test-c.sh: New file.
* build-aux/test-driver: New file.
* build-aux/test-suite.sh: New file.
* build-aux/trace.sh: Update.
* build-aux/uninstall.sh.in: Update.
* configure: Update.
* configure.sh: Update.
* lib/linux/x86-mes-mescc/crt1.c: Move from lib/linux/x86-mes.
* lib/linux/x86-mes-mescc/mini.c: Likewise.
* lib/linux/x86_64-mes-mescc/crt1.c: Move from lib/linux/x86_64-mes.
* lib/linux/x86_64-mes-mescc/mini.c: Likewise.
* lib/linux/x86-mes-gcc/syscall.c: Rename from mes.c.
* lib/linux/x86-mes-mescc/syscall.c: Likewise.
* lib/linux/x86_64-mes-gcc/syscall.c: Likewise.
* lib/linux/x86_64-mes-mescc/syscall.c: Likewise.
* lib/mes/mes_open.c: Include config.h.
* lib/tests/stdio/70-printf-hello.c: Likewise.
* lib/tests/stdio/70-printf-simple.c: Likewise.
* scaffold/gc-test.sh: New file.
* simple.sh: Update.
2019-06-08 15:36:22 +02:00
Jan Nieuwenhuizen
8abc68bb43
mescc: Support single-dash options on Mes too.
...
* scripts/mescc.in[MES]: Add -- as separator, fixes using single-dash
options on Mes too.
2019-05-29 16:45:28 +02:00
Jan (janneke) Nieuwenhuizen
e0eee55bf3
build: Fix mescc installation on Debian.
...
* build-aux/pre-inst-env.in: Set bindir.
* scripts/mescc.in: Fix configure/prefix issues.
* mes/module/mes/boot-01.scm (integer->char): Remove.
(newline): Use "\n".
(%moduledir): Use string-append.
* mes/module/mes/boot-02.scm: Likewise.
* mes/module/mes/boot-0.scm: Likewise.
2019-05-15 23:26:52 +02:00
Jan Nieuwenhuizen
8f8852ccff
build: Support building with Gash.
...
* build-aux/install.sh: Replace variables with substitution.
* build-aux/bootstrap.sh: New file.
* configure: Substitute it.
* configure.sh: Likewise. Be friendly to Gash.
* .gitignore: Ignore it.
2018-11-24 21:07:31 +01:00
Jan Nieuwenhuizen
6b841a0cab
mescc: Run without shell.
...
* mes/module/mescc.mes: New file.
* module/mescc.scm: Include it.
* scripts/mescc.scm.in: New file.
* scripts/mescc.in: Use it; Make pure shell.
* configure: Substitute it.
* configure.sh: Substitute it.
* build-aux/install.sh.in: Install it.
2018-11-25 13:21:03 +01:00
Jan Nieuwenhuizen
149f2a3e51
core: String as array of bytes.
...
* src/strings.c: New file.
* src/mes.c: Use it. Update users.
2018-11-11 16:25:36 +01:00
Jan Nieuwenhuizen
6b5ac57602
build: Simplify: cater for one compiler at a time.
...
* build-aux/build-cc.sh: Remove.
* build-aux/build-cc32.sh: Remove.
* build-aux/build-cc64.sh: Remove.
* build-aux/build-x86_64-mes.sh: Remove.
* build-aux/cc-mes.sh: Remove.
* build-aux/cc-x86_64-mes.sh: Remove.
* build-aux/cc32-mes.sh: Remove.
* build-aux/cc64-mes.sh: Remove.
* build-aux/test64.sh: Remove.
* build-aux/bootstrap-mes.sh: New file.
* build-aux/config.make.in: New file.
* build-aux/config.status.in: New file.
* build-aux/test-cc.sh: New file.
* .gitignore: Update.
* build-aux/GNUmakefile.in: Update.
* build-aux/build-guile.sh: Update.
* build-aux/build-mes.sh: Update.
* build-aux/build.sh.in: Update.
* build-aux/cc.sh: Update.
* build-aux/check-boot.sh: Update.
* build-aux/check-mes.sh: Update.
* build-aux/check-mescc.sh: Update.
* build-aux/check-tcc.sh: Update.
* build-aux/check.sh.in: Update.
* build-aux/config.sh: Update.
* build-aux/export.make: Update.
* build-aux/install.sh.in: Update.
* build-aux/pre-inst-env.in: Update.
* build-aux/test.sh: Update.
* build-aux/uninstall.sh.in: Update.
* configure: Update.
* configure.sh: Update.
* module/mescc/i386/as.scm: Update.
* module/mescc/preprocess.scm: Update.
* module/mescc/x86_64/as.scm: Update.
* scripts/mescc.in: Update.
* tests/psyntax.test: Update.
2018-11-06 20:29:35 +01:00
Jan Nieuwenhuizen
aa8fd3da9e
mescc: Accept -O, --std, -x.
...
* scripts/mescc.in (parse-opts): Accept -O, --std, -x.
2018-11-08 14:07:27 +01:00
Jan Nieuwenhuizen
21887b9a8e
mescc: Support -dumpmachine.
...
* scripts/mescc.in (parse-opts): Support -dumpmachine.
2018-11-08 22:41:20 +01:00
Jan Nieuwenhuizen
d862f1eceb
mescc: Support --align, off by default.
...
* scripts/mescc.in (parse-opts): Add --align.
* module/mescc/mescc.scm (mescc:compile): Support --align, off by
default.
* module/mescc/M1.scm (infos->M1): Add #:align parameter.
(M1:merge-infos): Likewise. Keep types.
(info->M1): Likewise. Make alignment switchable.
* module/mescc/compile.scm (r->ident): Do not clobber.
(ident-add): Likewise.
(clean-info): Keep types.
* module/mescc/i386/as.scm (i386:r->byte-label): New instruction.
* lib/x86-mes/x86.M1: Add instructions.
* lib/x86_64-mes/x86_64.M1: Add instructions.
* module/mescc/x86_64/as.scm (x86_64:r->byte-label,
x86_64:r->word-label, x86_64:r->long-label): New instruction.
2018-10-06 15:56:14 +02:00
Jan Nieuwenhuizen
3e1a197ed1
mescc: Initial x86_64 support.
...
make all-go && MES=guile ./pre-inst-env scripts/mescc -m64 -c scaffold/main.c
2018-08-14 20:32:56 +02:00
Jan Nieuwenhuizen
f18e1fea36
build: Make build more autotools-like.
...
* build-aux/build.sh.in: Move from ./build.sh
* build-aux/check.sh.in: Likewise.
* build-aux/GNUmakefile.in: Likewise.
* build-aux/install.sh.in: Likewise.
* build-aux/uninstall.sh.in: Likewise.
* configure: Substitute them.
* configure.sh: Likewise.
* build-aux/build-cc.sh: Update: use ${srcdest} instead of ${top_builddest}.
* build-aux/build-cc32.sh: Likewise.
* build-aux/build-guile.sh: Likewise.
* build-aux/build-mes.sh: Likewise.
* build-aux/cc-mes.sh: Likewise.
* build-aux/cc.sh: Likewise.
* build-aux/cc32-mes.sh: Likewise.
* build-aux/check-boot.sh: Likewise.
* build-aux/check-mes.sh: Likewise.
* build-aux/check-mescc.sh: Likewise.
* build-aux/config.sh: Likewise.
* build-aux/export.make: Likewise.
* build-aux/mes-snarf.scm: Likewise.
* build-aux/pre-inst-env.in: Likewise.
* build-aux/test.sh: Likewise.
* build-aux/trace.sh: Likewise.
* module/mescc/mescc.scm: Likewise.
* scripts/mescc.in: Likewise.
* src/mes.c: Likewise.
* .gitignore: Likewise.
2018-07-25 08:14:13 +02:00
Jan Nieuwenhuizen
72cb975213
GNU Mes.
...
Throughout, make these changes
Copyright headers: GNU Mes
First mention of name: GNU Mes
Website: https://www.gnu.org/software/mes
Git: git://git.savannah.gnu.org/mes.git
2018-07-22 14:24:36 +02:00
Jan Nieuwenhuizen
4203a427d0
build: Support --srcdir build.
...
* build-aux/config.sh: New file.
* build-aux/trace.sh: New file.
* build-aux/GNUmakefile.in: New file.
* configure: Support srcdir configure.
* GNUmakefile: Support srcdir build.
* build-aux/build-cc.sh: Likewise.
* build-aux/build-cc32.sh: Likewise.
* build-aux/build-guile.sh: Likewise.
* build-aux/build-mes.sh: Likewise.
* build-aux/cc-mes.sh: Likewise.
* build-aux/cc.sh: Likewise.
* build-aux/cc32-mes.sh: Likewise.
* build-aux/check-mes.sh: Likewise.
* build-aux/check-mescc.sh: Likewise.
* build-aux/export.make: Likewise.
* build-aux/mes-snarf.scm: Likewise.
* build-aux/pre-inst-env.in: Likewise.
* build-aux/test.sh: Likewise.
* build.sh: Likewise.
* check.sh: Likewise.
* install.sh: Likewise.
* module/mescc/mescc.scm: Likewise.
* scripts/mescc.in: Likewise.
* src/mes.c: Likewise.
2018-07-22 00:43:39 +02:00
Jan Nieuwenhuizen
5d3fa50384
build: Prepare for autoconfiscation.
...
Make build system more in alignment with how autotools work. This
will make transition easier.
* mes/module/mes/boot-0.scm.in: Update from module/mes/boot-0.scm.
* scripts/mescc.in: Update from scripts/mescc.
* build-aux/pre-inst-env.in: New file.
* build-aux/cc-mes.sh: Use pre-inst-env.
* configure: Substitute new .in files.
* install.sh: Do not substitute mescc, boot-0.scm.
2018-07-21 18:28:47 +02:00