Skip to content

Commit

Permalink
Update build.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
ii8 committed Nov 8, 2023
1 parent fe01001 commit 39c2217
Showing 1 changed file with 22 additions and 24 deletions.
46 changes: 22 additions & 24 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,23 +23,23 @@ jobs:
fail-fast: false
matrix:
arch:
# - { name: i686, alt: x86 }
# - { name: x86_64, alt: amd64 }
# - { name: aarch64, alt: arm64 }
- { name: i686, alt: x86 }
- { name: x86_64, alt: amd64 }
- { name: aarch64, alt: arm64 }
- { name: powerpc, alt: powerpc }
# - { name: powerpc64, alt: powerpc64 }
# - { name: riscv32, alt: riscv }
# - { name: riscv64, alt: riscv }
# - { name: mips, alt: mips }
# - { name: m68k, alt: m68k }
- { name: powerpc64, alt: powerpc64 }
- { name: riscv32, alt: riscv }
- { name: riscv64, alt: riscv }
- { name: mips, alt: mips }
- { name: m68k, alt: m68k }
libc: [ gnu, musl ]
include:
# - { arch: { name: mips64, alt: mips }, libc: gnuabi64 }
# - { arch: { name: mips64, alt: mips }, libc: musl }
- { arch: { name: mips64, alt: mips }, libc: gnuabi64 }
- { arch: { name: mips64, alt: mips }, libc: musl }
# - { arch: { name: arm, alt: arm }, libc: gnueabihf }
- { arch: { name: armv7l, alt: arm }, libc: musleabihf }
#exclude:
# - { arch: { name: riscv32, alt: riscv }, libc: gnu }
exclude:
- { arch: { name: riscv32, alt: riscv }, libc: gnu }

runs-on: ubuntu-latest

Expand All @@ -52,32 +52,29 @@ jobs:
path: mlton

- name: Checkout musl-cross-make
if: startsWith(matrix.libc, 'musl')
if: startsWith(matrix.libc, 'musl') && false
uses: actions/checkout@v4
with:
repository: richfelker/musl-cross-make
ref: master
path: musl-cross-make

- name: ls
run: ls -l

- name: Install qemu
run: |
sudo apt-get update
sudo apt-get install qemu-user-static
- name: Install toolchain (musl.cc)
if: ${{ startsWith(matrix.libc, 'musl') && false }}
- name: Install toolchain (musl)
if: startsWith(matrix.libc, 'musl')
run: |
curl -sOL https://more.musl.cc/x86_64-linux-musl/${{ matrix.arch.name }}-linux-${{ matrix.libc }}-cross.tgz
tar -xf ${{ matrix.arch.name }}-linux-${{ matrix.libc }}-cross.tgz
sudo cp -fpr ${{ matrix.arch.name }}-linux-${{ matrix.libc }}-cross/* /usr/local/
rm -r ${{ matrix.arch.name }}-linux-${{ matrix.libc }}-cross \
${{ matrix.arch.name }}-linux-${{ matrix.libc }}-cross.tgz
- name: Install toolchain (musl)
if: startsWith(matrix.libc, 'musl')
- name: Build toolchain (musl)
if: startsWith(matrix.libc, 'musl') && false
run: |
cd musl-cross-make
cat <<EOF > config.mak
Expand All @@ -94,13 +91,13 @@ jobs:
sudo make install
- name: Install toolchain (glibc)
if: ${{ startsWith(matrix.libc, 'gnu') && matrix.arch.name != 'x86_64' }}
if: startsWith(matrix.libc, 'gnu') && matrix.arch.name != 'x86_64'
run: |
sudo apt-get install gcc-${{ matrix.arch.name }}-linux-${{ matrix.libc }} \
binutils-${{ matrix.arch.name }}-linux-${{ matrix.libc }}
- name: Link cc to gcc
if: ${{ startsWith(matrix.libc, 'gnu') }}
if: startsWith(matrix.libc, 'gnu')
run: |
sudo ln -s /usr/bin/${{ matrix.arch.name }}-linux-${{ matrix.libc }}-gcc \
/usr/bin/${{ matrix.arch.name }}-linux-${{ matrix.libc }}-cc
Expand Down Expand Up @@ -132,7 +129,7 @@ jobs:
sudo cp -p mlton/runtime/platform/linux.h /opt/boot/lib/mlton/include/platform/linux.h
- name: Build target runtime (old)
if: ${{ false }}
if: false
run: |
curl -sOL https://github.com/MLton/mlton/releases/download/on-20210117-release/mlton-20210117.src.tgz
tar xzf mlton-20210117.src.tgz
Expand All @@ -148,7 +145,7 @@ jobs:
sudo cp -fpR src/build/lib/mlton/targets/${{ matrix.arch.name }}-linux-${{ matrix.libc }} /opt/boot/lib/mlton/targets/
- name: Build target runtime (new)
if: ${{ true }}
if: true
run: |
cd mlton
PATH="/opt/boot/bin:$PATH" make \
Expand Down Expand Up @@ -177,6 +174,7 @@ jobs:
build/bin/mlton -show path-map
- name: Limit tests
if: false
run: |
cd mlton
mv regression/real.sml .
Expand Down

0 comments on commit 39c2217

Please sign in to comment.