Bug 2258823 - scipy fails to build with GCC 14 on i686: error: assignment to ‘npy_int32 *’ {aka ‘long int *’} from incompatible pointer type ‘int *’ [-Wincompatible-pointer-types]
Summary: scipy fails to build with GCC 14 on i686: error: assignment to ‘npy_int32 *’ ...
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: scipy
Version: rawhide
Hardware: Unspecified
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Nikola Forró
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: PortingToModernCExemptions F40FTBFS PYTHON3.13
TreeView+ depends on / blocked
 
Reported: 2024-01-17 15:46 UTC by Miro Hrončok
Modified: 2024-01-29 20:55 UTC (History)
9 users (show)

Fixed In Version: scipy-1.11.3-5.fc40
Clone Of:
Environment:
Last Closed: 2024-01-29 20:55:22 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
The easy fix (559 bytes, patch)
2024-01-29 16:34 UTC, Florian Weimer
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Github scipy scipy issues 19993 0 None open BUG: F_INT type conflict with f2py translation of INTEGER type on i386 2024-01-29 16:32:17 UTC

Description Miro Hrončok 2024-01-17 15:46:46 UTC
FAILED: scipy/interpolate/_fitpack.cpython-312-i386-linux-gnu.so.p/src__fitpackmodule.c.o
  gcc -Iscipy/interpolate/_fitpack.cpython-312-i386-linux-gnu.so.p -Iscipy/interpolate -I../scipy/interpolate -I../scipy/interpolate/src -I../../../../../usr/lib/python3.12/site-packages/numpy/core/include -I/usr/include/python3.12 -fvisibility=hidden -fdiagnostics-color=always -DNDEBUG -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -std=c99 -O3 -Wno-unused-but-set-variable -Wno-unused-function -Wno-conversion -Wno-misleading-indentation -O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m32 -march=i686 -mtune=generic -msse2 -mfpmath=sse -mstackrealign -fasynchronous-unwind-tables -fstack-clash-protection -fPIC -DNPY_NO_DEPRECATED_API=NPY_1_9_API_VERSION -MD -MQ scipy/interpolate/_fitpack.cpython-312-i386-linux-gnu.so.p/src__fitpackmodule.c.o -MF scipy/interpolate/_fitpack.cpython-312-i386-linux-gnu.so.p/src__fitpackmodule.c.o.d -o scipy/interpolate/_fitpack.cpython-312-i386-linux-gnu.so.p/src__fitpackmodule.c.o -c ../scipy/interpolate/src/_fitpackmodule.c
  ../scipy/interpolate/src/_fitpackmodule.c: In function ‘fitpack_bispev’:
  ../scipy/interpolate/src/_fitpackmodule.c:255:10: error: assignment to ‘npy_int32 *’ {aka ‘long int *’} from incompatible pointer type ‘int *’ [-Wincompatible-pointer-types]
    255 |     iwrk = (int *)(wrk + lwrk);
        |          ^

Reproducible: Always

Steps to Reproduce:
`fedpkg build --scratch` on i686
Actual Results:  
  ../scipy/interpolate/src/_fitpackmodule.c:255:10: error: assignment to ‘npy_int32 *’ {aka ‘long int *’} from incompatible pointer type ‘int *’ [-Wincompatible-pointer-types]

Expected Results:  
build should work

scipy-1.11.3-3.fc40

Comment 1 Florian Weimer 2024-01-29 16:34:21 UTC
Created attachment 2011390 [details]
The easy fix

This patch is needed to reach the good bits in the f2py-converted code.

Any idea how to teach the build system to preserve .mesonpy-*/scipy/interpolate/dfitpackmodule.c on error? Right now, I count on hitting C-z at the right time, so that the ninja build still proceeds far enough, but the cleanup doesn't run because the supervising process is stopped.

We'll have to downgrade C type safety on i686, I think.

Comment 2 Florian Weimer 2024-01-29 20:55:22 UTC
Worked around with an i686-specific compiler flags downgrade.


Note You need to log in before you can comment on or make changes to this bug.