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

Add bin folder to python targets, and adapt the regular python layout (save for the zip). #39

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

Ivorforce
Copy link
Contributor

@Ivorforce Ivorforce commented Oct 28, 2024

Addresses #19. We should probably document this (and / or make it simpler), but this is a good start.

This allows godot-python users to use python (and pip) out of the box:

PYTHONPATH=bin/macos-x86_64/python312.zip:bin/macos-x86_64/python312.zip/site-packages bin/macos-x86_64/python/bin/python3 -m pip install -t bin/macos-x86_64/python/lib/python3.12/site-packages <packages>

The python binary points to @executable_path/../lib/libpython3.12.dylib so it's already configured correctly with this new layout (i.e. python lib moved to python/lib).

The bin folder is .gdignore'd.

@Ivorforce Ivorforce force-pushed the python-bin branch 4 times, most recently from 9b5e79d to 956dd1a Compare October 28, 2024 15:54
… (save for the zip). Use the zip upload archive method in the github runner for macOS, too, to preserve permissions.
@maiself maiself added documentation Improvements or additions to documentation enhancement New feature or request build related to the build system export related to project export investigate needs further investigation labels Oct 29, 2024
uses: actions/upload-artifact@v4
with:
name: godot-python-${{ matrix.platform }}-${{ matrix.arch }}
path: bin/**/*
path: godot-python-${{ matrix.platform }}-${{ matrix.arch }}.zip
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was hoping providing a single path would make it upload the file as-is, but it's still zipping the zip. Need to find a better way.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build related to the build system documentation Improvements or additions to documentation enhancement New feature or request export related to project export investigate needs further investigation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants