build tweaks #12
This file contains 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: "Continuous Integration" | |
on: | |
push: | |
branches: [ geojson-build ] | |
# pull_request: | |
env: | |
AREA: liechtenstein | |
jobs: | |
unix-build: | |
strategy: | |
matrix: | |
include: | |
- os: ubuntu-22.04 | |
triplet: x64-linux | |
executable: tilemaker | |
path: /usr/local/share/vcpkg/installed | |
toolchain: /usr/local/share/vcpkg/scripts/buildsystems/vcpkg.cmake | |
name: ${{ matrix.os }} build | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Enable vcpkg cache | |
uses: actions/cache@v2 | |
with: | |
path: ${{ matrix.path }} | |
key: vcpkg-${{ matrix.triplet }}-0 # Increase the number whenever dependencies are modified | |
restore-keys: vcpkg-${{ matrix.triplet }} | |
- name: Build dependencies | |
run: | | |
sudo apt install build-essential libboost-dev libboost-filesystem-dev libboost-iostreams-dev libboost-program-options-dev libboost-system-dev libluajit-5.1-dev libshp-dev libsqlite3-dev rapidjson-dev zlib1g-dev | |
- name: Build tilemaker | |
run: | | |
make -j | |
- name: Publish tilemaker | |
uses: actions/upload-artifact@v4 | |
with: | |
name: tilemaker | |
path: tilemaker | |
- name: Build openmaptiles-compatible mbtiles files of Liechtenstein | |
run: | | |
curl http://download.geofabrik.de/europe/${{ env.AREA }}-latest.osm.pbf -o ${{ env.AREA }}.osm.pbf | |
${{ github.workspace }}/build/${{ matrix.executable }} ${{ env.AREA }}.osm.pbf --config=resources/config-openmaptiles.json --process=resources/process-openmaptiles.lua --output=${{ env.AREA }}.mbtiles --verbose || true | |
- name: 'Upload compiled executable' | |
uses: actions/upload-artifact@v2 | |
with: | |
name: tilemaker-${{ matrix.os }} | |
path: | | |
${{ github.workspace }}/resources | |
${{ github.workspace }}/build/${{ matrix.executable }} |