boku-ilen / geodot-plugin

Godot plugin for loading geospatial data
GNU General Public License v3.0
107 stars 18 forks source link

Can we mimic Godot build scripts to build all platforms support? #41

Open clemens-tolboom opened 3 years ago

clemens-tolboom commented 3 years ago

Maybe this helps https://github.com/godotengine/godot-build-scripts ?

Godot CI is using this to test every PR generating builds in https://github.com/godotengine/godot/actions .. ie https://github.com/godotengine/godot/actions/runs/507761636 has build artifacts ... not sure as I haven't tried myself yet.

clemens-tolboom commented 3 years ago

It looks cool but is it doable? https://github.com/godotengine/build-containers/blob/master/build.sh is a good starting point for contemplating.

kb173 commented 3 years ago

I have some experience setting this up for Linux, that should be fairly easy. I think I'll try that sometime soon, and once that is done we can go on to other OSs :+1:

kb173 commented 3 years ago

I setup a GitHub Action for automatic Linux builds in https://github.com/boku-ilen/geodot-plugin/commit/d20abeeb83684baf378eb6eb300eebc371523a3c!

We could use the artifacts of this for automated releases. Unfortunately it's quite slow because it regenerates the CPP bindings every time - it'd be nice to find a way to cache those.

clemens-tolboom commented 3 years ago

(note to self) I found

kb173 commented 3 years ago

A GitHub Action for building on Mac OS was added in https://github.com/boku-ilen/geodot-plugin/commit/c3950526c2e27a3292f2e0f102aed4acf0691911 and seems to work!

Only Windows left - I restructured that build to use MinGW instead of MSVC, that way we can cross-compile from Linux which is much more comfortable. However, we need Fedora for that build since its package repository provides direct access to MinGW GDAL builds and all its dependencies. GitHub doesn't offer Fedora for actions, so we'll likely want to use a minimal Docker container for that, similarly to how Godot does it.

kb173 commented 3 years ago

All platforms now have functional GitHub Actions for compilation!

What we need to do now is figure out packaging and publish the build artifacts accordingly. That means this issue is blocked until #42 is done.

kb173 commented 3 years ago

60 publishes the build artifacts in the GitHub Action tab. For the asset store, we'll want to push them to a GitHub repo - either to this one, or to a new one with only the binaries relevant for users.