Skip to content

Commit

Permalink
attempt to add ruleset for FreeBSD builds
Browse files Browse the repository at this point in the history
  • Loading branch information
drkameleon committed Jun 26, 2024
1 parent de6d4ea commit ddeb111
Showing 1 changed file with 23 additions and 9 deletions.
32 changes: 23 additions & 9 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,15 +59,15 @@ runs:
shell: bash

- name: Cache ChooseNim
if: runner.os == 'Linux' || runner.os == 'macOS'
if: inputs.simulating == '' && (runner.os == 'Linux' || runner.os == 'macOS')
id: cache-choosenim
uses: actions/cache@v4
with:
path: ~/.choosenim
key: ${{ runner.os }}-choosenim-${{ steps.get-date.outputs.date }}

- name: Cache Nimble
if: runner.os == 'Linux' || runner.os == 'macOS'
if: inputs.simulating == '' && (runner.os == 'Linux' || runner.os == 'macOS')
id: cache-nimble
uses: actions/cache@v4
with:
Expand All @@ -83,7 +83,7 @@ runs:
install: 'git base-devel p7zip mingw-w64-x86_64-toolchain'

- name: Install Nim (Linux)
if: runner.os == 'Linux'
if: inputs.simulating == '' && runner.os == 'Linux'
uses: jiro4989/setup-nim-action@v1
with:
nim-version: '2.0.4'
Expand Down Expand Up @@ -140,21 +140,21 @@ runs:
shell: msys2 {0}

- name: Install dependencies (Linux / mini / x86)
if: runner.os == 'Linux' && inputs.mode == 'mini' && inputs.arch == 'x86'
if: inputs.simulating == '' && runner.os == 'Linux' && inputs.mode == 'mini' && inputs.arch == 'x86'
run: |
sudo apt-get update
sudo apt-get install gcc-multilib g++-multilib
shell: bash

- name: Install dependencies (Linux / mini / arm)
if: runner.os == 'Linux' && inputs.mode == 'mini' && (inputs.arch == 'arm' || inputs.arch == 'arm64')
if: inputs.simulating == '' && runner.os == 'Linux' && inputs.mode == 'mini' && (inputs.arch == 'arm' || inputs.arch == 'arm64')
run: |
sudo apt-get update
sudo apt-get install gcc-arm-linux-gnueabihf gcc-aarch64-linux-gnu
shell: bash

- name: Install dependencies (Linux / full)
if: runner.os == 'Linux' && inputs.mode != 'mini'
if: inputs.simulating == '' && runner.os == 'Linux' && inputs.mode != 'mini'
run: |
npm install -g uglify-js
sudo apt-get update
Expand All @@ -168,7 +168,7 @@ runs:
shell: bash

- name: Compile Arturo (Linux/macOS - native)
if: inputs.mode != 'web' && runner.os != 'Windows' && (inputs.arch == 'native' || inputs.arch == 'amd64') && runner.arch != 'ARM64'
if: inputs.simulating == '' && inputs.mode != 'web' && runner.os != 'Windows' && (inputs.arch == 'native' || inputs.arch == 'amd64') && runner.arch != 'ARM64'
run: |
cd arturo
./build.nims --install --mode ${{inputs.mode}} --arch amd64 --log
Expand All @@ -186,7 +186,7 @@ runs:
shell: bash

- name: Compile Arturo (Linux)
if: inputs.mode != 'web' && inputs.arch != 'native' && inputs.arch != 'amd64' && runner.os == 'Linux'
if: inputs.simulating == '' && inputs.mode != 'web' && inputs.arch != 'native' && inputs.arch != 'amd64' && runner.os == 'Linux'
run: |
cd arturo
./build.nims --install --mode ${{inputs.mode}} --arch ${{inputs.arch}} --log
Expand All @@ -202,4 +202,18 @@ runs:
./build.nims --install --mode full --arch ${{ inputs.arch }} --log
echo "$HOME/.arturo/bin" >> $GITHUB_PATH
cd ..
shell: bash
shell: bash

- name: Compile Arturo (FreeBSD)
if: inputs.simulating == 'freebsd'
uses: vmactions/freebsd-vm@v1
with:
usesh: true
prepare: |
pkg update
pkg install -y wget nim bash
pkg info --list-file nim
run: |
export PATH="/usr/local/nim/bin/:$PATH"
./build.nims --install --mode ${{ matrix.version }} --log
export PATH="$HOME/.arturo/bin:$PATH"

0 comments on commit ddeb111

Please sign in to comment.