Sam Ruby wrote:
Trans wrote:
I updated the Rakefile to shell out to the task/* scripts.
Thanks!
With the attached patch, I've the following sequence works on Ruby 1.9,
revision 15360 (the latest HEAD):
rake clobber
rake compile
rake test
The patch should not be applies as is, as the rename of util.h to
ruby/util.h is a breaking change. Should be easy enough to handle in
extconf.rb.
My goal is to keep a watch on Ruby 19 and libxml2 to ensure that neither
commits any changes that breaks the other. More details can be found here:
http://intertwingly.net/blog/2008/01/31/Ruby-CI-Efforts
Let me know if you commit these changes, or how you want the extconf
changes to be handled, as once basic Ruby 1.9 support is in place, I
will add libxml to my list.
- Sam Ruby
Oops. This time, I'm going to include the patch. :-)
- Sam Ruby
Index: ext/libxml/libxml.c
===================================================================
--- ext/libxml/libxml.c (revision 256)
+++ ext/libxml/libxml.c (working copy)
@@ -4,9 +4,6 @@
#include "libxml.h"
-/* Ruby's util.h has ruby_strdup */
-#include "util.h"
-
#ifdef xmlMalloc
#undef xmlMalloc
#endif
Index: ext/libxml/libxml.h
===================================================================
--- ext/libxml/libxml.h (revision 256)
+++ ext/libxml/libxml.h (working copy)
@@ -18,7 +18,7 @@
#include <ruby.h>
#include <rubyio.h>
-#include <util.h>
+#include <ruby/util.h>
#include <libxml/parser.h>
#include <libxml/parserInternals.h>
#include <libxml/debugXML.h>
@@ -35,6 +35,12 @@
#define RSTRING_LEN(x) RSTRING(x)->len
#endif
+// not in Ruby 1.9
+#ifndef GetWriteFile
+#define GetWriteFile(fp) rb_io_stdio_file(fp)
+#define OpenFile rb_io_t
+#endif
+
#ifdef LIBXML_DEBUG_ENABLED
#include <libxml/xpathInternals.h>
#endif
_______________________________________________
libxml-devel mailing list
libxml-devel@rubyforge.org
http://rubyforge.org/mailman/listinfo/libxml-devel