Bug 1228342

Summary: Package texlive does not build with gcc 14 on i586 because of use of incompatible pointer types
Product: [openSUSE] openSUSE Tumbleweed Reporter: Martin Jambor <mjambor>
Component: OtherAssignee: E-mail List <screening-team-bugs>
Status: NEW --- QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None CC: werner
Version: Current   
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Bug Depends on:    
Bug Blocks: 1220571    

Description Martin Jambor 2024-07-25 19:12:39 UTC
Package texlive fails to build with GCC 14 on i586 (and probably othr 32bit architectures too) because of various C99 violations which previously just generated warning s but which cause errors with GCC 14 by default (see meta bug#1220571).

The (first) problem stopping the build is:

pdftexini.c: In function 'loadfmtfile':
pdftexini.c:4016:25: error: assignment to 'boolean *' {aka 'int *'} from incompatible pointer type 'internalfontnumber  ' {aka 'long int *'} [-Wincompatible-pointer-types]
 4016 |     pdffonthasspacechar = xmallocarray ( internalfontnumber , fontmax ) ;
      |                         ^
pdftexini.c: In function 'mainbody':
pdftexini.c:5569:27: error: assignment to 'boolean *' {aka 'int *'} from incompatible pointer type 'internalfontnumber  ' {aka 'long int *'} [-Wincompatible-pointer-types]
 5569 |       pdffonthasspacechar = xmallocarray ( internalfontnumber , fontmax ) ;
      |                           ^

so IIUC double the necessary size is allocated rater than just half but it looks like a genuine type issue.  We can work-around the issue by building with -Wno-error=incompatible-pointer-types (on 32 bit architectures) but it is always better to fix these issues.

I admit that so far I am super puzzled where the file texk/web2c/pdftexini.c comes from (or rather how it is generated?) so I'd be grateful if someone who knows the package better looked at this.
Comment 1 Martin Jambor 2024-07-26 15:48:13 UTC
I have created https://build.opensuse.org/request/show/1189820 to work around the problem until we can fix it.

My plan is to not close the bug and keep an eye on the package and remove the option disabling the error when (upstream hopefully fixes it and) we can do so.