-
Notifications
You must be signed in to change notification settings - Fork 3
32 lines (32 loc) · 1.07 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
name: Compile
on: [push, pull_request]
jobs:
test:
strategy:
matrix:
operating-system: [ubuntu-latest]
ocaml-version: ["4.13.0", "4.13.1", "4.14.0", "4.14.1", "4.14.2"]
runs-on: ${{ matrix.operating-system }}
steps:
- uses: actions/checkout@v2
- uses: ocaml/setup-ocaml@v2
with:
ocaml-compiler: ${{ matrix.ocaml-version }}
allow-prerelease-opam: true
# See jart/cosmopolitan#3
- name: Fix binfmt and Cosmopolitan
run: sudo sh -c "echo ':APE:M::MZqFpD::/bin/sh:' >/proc/sys/fs/binfmt_misc/register"
- name: Pinning packages
run: opam pin add -t -yn -vvv --kind=path --with-version=dev .
- name: Install cosmopolitan/esperanto and dune
run: opam depext -iyt -v esperanto-cosmopolitan x86_64-esperanto aarch64-esperanto dune
- name: Compiling example project (cat.com)
run: |
cd example/
opam install ocamlfind
opam exec -- dune build ./cat.exe
opam exec -- ./link.sh
- name: Execute cat.com
run: |
cd example/
./cat.com < cat.ml