consider making the wrapper independent of nimterop and publish the actual generated wrapper #1

Closed
opened 2020-09-15 19:29:59 +00:00 by HugoP707 · 2 comments
HugoP707 commented 2020-09-15 19:29:59 +00:00 (Migrated from github.com)

Its an issue very specific tbh, but i just have problems installing nimterop, and i cant use the wrapper, however, if im not mistaken, nimterop generated wrappers no longer need the library to work, so uploading the generated wrapper directly would be very useful.

Its an issue very specific tbh, but i just have problems installing nimterop, and i cant use the wrapper, however, if im not mistaken, nimterop generated wrappers no longer need the library to work, so uploading the generated wrapper directly would be very useful.
jyapayne commented 2020-09-15 20:26:53 +00:00 (Migrated from github.com)

There are a couple problems with generating the wrapper and storing it in Git.

The first is that the wrapper generated is platform dependent (since nimterop runs a preprocessor on the C headers, any platform independent code gets lost). I would need to generate the wrapper for each platform (may not matter in glfw's case, since there doesn't appear to be much in the way of that from just a quick scan through)

The second is that it can easily get out of date if the generation isn't maintained. Ideally it should be automated.

That being said, I've created a file called src/glfw/glfw_standalone.nim with a warning at the top and some instructions. Let me know if it works for you. You'll probably have to clone the repo manually since nimble will still try to install nimterop.

There are a couple problems with generating the wrapper and storing it in Git. The first is that the wrapper generated is platform dependent (since nimterop runs a preprocessor on the C headers, any platform independent code gets lost). I would need to generate the wrapper for each platform (may not matter in glfw's case, since there doesn't appear to be much in the way of that from just a quick scan through) The second is that it can easily get out of date if the generation isn't maintained. Ideally it should be automated. That being said, I've created a file called `src/glfw/glfw_standalone.nim` with a warning at the top and some instructions. Let me know if it works for you. You'll probably have to clone the repo manually since nimble will still try to install nimterop.
HugoP707 commented 2020-09-25 12:09:36 +00:00 (Migrated from github.com)

thanks for the information, my nimterop problems are not related to this package though, so until i can fix that, i wont be able to use the wrapper thanks for the answer anyway

thanks for the information, my nimterop problems are not related to this package though, so until i can fix that, i wont be able to use the wrapper thanks for the answer anyway
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
jyapayne/nim-glfw#1
No description provided.