diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index fe8f0a6..6687fc3 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -5,17 +5,17 @@ on: jobs: release: - # We use Ubuntu 20.04 to have an older version of the file tool. - # If we used a newer Ubuntu it it would complain about incompatible magic - # file format on older Ubuntu versions. - runs-on: ubuntu-20.04 + # Compiled magic files are incompatible with older and (for whatever + # reason) also newer versions of `file`. + # Therefore, we only release the concatenated, compressed source file. + runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v3 - name: Install Make - run: sudo apt-get install make + run: sudo apt-get install make xz-utils - name: Build run: make all @@ -24,4 +24,4 @@ jobs: uses: softprops/action-gh-release@v1 if: startsWith(github.ref, 'refs/tags/') with: - files: firmware.mgc + files: firmware.xz diff --git a/Makefile b/Makefile index 52c76f1..bd0d0cf 100644 --- a/Makefile +++ b/Makefile @@ -1,11 +1,19 @@ -all: firmware.mgc +all: mgc xz + +mgc: firmware.mgc firmware.mgc: firmware file -C -m firmware +xz: firmware.xz + +firmware.xz: firmware + xz -f -7 -k firmware + firmware: cat mime/* > firmware clean: rm -f firmware rm -f firmware.mgc + rm -f firmware.xz