Bug 1225921 - Package rubygem-hpricot does not build with gcc14 because of new errors
Summary: Package rubygem-hpricot does not build with gcc14 because of new errors
Status: NEW
Alias: None
Product: openSUSE Tumbleweed
Classification: openSUSE
Component: Development (show other bugs)
Version: Current
Hardware: Other Other
: P5 - None : Normal (vote)
Target Milestone: ---
Assignee: Marcus Rückert
QA Contact: E-mail List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: modern_C
  Show dependency treegraph
 
Reported: 2024-06-04 11:40 UTC by Martin Jambor
Modified: 2024-07-01 16:02 UTC (History)
0 users

See Also:
Found By: ---
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Jambor 2024-06-04 11:40:51 UTC
GCC 14 newly by default treats as errors a number of situations which
before were only warnings.  For more information see
https://gcc.gnu.org/gcc-14/porting_to.html and meta bug #1220571.

Because of this, package rubygem-hpricot fails to compile.  This can be seen online
at:
https://build.opensuse.org/package/live_build_log/openSUSE:Factory:Staging:Gcc7/rubygem-hpricot/standard/x86_64

It can be reproduced locally with command: osc build --clean
--alternative-project home:rguenther:nextgcc

The corresponding Gentoo bug might be https://bugs.gentoo.org/884257


The (first) error (that halts the build) is:

[    7s] fast_xs.c: In function ‘fast_xs’:
[    7s] fast_xs.c:165:46: error: passing argument 3 of ‘rb_rescue’ from incompatible pointer type [-Wincompatible-pointer-types]
[    7s]   165 |         array = rb_rescue(unpack_utf8, self, unpack_uchar, self);
[    7s]       |                                              ^~~~~~~~~~~~
[    7s]       |                                              |
[    7s]       |                                              VALUE (*)(VALUE) {aka long unsigned int (*)(long unsigned int)}
[    7s] In file included from /usr/include/ruby-3.3.0/ruby/ruby.h:41,
[    7s]                  from /usr/include/ruby-3.3.0/ruby.h:38,
[    7s]                  from fast_xs.c:1:
[    7s] /usr/include/ruby-3.3.0/ruby/internal/iterator.h:364:62: note: expected ‘VALUE (*)(VALUE,  VALUE)’ {aka ‘long unsigned int (*)(long unsigned int,  long unsigned int)’} but argument is of type ‘VALUE (*)(VALUE)’ {aka ‘long unsigned int (*)(long unsigned int)’}
[    7s]   364 | VALUE rb_rescue(VALUE (*b_proc)(VALUE), VALUE data1, VALUE (*r_proc)(VALUE, VALUE), VALUE data2);
[    7s]       |                                                      ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~