Bug#846353: FTBFS: ERROR: Test "ruby2.3" failed. Exiting.
Gilles Filippini
pini at debian.org
Sat Dec 3 18:19:25 UTC 2016
Control: block -1 by 846853
Control: tags -1 + patch
Gilles Filippini a écrit le 03/12/2016 à 02:34 :
> Gilles Filippini a écrit le 03/12/2016 à 01:35 :
>> Gilles Filippini a écrit le 02/12/2016 à 23:26 :
>>> Sebastiaan Couwenberg a écrit le 02/12/2016 à 15:34 :
>>>> On 12/02/2016 09:55 AM, Sebastiaan Couwenberg wrote:
>>>>> On 12/01/2016 07:48 PM, Sebastiaan Couwenberg wrote:
>>>>>> On Wed, 30 Nov 2016 15:10:03 +0000 Iain Lane wrote:
>>>>>>> This package FTBFS on 32 bit arches (works on amd64 and other 64 bit
>>>>>>> arches), maybe due to the new hdf5
>>>>>>
>>>>>> Quite likely, since hdf-eos5 hasn't been rebuilt for the hdf5 transition
>>>>>> yet. I suspect this issue to fix itself once that's done.
>>>>>
>>>>> It did not, but did only fail on 32-bit architectures.
>>>>
>>>> Gilles, these failures seem to be caused by the hid_t type change from
>>>> 32-bit to a 64-bit value. I'm not sure how to fix it for ruby-hdfeos5,
>>>> can you maybe provide a patch?
>>>
>>> Damn, I tested the build on amd64 only :/
>>> I've tried fixing the 'incompatible pointer type' warning, but it
>>> deosn't change anything wrt the test suite.
>>> Is there a way to ensure first that hdf-eos5 works fine on 32 bit archs?
>>
>> CC-ing Alastair, maintainer of hdf-eos5.
>>
>> AIUI the problem lies in hdf-eos5. I've ran a very simple C test made
>> after the first lines of test/test_gd.rb (source attached), both on
>> amd64 and i386. It succeeds on amd64 and fails on i386 at the
>> HE5_GDdetach step with:
>>
>> $ ./myhe5-32
>> bufsize = 19
>> ColumnAmountAerosol
>> HDF5-DIAG: Error detected in HDF5 (1.10.0-patch1) thread 4142823168:
>> #000: GDapi.c line 1140 in HE5_GDchkgdid(): Cannot get the Grid index
>>
>> major: Invalid arguments to routine
>> minor: Out of range
>> HDF5-DIAG: Error detected in HDF5 (1.10.0-patch1) thread 4142823168:
>> #000: EHapi.c line 2206 in HE5_EHchkfid(): Invalid file ID: 0. ID
>> should range from 67108864 to 67109064 .
>>
>> major: Invalid arguments to routine
>> minor: Bad value
>> HDF5-DIAG: Error detected in HDF5 (1.10.0-patch1) thread 4142823168:
>> #000: GDapi.c line 1151 in HE5_GDchkgdid(): Checking for file ID failed.
>>
>> major: Invalid arguments to routine
>> minor: Out of range
>> HDF5-DIAG: Error detected in HDF5 (1.10.0-patch1) thread 4142823168:
>> #000: GDapi.c line 12623 in HE5_GDdetach(): Checking for grid ID failed.
>>
>> major: Invalid arguments to routine
>> minor: Out of range
>
> The problem seems to be the type conversion functions in EHapi.c. For
> instance:
>
> long
> HE5_EHhid2long(hid_t invalue)
> {
> long outvalue = FAIL;
>
> if (sizeof(hid_t) == sizeof(int))
> outvalue = HE5_EHint2long(invalue);
> else if (sizeof(hid_t) == sizeof(long))
> outvalue = invalue;
>
> return(outvalue);
> }
>
> On 32 bit archs:
> sizeof(hid_t) != sizeof(int)
> sizeof(hid_t) != sizeof(long)
> sizeof(hid_t) == sizeof(long long)
>
> The conversion functions should be adapted accordingly.
I've filed #846853 against src:hdf-eos5. There are issues in
ruby-hdfeos5 as well. See the attached patch.
With these fixes the ruby-hdfeos5 testsuite passes on 64 bit and 32 bit
arches.
Thanks,
_g.
-------------- next part --------------
diff -Nru ruby-hdfeos5-1.2/debian/changelog ruby-hdfeos5-1.2/debian/changelog
--- ruby-hdfeos5-1.2/debian/changelog 2016-03-01 10:16:48.000000000 +0100
+++ ruby-hdfeos5-1.2/debian/changelog 2016-12-03 18:55:27.000000000 +0100
@@ -1,3 +1,10 @@
+ruby-hdfeos5 (1.2-6.1) unstable; urgency=medium
+
+ * Non-maintainer upload
+ * Fix FTBFS on 32 bi architectures against hdf5 1.10 (closes: #846353)
+
+ -- Gilles Filippini <pini at debian.org> Sat, 03 Dec 2016 18:55:27 +0100
+
ruby-hdfeos5 (1.2-6) unstable; urgency=medium
* Remove dbg package
diff -Nru ruby-hdfeos5-1.2/debian/patches/hid_t.patch ruby-hdfeos5-1.2/debian/patches/hid_t.patch
--- ruby-hdfeos5-1.2/debian/patches/hid_t.patch 1970-01-01 01:00:00.000000000 +0100
+++ ruby-hdfeos5-1.2/debian/patches/hid_t.patch 2016-12-03 15:23:32.000000000 +0100
@@ -0,0 +1,142 @@
+Index: ruby-hdfeos5-1.2/hdfeos5gd_wrap.c
+===================================================================
+--- ruby-hdfeos5-1.2.orig/hdfeos5gd_wrap.c
++++ ruby-hdfeos5-1.2/hdfeos5gd_wrap.c
+@@ -20,7 +20,7 @@
+ #endif
+
+ extern int check_numbertype(char *);
+-extern int change_numbertype(char *);
++extern hid_t change_numbertype(char *);
+ extern int change_entrycode(char *);
+ extern int change_projcode(char *);
+ extern int change_compmethod(char *);
+@@ -1327,7 +1327,7 @@ hdfeos5_gdinqfields(VALUE mod, VALUE ent
+
+ i_count = (int)o_nflds;
+ rank = hdfeos5_cintary2obj(o_rank, i_count, 1, &i_count);
+- ntype = hdfeos5_cintary2obj(o_ntype, i_count, 1, &i_count);
++ ntype = hdfeos5_cunsint64ary2obj(o_ntype, i_count, 1, &i_count);
+
+ return rb_ary_new3(4, nflds, fieldlist, rank, ntype);
+ }
+@@ -1905,12 +1905,12 @@ hdfeos5_gdsetextdata(VALUE mod, VALUE fi
+ size = rb_Array(size);
+ }
+ i_filelist = RSTRING_PTR(filelist);
+- i_offset = hdfeos5_obj2clongary(offset);
++ i_offset = hdfeos5_obj2cunsint64ary(offset);
+ i_size = hdfeos5_obj2cunsint64ary(size);
+
+ o_rtn_val = HE5_GDsetextdata(i_gridid, i_filelist, i_offset, i_size);
+ rtn_val = (o_rtn_val == FAIL) ? Qfalse : Qtrue;
+- hdfeos5_freeclongary(i_offset);
++ hdfeos5_freecunsint64ary(i_offset);
+ hdfeos5_freecunsint64ary(i_size);
+ return rtn_val;
+ }
+@@ -1946,7 +1946,7 @@ hdfeos5_gdgetextdata(VALUE mod, VALUE fi
+
+ namelength = hdfeos5_cintary2obj((int*)o_namelength,o_nfiles,1,&o_nfiles);
+ filelist = hdfeos5_ccharary2obj(o_filelist,o_nfiles,o_nfiles);
+- offset = hdfeos5_clongary2obj(o_offset,o_nfiles,1,&o_nfiles);
++ offset = hdfeos5_cunsint64ary2obj(o_offset,o_nfiles,1,&o_nfiles);
+ size = hdfeos5_cunsint64ary2obj(o_size,o_nfiles,1,&o_nfiles);
+
+ return rb_ary_new3(5,nfiles, namelength, filelist, offset, size);
+Index: ruby-hdfeos5-1.2/hdfeos5sw_wrap.c
+===================================================================
+--- ruby-hdfeos5-1.2.orig/hdfeos5sw_wrap.c
++++ ruby-hdfeos5-1.2/hdfeos5sw_wrap.c
+@@ -1098,7 +1098,7 @@ hdfeos5_swinqdatafields(VALUE mod, VALUE
+
+ i_count = (int)o_nflds;
+ rank = hdfeos5_cintary2obj(o_rank, i_count, 1, &i_count);
+- ntype = hdfeos5_cintary2obj(o_ntype, i_count, 1, &i_count);
++ ntype = hdfeos5_cunsint64ary2obj(o_ntype, i_count, 1, &i_count);
+
+ return rb_ary_new3(4, nflds, fieldlist, rank, ntype);
+ }
+@@ -1139,7 +1139,7 @@ hdfeos5_swinqgeofields(VALUE mod, VALUE
+
+ i_count = (int)o_nflds;
+ rank = hdfeos5_cintary2obj(o_rank, i_count, 1, &i_count);
+- ntype = hdfeos5_cintary2obj(o_ntype, i_count, 1, &i_count);
++ ntype = hdfeos5_cunsint64ary2obj(o_ntype, i_count, 1, &i_count);
+
+ return rb_ary_new3(4, nflds, fieldlist, rank, ntype);
+ }
+@@ -2685,12 +2685,12 @@ hdfeos5_swsetextdata(VALUE mod, VALUE fi
+ size = rb_Array(size);
+ }
+ i_filelist = RSTRING_PTR(filelist);
+- i_offset = hdfeos5_obj2clongary(offset);
++ i_offset = hdfeos5_obj2cunsint64ary(offset);
+ i_size = hdfeos5_obj2cunsint64ary(size);
+
+ o_rtn_val = HE5_SWsetextdata(i_swathid, i_filelist, i_offset, i_size);
+ rtn_val = (o_rtn_val == FAIL) ? Qfalse : Qtrue;
+- hdfeos5_freeclongary(i_offset);
++ hdfeos5_freecunsint64ary(i_offset);
+ hdfeos5_freecunsint64ary(i_size);
+ return rtn_val;
+ }
+@@ -2726,7 +2726,7 @@ hdfeos5_swgetextdata(VALUE mod, VALUE fi
+
+ namelength = hdfeos5_cintary2obj((int*)o_namelength,o_rtn_val,1,&o_rtn_val);
+ filelist = hdfeos5_ccharary2obj(o_filelist,o_rtn_val,o_rtn_val);
+- offset = hdfeos5_clongary2obj(o_offset,o_rtn_val,1,&o_rtn_val);
++ offset = hdfeos5_cunsint64ary2obj(o_offset,o_rtn_val,1,&o_rtn_val);
+ size = hdfeos5_cunsint64ary2obj(o_size,o_rtn_val,1,&o_rtn_val);
+
+ return rb_ary_new3(5,rtn_val, namelength, filelist, offset, size);
+Index: ruby-hdfeos5-1.2/hdfeos5za_wrap.c
+===================================================================
+--- ruby-hdfeos5-1.2.orig/hdfeos5za_wrap.c
++++ ruby-hdfeos5-1.2/hdfeos5za_wrap.c
+@@ -785,7 +785,7 @@ hdfeos5_zainquire(VALUE mod, VALUE entry
+
+ i_count = (int)o_nflds;
+ rank = hdfeos5_cintary2obj(o_rank, i_count, 1, &i_count);
+- ntype = hdfeos5_cintary2obj(o_ntype, i_count, 1, &i_count);
++ ntype = hdfeos5_cunsint64ary2obj(o_ntype, i_count, 1, &i_count);
+
+ return rb_ary_new3(4, nflds, fieldlist, rank, ntype);
+ }
+@@ -1603,12 +1603,12 @@ hdfeos5_zasetextdata(VALUE mod, VALUE fi
+ size = rb_Array(size);
+ }
+ i_filelist = RSTRING_PTR(filelist);
+- i_offset = hdfeos5_obj2clongary(offset);
++ i_offset = hdfeos5_obj2cunsint64ary(offset);
+ i_size = hdfeos5_obj2cunsint64ary(size);
+
+ o_rtn_val = HE5_ZAsetextdata(i_zaid, i_filelist, i_offset, i_size);
+ rtn_val = (o_rtn_val == FAIL) ? Qfalse : Qtrue;
+- hdfeos5_freeclongary(i_offset);
++ hdfeos5_freecunsint64ary(i_offset);
+ hdfeos5_freecunsint64ary(i_size);
+ return rtn_val;
+ }
+@@ -1644,7 +1644,7 @@ hdfeos5_zagetextdata(VALUE mod, VALUE fi
+
+ namelength = hdfeos5_cintary2obj((int*)o_namelength,o_rtn_val,1,&o_rtn_val);
+ filelist = hdfeos5_ccharary2obj(o_filelist,o_rtn_val,o_rtn_val);
+- offset = hdfeos5_clongary2obj(o_offset,o_rtn_val,1,&o_rtn_val);
++ offset = hdfeos5_cunsint64ary2obj(o_offset,o_rtn_val,1,&o_rtn_val);
+ size = hdfeos5_cunsint64ary2obj(o_size,o_rtn_val,1,&o_rtn_val);
+
+ return rb_ary_new3(5,rtn_val, namelength, filelist, offset, size);
+Index: ruby-hdfeos5-1.2/hdfeos5_chkdatatype.c
+===================================================================
+--- ruby-hdfeos5-1.2.orig/hdfeos5_chkdatatype.c
++++ ruby-hdfeos5-1.2/hdfeos5_chkdatatype.c
+@@ -156,7 +156,7 @@ check_numbertype(char *numbertype)
+ __FILE__,__LINE__);
+ }
+
+-int
++hid_t
+ change_numbertype(char *numbertype)
+ {
+ if(strcmp(numbertype,"byte")==0) return(H5T_NATIVE_CHAR);
diff -Nru ruby-hdfeos5-1.2/debian/patches/series ruby-hdfeos5-1.2/debian/patches/series
--- ruby-hdfeos5-1.2/debian/patches/series 2015-09-04 07:56:38.000000000 +0200
+++ ruby-hdfeos5-1.2/debian/patches/series 2016-12-03 18:27:12.000000000 +0100
@@ -2,3 +2,4 @@
0002-Fix-test-data-path.patch
0003-Fix-printf-debugging.patch
0004-hdf5-dir.patch
+hid_t.patch
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 480 bytes
Desc: OpenPGP digital signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-grass-devel/attachments/20161203/a44847fc/attachment.sig>
More information about the Pkg-grass-devel
mailing list