Skip to content

Commit

Permalink
Merge pull request #81 from davidgiven/ab
Browse files Browse the repository at this point in the history
Rewrite the build system to be less terrible.
  • Loading branch information
davidgiven authored Dec 17, 2023
2 parents 9ddd493 + 131499f commit bc4e786
Show file tree
Hide file tree
Showing 81 changed files with 2,330 additions and 715 deletions.
26 changes: 4 additions & 22 deletions .github/workflows/ccpp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,34 +10,16 @@ jobs:
with:
repository: 'davidgiven/cpm65'
path: 'cpm65'
- uses: actions/checkout@v3
with:
repository: 'davidgiven/llvm-mos-sdk'
path: 'llvm-mos-sdk'
- name: get llvm-mos-sdk version
run: echo "MOS_SDK_VERSION=$(cd llvm-mos-sdk && git rev-parse --short HEAD)" >> $GITHUB_ENV

- name: apt
run: sudo apt update && sudo apt install cc1541 cpmtools libfmt-dev ninja-build fp-compiler

- name: cache llvm-mos
id: cache-llvm-mos
uses: actions/cache@v3
env:
cache-name: cache-llvm-mos
with:
path: ~/llvm-mos
key: ${{ runner.os }}-build-${{ env.cache-name }}-ver-${{ env.MOS_SDK_VERSION }}
run: sudo apt update && sudo apt install cc1541 cpmtools libfmt-dev fp-compiler moreutils

- if: ${{ steps.cache-llvm-mos.outputs.cache-hit != 'true' }}
name: install llvm-mos
- name: install llvm-mos
run: |
mkdir -p llvm-mos-sdk/build
(cd llvm-mos-sdk/build && cmake -G "Ninja" -DCMAKE_INSTALL_PREFIX=$HOME/llvm-mos ..)
(cd llvm-mos-sdk/build && ninja install)
wget -O - https://github.com/llvm-mos/llvm-mos-sdk/releases/latest/download/llvm-mos-linux.tar.xz | tar xJf - -C $HOME
- name: make
run: PATH=$PATH:$HOME/llvm-mos/bin make -C cpm65 LLVM=
run: make -C cpm65 LLVM=$HOME/llvm-mos/bin

- name: Upload build artifacts
uses: actions/upload-artifact@v2
Expand Down
26 changes: 4 additions & 22 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,34 +13,16 @@ jobs:
with:
repository: 'davidgiven/cpm65'
path: 'cpm65'
- uses: actions/checkout@v3
with:
repository: 'davidgiven/llvm-mos-sdk'
path: 'llvm-mos-sdk'
- name: get llvm-mos-sdk version
run: echo "MOS_SDK_VERSION=$(cd llvm-mos-sdk && git rev-parse --short HEAD)" >> $GITHUB_ENV

- name: apt
run: sudo apt update && sudo apt install cc1541 cpmtools libfmt-dev ninja-build fp-compiler

- name: cache llvm-mos
id: cache-llvm-mos
uses: actions/cache@v3
env:
cache-name: cache-llvm-mos
with:
path: ~/llvm-mos
key: ${{ runner.os }}-build-${{ env.cache-name }}-ver-${{ env.MOS_SDK_VERSION }}
run: sudo apt update && sudo apt install cc1541 cpmtools libfmt-dev fp-compiler moreutils

- if: ${{ steps.cache-llvm-mos.outputs.cache-hit != 'true' }}
name: install llvm-mos
- name: install llvm-mos
run: |
mkdir -p llvm-mos-sdk/build
(cd llvm-mos-sdk/build && cmake -G "Ninja" -DCMAKE_INSTALL_PREFIX=$HOME/llvm-mos ..)
(cd llvm-mos-sdk/build && ninja install)
wget -O - https://github.com/llvm-mos/llvm-mos-sdk/releases/latest/download/llvm-mos-linux.tar.xz | tar xJf - -C $HOME
- name: make
run: PATH=$PATH:$HOME/llvm-mos/bin make -C cpm65 LLVM=
run: make -C cpm65 LLVM=$HOME/llvm-mos/bin

- name: date
run: |
Expand Down
Loading

0 comments on commit bc4e786

Please sign in to comment.