Always compile KindleTool? #201
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| pull_request: | |
| workflow_dispatch: | |
| jobs: | |
| kindletool: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| repository: KindleModding/KindleTool | |
| - name: Compile KindleTool | |
| run: | | |
| sudo apt-get install -y zlib1g-dev libarchive-dev nettle-dev | |
| make | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: kindletool | |
| path: KindleTool/Release/kindletool | |
| build: | |
| runs-on: ubuntu-latest | |
| needs: kindletool | |
| steps: | |
| - name: Setup | |
| run: sudo apt-get install meson | |
| - name: Download toolchain | |
| run: | | |
| wget -q https://github.com/KindleModding/koxtoolchain/releases/latest/download/kindlepw2.tar.gz -O - | tar -xzf - -C ~ | |
| wget -q https://github.com/KindleModding/koxtoolchain/releases/latest/download/kindlehf.tar.gz -O - | tar -xzf - -C ~ | |
| - uses: actions/checkout@v4 | |
| with: | |
| submodules: recursive | |
| - name: Remove old Kindletool | |
| run: rm -f ./utils/kindletool | |
| - uses: actions/download-artifact@v4 | |
| with: | |
| name: kindletool | |
| path: ./utils/ | |
| - uses: actions/checkout@v4 | |
| with: | |
| repository: KindleModding/kindle-sdk | |
| submodules: recursive | |
| path: kindle-sdk | |
| - name: "Setup kindle-sdk" | |
| run: | | |
| sudo apt-get install -y zlib1g-dev libarchive-dev nettle-dev curl | |
| bash ./kindle-sdk/gen-sdk.sh kindlepw2 | |
| bash ./kindle-sdk/gen-sdk.sh kindlehf | |
| - name: Cache Kindle firmware | |
| id: build-cache | |
| uses: actions/cache@v4 | |
| with: | |
| path: ./build_cache | |
| key: ${{ runner.os }}-build-cache | |
| - name: build | |
| run: | | |
| chmod 755 ./utils/kindletool | |
| chown -R $USER: ./utils/ | |
| sh ./build.sh | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: HAKT_BUILD_DEV | |
| path: build/ |