On Tue, 28 Feb 2006 00:47:23 -0000, Sean Chittenden <[EMAIL PROTECTED]> wrote:
>> >> So anyway, here's the question: Does anyone know any links >> >> pertaining to building and linking interdependent ruby >> >> extensions? Or have any tips for me? >> > >> > During the dist-bzip2 phase of the makefile, *copy* a version of >> > ruby-libxml's headers into the libxslt tree. Then install a >> > version check at the load of the .so to confirm that ruby's >> > libxml/libxslt bindings are the same as current or within a micro >> > release. >> > >> > How's that sound? -sc >> >> Well, it works, which is good enough for me :) I've now got the >> libxslt-ruby source compiling without warnings and passing all the >> tests. I've not put the version check in yet - is there a better >> way than just comparing them with the header consts at the start of >> Init_libxslt ? > > Nope, that's about it. I'd look for major and minor versions. Daniel > is pretty good about not breaking ABI with micro releases and think > I've done a decent job in the past with the libxml/xsl bindings. -sc > Okay, for now I put in an #error thats hit if RUBY_LIBXML_VERNUM != RUBY_LIBXSLT_VERNUM , so it won't compile if the headers mismatch. Pretty crude I know but I had problems comparing the versions, because right now they're octal consts in the source, but will become decimal at version 1.x. I guess it could just check the string versions instead or something... ? I also added a LIBXML_TEST_VERSION in the Init_libxslt func, I couldn't find an equivalent in libxslt but it shouldn't be difficult to do. I guess libxml-ruby should have the same thing... Apart from that I think this codebase should go into CVS, I've not lost any data for, ooh, days and I'm starting to get jittery having uncommitted stuff ;) -- Ross Bamford - [EMAIL PROTECTED] _______________________________________________ libxml-devel mailing list [email protected] http://rubyforge.org/mailman/listinfo/libxml-devel
