gprolog-1.5.0 fails to compile on Linux/Debian/Trixie/x86-64 (or Ubuntu 24)

Basile Starynkevitch <[email protected]> Wed, 26 Nov 2025 12:29:48 +0100
Newsgroups gmane.comp.gnu.prolog.bugs
Message-ID <[email protected]>
Hello


(cd ../TopComp; make gplc)
make[2]: Entering directory '/usr/src/Lang/gprolog-1.5.0/src/TopComp'
gcc  -fno-strict-aliasing -fcommon -O2 -g -Wall -Wno-char-subscripts -o gpl=
c top_comp.c -lm
make[2]: Leaving directory '/usr/src/Lang/gprolog-1.5.0/src/TopComp'
make[1]: Leaving directory '/usr/src/Lang/gprolog-1.5.0/src/EnginePl'
. ./SETVARS;for i in EnginePl TopComp Wam2Ma Ma2Asm Linedit BipsPl Pl2Wam F=
d2C EngineFD BipsFD;do (cd $i; make) || exit 1; done;\
(cd TopComp; make top-level) || exit 1;\
(cd Pl2Wam; make stage2)
make[1]: Entering directory '/usr/src/Lang/gprolog-1.5.0/src/EnginePl'
gcc  -fno-strict-aliasing -fcommon -O2 -g -Wall -Wno-char-subscripts  -o cp=
p_headers cpp_headers.c
gplc -c -C '-O2 -g -Wall -Wno-char-subscripts' machine.c
gplc -c -C '-O2 -g -Wall -Wno-char-subscripts' machine1.c
gplc -c -C '-O2 -g -Wall -Wno-char-subscripts' stacks_sigsegv.c
stacks_sigsegv.c:470:1: error: conflicting types for =E2=80=98SIGSEGV_Handl=
er=E2=80=99; have =E2=80=98void(int,  siginfo_t *, void *)=E2=80=99
  470 | SIGSEGV_Handler(int sig, siginfo_t *sip, void *scp)
      | ^~~~~~~~~~~~~~~
stacks_sigsegv.c:140:13: note: previous declaration of =E2=80=98SIGSEGV_Han=
dler=E2=80=99 with type =E2=80=98void(void)=E2=80=99
  140 | static void SIGSEGV_Handler();
      |             ^~~~~~~~~~~~~~~
compilation failed
make[1]: *** [Makefile:29: stacks_sigsegv.o] Error 1
make[1]: Leaving directory '/usr/src/Lang/gprolog-1.5.0/src/EnginePl'
make: *** [Makefile:45: all] Error 1



I believe that to fix that bug (for GCC 15 or GCC trunk on Linux/Debian/ ..=
.) the line stacks_sigsegv.c:140
should contain:

static void SIGSEGV_Handler(int, siginfo_t*, void*);


--=20

Basile STARYNKEVITCH                    basile AT starynkevitch DOT net
8 rue de la Fa=C3=AFencerie                       http://starynkevitch.net/=
Basile/ =20
92340 Bourg-la-Reine                         https://github.com/bstarynk
France                                https://github.com/RefPerSys/RefPerSy=
s
                  https://orcid.org/0000-0003-0908-5250