Actions
Bug #8455
closedLinking one Ruby extension to another Ruby extension with mkmf
Status:
Rejected
Assignee:
-
Target version:
-
ruby -v:
ruby 2.0.0p0 (2013-02-24 revision 39474) [x86_64-linux]
Backport:
Description
The problem lies within 'mkmf' of ruby.
If we have a gem which contains a native extension consisting of two libraries called 'libfail' and 'good' in C/C++ and both of these libraries have Ruby extensions it is not possible to compile and link them against each other without patching 'mkmf.rb'.
A sample git-repository is here: https://github.com/FlavourSys/ruby-native-extension-bug
If we call 'rake compile' it terminates with an error, because 'find_library' of 'mkmf' is not able to link against 'libfail'. The problem is that the 'ruby-static' libraries are added as g++ option before 'libfail' is.
A simple monkey patch is provided in the git repository. The solution is to just change the order of arguments for the compiler.
Files
Actions
Like0
Like0