Mercurial > repo
view interps/egel/readme-hackeso.txt @ 12514:500486b20e41 draft default tip
<int-e> slwd fungot//s/ds/d s/
author | HackEso <hackeso@esolangs.org> |
---|---|
date | Fri, 27 Sep 2024 20:43:06 +0100 |
parents | 563db84bb4f8 |
children |
line wrap: on
line source
Egel interpreter from "https://github.com/egel-lang/egel/" by Marco Devillers. Instructions to rebuild the executable and compiled libraries from a newer version of egel. Get sources from github: `fetch /hackenv/tmp/egel.zip https://github.com/egel-lang/egel/archive (As of this writing, I used git commit a518d99f704f07f90f507eb59ef904b40dd785dd , but I'll forget to update this readme when I install a newer one.) Unpack sources: ``` set -e; cd /hackenv/tmp; rm -r egel-master ``` set -e; cd /hackenv/tmp; unzip egel.zip Build the interpreter. You'll have to rerun this a few time because it's too slow to build for HackEso's timeout, and check for unlucky timeouts while the compiler is writing its output. ``` set -ex; cd /hackenv/tmp/egel-master; make -C src LIBS="-ldl -lpthread -licuio -licui18n -licuuc -licudata" &>> buildlog Build the compiled libraries. ``` set -ex; cd /hackenv/tmp/egel-master; (for m in io fs random regex; do make -C lib/$m LIBS="-ldl -lpthread -licuio -licui18n -licuuc -licudata"; done) &>> buildlog Copy the files ``` set -xe; cd /hackenv/tmp/egel-master; cp -v src/egel lib/*.ego /hackenv/interps/egel/ The prelude is currently a custom one for HackEso. Check if the prelude distributed with egel changed and merge. In the long term, we should merge changes back from HackEso to egel, or at least a fork. There should be a wrapper that invokes this, but I haven't yet written one. Example command that works. ``` set -e; cd egel-scripts; >a0.eg echo $'import "/hackenv/tmp/egel-master/include/prelude-hackeso.eg"\nusing System\nusing Math\nusing String\nusing IO\ndef main = ''[F->F F tuple 2 777][F B L U->[false->B|true->F F([T->T T 2][T C->[true->B|false->[false->B L|true->T T(C+1)](C*C<=L)](0==L%C)])(L+1)U](L<U)]'; /hackenv/interps/egel/egel a0.eg