The recommended way to use SDL2 in Android projects is via symlinking the SDL source tree into the project. However, this allegedly causes strange issues with Git for Windows. This PR switches the build process to the more recently added alternative of installing SDL2 via Maven and having Gradle handle the dependency management. This also avoids the need to vendor the Java code.
However, SDL currently does not publish Maven packages, meaning they have to be built manually. This can be done by running build-scripts/android-prefab.sh in the SDL repository and then ensuring that the built package is available to Gradle. The cleanest way to do this is by running mvn install:install-file -Dfile=build-android-prefab/prefab-2.28.5/SDL2-2.28.5.aar -DpomFile=build-android-prefab/prefab-2.28.5/SDL2-2.28.5.pom to install it to Maven Local, but other methods are possible as well.
Legal Stuff:
By submitting this pull request, I confirm that...
[x] My changes may be used in a future commercial release of VVVVVV
[x] I will be credited in a CONTRIBUTORS file and the "GitHub Friends"
section of the credits for all of said releases, but will NOT be compensated
for these changes
Changes:
The recommended way to use SDL2 in Android projects is via symlinking the SDL source tree into the project. However, this allegedly causes strange issues with Git for Windows. This PR switches the build process to the more recently added alternative of installing SDL2 via Maven and having Gradle handle the dependency management. This also avoids the need to vendor the Java code.
However, SDL currently does not publish Maven packages, meaning they have to be built manually. This can be done by running
build-scripts/android-prefab.sh
in the SDL repository and then ensuring that the built package is available to Gradle. The cleanest way to do this is by runningmvn install:install-file -Dfile=build-android-prefab/prefab-2.28.5/SDL2-2.28.5.aar -DpomFile=build-android-prefab/prefab-2.28.5/SDL2-2.28.5.pom
to install it to Maven Local, but other methods are possible as well.Legal Stuff:
By submitting this pull request, I confirm that...
CONTRIBUTORS
file and the "GitHub Friends" section of the credits for all of said releases, but will NOT be compensated for these changes