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

How to use dlopen() on Android 8? #57

Closed
RPG3D opened this issue Apr 16, 2019 · 6 comments
Closed

How to use dlopen() on Android 8? #57

RPG3D opened this issue Apr 16, 2019 · 6 comments

Comments

@RPG3D
Copy link

RPG3D commented Apr 16, 2019

In my test ndk app, dlopen() reutrn nullptr.

Java_com_github_rpg3d_sword2android_MainActivity_runGame(JNIEnv* env, jobject /* this */)
{

    void* handle = dlopen("libvulkan.so", RTLD_NOW|RTLD_LOCAL);
    char* loaderror = (char *) dlerror();
    Game game;
    game.run();

}
@ggfan
Copy link
Contributor

ggfan commented Apr 16, 2019

that should be the way. Is Vulkan supported on the device?

@RPG3D
Copy link
Author

RPG3D commented Apr 17, 2019

that should be the way. Is Vulkan supported on the device?

yes. my device can run your LoadVulkan sample, but not my own test app

@ggfan
Copy link
Contributor

ggfan commented Apr 17, 2019

I am not sure what the problem is. you are also using native-activity? ( not sure that matters at all)

Re-run the app while keep "adb logcat" running on command line, see if you could have some clue from there ( adb logcat ): it normally throw error message ( but buried in million of other non-related messages ) :-(

@RPG3D
Copy link
Author

RPG3D commented Apr 17, 2019

In single module it runs well. but in multi module app didn't.
would you give me some help ? I am portting an old 2D PC game to Android, but failed...
https://github.com/RPG3D/Sword2

@Andreyogld3d
Copy link

@RPG3D, try to use vulkan_wrapper.cpp instead of manually loading of Vulkan API functions

@RPG3D
Copy link
Author

RPG3D commented Dec 22, 2020

@RPG3D, try to use vulkan_wrapper.cpp instead of manually loading of Vulkan API functions

thanks, I will do some test

@RPG3D RPG3D closed this as completed Dec 22, 2020
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