Package: libhpricot-ruby
Version: 0.5-2
Severity: serious
Tags: patch
User: [EMAIL PROTECTED]
Usertags: qa-ftbfs

hi,

while doing an archive wide package rebuild your package failed to build from
source for the following reason:

 > mkdir -p 
 > /build/user/libhpricot-ruby-0.5/debian/libhpricot-ruby1.8/usr/lib/ruby/1.8/i486-linux
 > /usr/bin/install -c -m 0755 hpricot_scan.so 
 > /build/user/libhpricot-ruby-0.5/debian/libhpricot-ruby1.8/usr/lib/ruby/1.8/i486-linux
 > make[1]: Leaving directory `/build/user/libhpricot-ruby-0.5'
 > dh_installdirs -plibhpricot-ruby1.9 
 > cd . 
 > /usr/bin/make distclean
 > make[1]: Entering directory `/build/user/libhpricot-ruby-0.5'
 > make[1]: Leaving directory `/build/user/libhpricot-ruby-0.5'
 > /usr/bin/ruby1.9  ext/hpricot_scan/extconf.rb 
 > checking for main() in -lc... yes
 > creating Makefile
 > /usr/bin/make
 > make[1]: Entering directory `/build/user/libhpricot-ruby-0.5'
 > cc -I. -I. -I/usr/lib/ruby/1.9/i486-linux -Iext/hpricot_scan  -fPIC 
 > -fno-strict-aliasing  -fPIC  -c ext/hpricot_scan/hpricot_scan.c
 > ext/hpricot_scan/hpricot_scan.rl: In function 'hpricot_scan':
 > ext/hpricot_scan/hpricot_scan.rl:239: error: 'struct RString' has no member 
 > named 'ptr'
 > ext/hpricot_scan/hpricot_scan.rl:252: error: 'struct RString' has no member 
 > named 'ptr'
 > ext/hpricot_scan/hpricot_scan.rl:252: error: 'struct RString' has no member 
 > named 'len'
 > ext/hpricot_scan/hpricot_scan.rl:253: error: 'struct RString' has no member 
 > named 'len'
 > ext/hpricot_scan/hpricot_scan.rl:269: error: 'struct RString' has no member 
 > named 'ptr'
 > make[1]: *** [hpricot_scan.o] Error 1
 > make[1]: Leaving directory `/build/user/libhpricot-ruby-0.5'
 > make: *** [install/libhpricot-ruby1.9] Error 2

The Full Build log is available and can be viewed at:

 http://people.debian.org/~lucas/logs/2007/06/01/

i think attached patch should fix this issue.
 
bye,
        - michael
diff -ruN libhpricot-ruby-0.5/ext/hpricot_scan/hpricot_scan.c ../libhpricot-ruby-0.5/ext/hpricot_scan/hpricot_scan.c
--- libhpricot-ruby-0.5/ext/hpricot_scan/hpricot_scan.c	2007-01-31 19:36:22.000000000 +0100
+++ ../libhpricot-ruby-0.5/ext/hpricot_scan/hpricot_scan.c	2007-06-04 10:20:14.952421398 +0200
@@ -140,7 +140,7 @@
       /* We've used up the entire buffer storing an already-parsed token
        * prefix that must be preserved.  Likely caused by super-long attributes.
        * See ticket #13. */
-      rb_raise(rb_eHpricotParseError, "ran out of buffer space on element <%s>, starting on line %d.", RSTRING(tag)->ptr, curline);
+      rb_raise(rb_eHpricotParseError, "ran out of buffer space on element <%s>, starting on line %d.", RSTRING_PTR(tag), curline);
     }
 
     if ( rb_respond_to( port, s_read ) )
@@ -153,8 +153,8 @@
     }
 
     StringValue(str);
-    memcpy( p, RSTRING(str)->ptr, RSTRING(str)->len );
-    len = RSTRING(str)->len;
+    memcpy( p, RSTRING_PTR(str), RSTRING_LEN(str));
+    len = RSTRING_LEN(str);
     nread += len;
 
     /* If this is the last buffer, tack on an EOF. */
@@ -5648,7 +5648,7 @@
       free(buf);
       if ( !NIL_P(tag) )
       {
-        rb_raise(rb_eHpricotParseError, "parse error on element <%s>, starting on line %d.\n" NO_WAY_SERIOUSLY, RSTRING(tag)->ptr, curline);
+        rb_raise(rb_eHpricotParseError, "parse error on element <%s>, starting on line %d.\n" NO_WAY_SERIOUSLY, RSTRING_PTR(tag), curline);
       }
       else
       {
diff -ruN libhpricot-ruby-0.5/ext/hpricot_scan/hpricot_scan.rl ../libhpricot-ruby-0.5/ext/hpricot_scan/hpricot_scan.rl
--- libhpricot-ruby-0.5/ext/hpricot_scan/hpricot_scan.rl	2007-01-30 22:11:19.000000000 +0100
+++ ../libhpricot-ruby-0.5/ext/hpricot_scan/hpricot_scan.rl	2007-06-04 10:19:41.706526825 +0200
@@ -236,7 +236,7 @@
       /* We've used up the entire buffer storing an already-parsed token
        * prefix that must be preserved.  Likely caused by super-long attributes.
        * See ticket #13. */
-      rb_raise(rb_eHpricotParseError, "ran out of buffer space on element <%s>, starting on line %d.", RSTRING(tag)->ptr, curline);
+      rb_raise(rb_eHpricotParseError, "ran out of buffer space on element <%s>, starting on line %d.", RSTRING_PTR(tag), curline);
     }
 
     if ( rb_respond_to( port, s_read ) )
@@ -249,8 +249,8 @@
     }
 
     StringValue(str);
-    memcpy( p, RSTRING(str)->ptr, RSTRING(str)->len );
-    len = RSTRING(str)->len;
+    memcpy( p, RSTRING_PTR(str), RSTRING_LEN(str));
+    len = RSTRING_LEN(str);
     nread += len;
 
     /* If this is the last buffer, tack on an EOF. */
@@ -266,7 +266,7 @@
       free(buf);
       if ( !NIL_P(tag) )
       {
-        rb_raise(rb_eHpricotParseError, "parse error on element <%s>, starting on line %d.\n" NO_WAY_SERIOUSLY, RSTRING(tag)->ptr, curline);
+        rb_raise(rb_eHpricotParseError, "parse error on element <%s>, starting on line %d.\n" NO_WAY_SERIOUSLY, RSTRING_PTR(tag), curline);
       }
       else
       {

Reply via email to