-
Notifications
You must be signed in to change notification settings - Fork 97
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
Needs a way to do lookup in cstubs using dlsym/eglGetProcAddress #280
Comments
@whitequark if you have a clear idea of what should be done API-wise maybe you should expand a bit on that/explain the problem and try to make a more precise proposal (personally I'm completly ignorant of stub generation and don't have much time to work on that at the moment). For reference this is what Jeremy wrote about the problem at a certain point in time. |
The idea is very simple. Currently the stubs look like this:
With this proposal, they would look like:
The
This would add just one argument to This would be trivial if not for the many layers of abstraction between cstubs' interface and the generated C code. |
@yallop Any opinion on this? |
I'd like to support this kind of thing, but ideally via a general mechanism of customising the generated code (#211). In the short/medium term one possibility is to generate code that makes calls via a macro value stub(value foo) {
long c_foo = Long_val(foo);
CALL(c_call, c_foo);
return Val_unit;
} and allow you to redefine |
See dbuenzli/tgls#14 for details. I was going to implement this but the C representation used by cstubs is horrendously opaque and I am not motivated enough to figure it out.
The text was updated successfully, but these errors were encountered: