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

Implement VFS functions to load shared libraries from within LUAZIP archives #562

Draft
wants to merge 11 commits into
base: main
Choose a base branch
from

Conversation

rdw-software
Copy link
Member

@rdw-software rdw-software commented Sep 4, 2024

Things left to do:

  • Test on Windows (Should use .dll suffix instead of .so?)
  • Test on macOS (Use of .so should be fine, but what about .dylib?)
  • One of the "unit" tests is actually way too involved; can speed up? If not, move to integration test suite
  • Tests should ensure any temporary files are always cleaned (compare directory tree before/after each call)
  • Cleanup and possibly renames/refactoring - maybe later? Have to use the feature some more to get a feel for it
  • I don't like the ergonomics of having to manually vfs.decode before vfs.dlopen can be used (separate issue?)
  • Update the documentation (pending PR, to be merged after the next tagged release is available)

Resolves #488.

When using ffi.load this is seemingly handled by the underlying platform, but when attempting to load libraries from the VFS that isn't going to work.

There's no way around resolving names manually, since the files have to be extracted to a temporary directory and then loaded from disk (using the fully-qualified file name). Providing a separate function for the lookup  makes it easier to test and also allows users to check that resolution works as expected.
@rdw-software
Copy link
Member Author

Needs a design review. Not too happy with the API as well; holding off on completing this work. Maybe postpone to next release?

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