Skip to content

FTBFS (macOS 26.0/Tahoe) in gd #19

@dmacks

Description

@dmacks

Trying libwmf-0.2.13:

/bin/sh ../../../libtool  --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H  -DHAVE_UNISTD_H -DHAVE_LIBFREETYPE -DHAVE_LIBPNG -DHAVE_LIBJPEG -I. -I../../.. -I.  -I/opt/sw/include  -g -O2 -I/opt/sw/include/freetype2  -I/usr/X11/include       -MT gd.lo -MD -MP -MF .deps/gd.Tpo -c -o gd.lo gd.c
libtool: compile:  gcc -DHAVE_CONFIG_H -DHAVE_UNISTD_H -DHAVE_LIBFREETYPE -DHAVE_LIBPNG -DHAVE_LIBJPEG -I. -I../../.. -I. -I/opt/sw/include -g -O2 -I/opt/sw/include/freetype2 -I/usr/X11/include -MT gd.lo -MD -MP -MF .deps/gd.Tpo -c gd.c  -fno-common -DPIC -o .libs/gd.o
gd.c:2216:20: error: use of undeclared identifier 'SHRT_MAX'
 2216 |   if (w < 0 || w > SHRT_MAX || h < 0 || h > SHRT_MAX)
      |                    ^
gd.c:2216:45: error: use of undeclared identifier 'SHRT_MAX'
 2216 |   if (w < 0 || w > SHRT_MAX || h < 0 || h > SHRT_MAX)
      |                                             ^
2 errors generated.
libtool: compile:  gcc -DHAVE_CONFIG_H -DHAVE_UNISTD_H -DHAVE_LIBFREETYPE -DHAVE_LIBPNG -DHAVE_LIBJPEG -I. -I../../.. -I. -I/opt/sw/include -g -O2 -I/opt/sw/include/freetype2 -I/usr/X11/include -MT gd_gd2.lo -MD -MP -MF .deps/gd_gd2.Tpo -c gd_gd2.c  -fno-common -DPIC -o .libs/gd_gd2.o
gd_gd2.c:148:44: error: use of undeclared identifier 'INT_MAX'
  148 |       if (*ncx <= 0 || *ncy <= 0 || *ncx > INT_MAX / *ncy) {
      |                                            ^
1 error generated.
/bin/sh ../../../libtool  --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H  -DHAVE_UNISTD_H -DHAVE_LIBFREETYPE -DHAVE_LIBPNG -DHAVE_LIBJPEG -I. -I../../.. -I.  -I/opt/sw/include  -g -O2 -I/opt/sw/include/freetype2  -I/usr/X11/include       -MT gd_jpeg.lo -MD -MP -MF .deps/gd_jpeg.Tpo -c -o gd_jpeg.lo gd_jpeg.c
libtool: compile:  gcc -DHAVE_CONFIG_H -DHAVE_UNISTD_H -DHAVE_LIBFREETYPE -DHAVE_LIBPNG -DHAVE_LIBJPEG -I. -I../../.. -I. -I/opt/sw/include -g -O2 -I/opt/sw/include/freetype2 -I/usr/X11/include -MT gd_jpeg.lo -MD -MP -MF .deps/gd_jpeg.Tpo -c gd_jpeg.c  -fno-common -DPIC -o .libs/gd_jpeg.o
gd_jpeg.c:723:30: error: incompatible function pointer types assigning to 'boolean (*)(j_decompress_ptr)' (aka 'boolean (*)(struct jpeg_decompress_struct *)') from 'safeboolean (j_decompress_ptr)' (aka 'int (struct jpeg_decompress_struct *)') [-Wincompatible-function-pointer-types]
  723 |   src->pub.fill_input_buffer = fill_input_buffer;
      |                              ^ ~~~~~~~~~~~~~~~~~
gd_jpeg.c:855:33: error: incompatible function pointer types assigning to 'boolean (*)(j_compress_ptr)' (aka 'boolean (*)(struct jpeg_compress_struct *)') from 'safeboolean (j_compress_ptr)' (aka 'int (struct jpeg_compress_struct *)') [-Wincompatible-function-pointer-types]
  855 |   dest->pub.empty_output_buffer = empty_output_buffer;
      |                                 ^ ~~~~~~~~~~~~~~~~~~~
2 errors generated.

Recent actual libgd sources build fine for me. That's many-years newer than the 2.0.1beta included in libwmf, and includes lots of CVE and build-fixes. Given libwmf is currently unbuildable, is it time to re-visit Issue #5 ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions