[WIP] Add a gradle configuration that builds tcnative linux versions within… #252
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
… docker while also executing the host build.
Motivation: Currently tcnative does not run on Alpine linux due to libc incompatibility. By having more flexible building, taking advantage of docker, it should be possible to provide official binaries without much extra work during release.
See also #111, #152
I went ahead and hacked this setup together to allow more flexibility in tcnative builds. Without more knowledge of the release process, I can't say this does exactly what's needed but will be happy to continue to update until it can be used for releasing. FWIW, ~/.m2/repository gets populated with the right jars so it should be mostly there :)
This PR does not change the tcnative build to gradle - that would be a much more invasive process. It uses gradle to take advantage of its flexibility in task execution - looking at examples of maven-docker-plugin made it look like it'd result in an unreadable pom.xml.
With this setup, it would be possible to build all of OSX (or windows which also has docker) and linux versions on the same machine. Care has been taken to allow the versions to be built in parallel using gradle's incubating parallel projects feature. On my macbook pro, all the builds end in about 20min.
Another feature of this gradle script is it automatically downloads and runs maven. So for building linux binaries, the requirements are literally just Java and Docker.
Main questions I currently have are