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

issue with shared_libraries for appimage #29

Open
anchikai opened this issue Jan 20, 2023 · 7 comments
Open

issue with shared_libraries for appimage #29

anchikai opened this issue Jan 20, 2023 · 7 comments

Comments

@anchikai
Copy link

My project uses nuklear for handling all of its ui. So I built nuklear from source and I have nuklear.so in the project's root directory, aka ./nuklear.so as well as

[appimage]
shared_libraries = [
    "nuklear.so",
]

inside of makelove.toml.

With all of that said, running the appimage makes love error as it can't find nuklear.so.

@pfirsich
Copy link
Owner

Can you extract the AppImage and check whether the file is there and where it is? Which love version are you building for? From 11.4 the official AppImages are a bit different than the ones I built for earlier versions. Could you share the AppImage so I can have a look myself?

@anchikai
Copy link
Author

Hey my bad for not getting to you, I am using the latest version of love. When I extracted the AppImage it was called squashfs-root, and the .so is located at squashfs-root/usr/lib/nuklear.so.
Also github isn't letting me upload the AppImage through this comment, you have discord?

@anchikai
Copy link
Author

oh my bad, I'm actually using 11.3

@pfirsich
Copy link
Owner

Hey, I do have Discord, but I don't want to share my username + id publicly, I think. If you don't mind to share it, please do and I will contact you there. Or join the löve Discord server and ping me from there.

@MikuAuahDark
Copy link

MikuAuahDark commented Jan 31, 2023

The wrapper script needs to set LUA_PATH and LUA_CPATH environment variable to somewhere relative to the AppImage before launching LOVE https://github.com/pfirsich/love-appimages/blob/b58084eb23f6595617ad9511b5b136a7523e2f4d/build.py#L46-L54.

See https://github.com/love2d/love-appimage-source/blob/55ba1c5d9371dc7879764e9e657f6ca9198551bd/AppRun.c#L201-L214 on how it's done by modifying AppRun.c

@pfirsich
Copy link
Owner

pfirsich commented Feb 1, 2023

I knew I tested this in the past and now I find this again: https://github.com/pfirsich/love-appimages#handling-shared-libraries
It seems my plan was to adjust cpath from Lua, if the file is run from an AppImage.

@pfirsich
Copy link
Owner

Is that an acceptable solution for you?

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

No branches or pull requests

3 participants