Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Created Github Action for automating generation of prebuilt libraries. #135

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Retzinsky
Copy link

Github Actions to automate creation of prebuilt libraries. The action triggers on any change to the source of java-wrapper or server. First job runs JNICodeGenerator to generate the C++ sources. Next, three jobs in parallel to build on the respective platforms. Last job creates a pull request to merge the new prebuilt libraries back into the project. Runs as-is, no changes to project setup required - it's essentially just the build instructions page in Action form using the existing build-natives scripts.

I added a couple of extra functions to my personal build (namely requestUserStats() and getUserStats()) and verified them as functional using this process in my own game, on Windows at least.

There's probably more fun stuff that could be added, perhaps caching of intermediate products etc but it only takes a couple of minutes to run as it is. Sure beats doing everything by hand!

(cherry picked from commit 06f0ca8)
@Retzinsky Retzinsky changed the title Create main.yml Created Github Action for automating generation of prebuilt libraries. Nov 9, 2023
@code-disaster
Copy link
Owner

I've added build actions myself a while back, but kept them in a separate and private repository, fetching steamworks4j as a submodule. I just wasn't sure about sharing binaries (premake) and Steamworks SDK files in a public repository.

@Retzinsky
Copy link
Author

I've added build actions myself a while back, but kept them in a separate and private repository, fetching steamworks4j as a submodule. I just wasn't sure about sharing binaries (premake) and Steamworks SDK files in a public repository.

What's the issue with premake exactly? The premake used in this action is either installed with apt-get in the case of the linux build or pulled from premake's own repository in the case of windows/osx. Forgive me if I'm ignorant of something here, this isn't my area of expertise by any means.

As for the SDK I was definitely concerned about that too, but it turns out the guy who maintains Steamworks.NET already uploaded the whole thing publicly so I just pull that.

@code-disaster
Copy link
Owner

Oh, nothing wrong with premake. Just personal preferences. And I didn't know there's a GH actions recipe to get that one, too. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants