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

Include st.h when using st_* functions #95

Closed
ged opened this issue Dec 17, 2011 · 8 comments
Closed

Include st.h when using st_* functions #95

ged opened this issue Dec 17, 2011 · 8 comments

Comments

@ged
Copy link
Owner

ged commented Dec 17, 2011

Original report by Anonymous.


In MRI, st.h is included in intern.h which is included in ruby.h. However, we do not include st.h in Rubinius. Since st_* functions are used, st.h should be explicitly included.

Alternatively, I'd suggest not using st_* functions at all. They are very much an implementation detail of MRI.

The include of st.h is the only blocker for building the pg gem under Rubinius 1.9 mode:

https://gist.github.com/1489400

Thanks,
Brian

@ged
Copy link
Owner Author

ged commented Dec 17, 2011

Original comment by Charles Nutter (Bitbucket: headius, GitHub: headius).


FWIW, JRuby's C ext support also does not include st.h, so consider this a second vote for avoiding its use.

@ged
Copy link
Owner Author

ged commented Dec 17, 2011

Original comment by Erik Michaels-Ober (Bitbucket: sferik, GitHub: sferik).


I'll add a third vote!

@ged
Copy link
Owner Author

ged commented Dec 17, 2011

Original comment by Kyle Drake (Bitbucket: kyledrake, GitHub: kyledrake).


Vote number four. This would be hugely helpful!

@ged
Copy link
Owner Author

ged commented Dec 17, 2011

Original comment by Anonymous.


+1 I'd love to be able to use the pg gem on Rubinius.

@ged
Copy link
Owner Author

ged commented Dec 17, 2011

Original comment by George Bellos (Bitbucket: georgedev, GitHub: georgedev).


another vote from me.

@ged
Copy link
Owner Author

ged commented Dec 21, 2011

Original comment by Michael Granger (Bitbucket: ged, GitHub: ged).


I'm happy to accept a patch that replaces the use of st_* functions, and works under MRI (1.8.7 and 1.9.3), JRuby, and the latest Rubinius (in both 1.8 and 1.9 modes).

In the meantime, I'll add an include for st.h.

@ged
Copy link
Owner Author

ged commented Dec 22, 2011

Original comment by Anonymous.


Any chance of a minor release with this fix? It'd be a nice Christmas present for Rubinius users :)

@ged
Copy link
Owner Author

ged commented Dec 28, 2011

Original comment by Michael Granger (Bitbucket: ged, GitHub: ged).


Explicitly include the st.h file for interpreters that need it (fixes #95)

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

No branches or pull requests

1 participant