NetBSD Problem Report #56409

From john@daisy.zia.io  Sat Sep 18 15:59:27 2021
Return-Path: <john@daisy.zia.io>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits))
	(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
	by mollari.NetBSD.org (Postfix) with ESMTPS id AE4181A923A
	for <gnats-bugs@gnats.NetBSD.org>; Sat, 18 Sep 2021 15:59:27 +0000 (UTC)
Message-Id: <202109181559.18IFxIKe015980@daisy.zia.io>
Date: Sat, 18 Sep 2021 15:59:18 GMT
From: john@ziaspace.com
Reply-To: john@ziaspace.com
To: gnats-bugs@NetBSD.org
Subject: pkgsrc/graphics/php-gd fails to compile on NetBSD/amd64
X-Send-Pr-Version: 3.95

>Number:         56409
>Category:       pkg
>Synopsis:       pkgsrc/graphics/php-gd fails to compile on NetBSD/amd64
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    prlw1
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat Sep 18 16:00:00 +0000 2021
>Closed-Date:    Tue Sep 21 07:59:52 +0000 2021
>Last-Modified:  Tue Sep 21 07:59:52 +0000 2021
>Originator:     John Klos
>Release:        NetBSD 9.0_STABLE
>Organization:

>Environment:


System: NetBSD daisy.zia.io 9.0_STABLE NetBSD 9.0_STABLE (DAISY) #0: Tue Jul 28 04:48:43 UTC 2020 john@daisy.zia.io:/usr/obj-amd64/sys/arch/amd64/compile/DAISY amd64
Architecture: x86_64
Machine: amd64
>Description:


Attempting to update pkgsrc/graphics/php-gd with php 7.4.23 fails with:

/bin/sh /usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/libtool --mode=compile gcc  -I. -I/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd -DPHP_ATOM_INC -I/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/include -I/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/main -I/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -I/usr/local/include -I/usr/local/include/libpng16 -I/usr/X11R7/include/freetype2 -I/usr/X11R7/include  -I/usr/local/include -I/usr/include -I/usr/X11R7/include -I/usr/X11R7/include/freetype2 -DHAVE_CONFIG_H  -O2 -D_FORTIFY_SOURCE=2 -I/usr/local/include -I/usr/include -I/usr/X11R7/include -I/usr/X11R7/include/freetype2   -c /usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/gd.c -o gd.lo
libtool: compile:  gcc -I. -I/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd -DPHP_ATOM_INC -I/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/include -I/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/main -I/usr/pkgsrc/graphics/php-gd/work/.buildlink/include/php -I/usr/pkgsrc/graphics/php-gd/work/.buildlink/include/php/main -I/usr/pkgsrc/graphics/php-gd/work/.buildlink/include/php/TSRM -I/usr/pkgsrc/graphics/php-gd/work/.buildlink/include/php/Zend -I/usr/pkgsrc/graphics/php-gd/work/.buildlink/include/php/ext -I/usr/pkgsrc/graphics/php-gd/work/.buildlink/include/php/ext/date/lib -I/usr/pkgsrc/graphics/php-gd/work/.buildlink/include -I/usr/pkgsrc/graphics/php-gd/work/.buildlink/include/libpng16 -I/usr/pkgsrc/graphics/php-gd/work/.x11-buildlink/include/freetype2 -I/usr/pkgsrc/graphics/php-gd/work/.x11-buildlink/include -DHAVE_CONFIG_H -O2 -D_FORTIFY_SOURCE=2 -c /usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/gd.c  -fPIC -DPIC -o .libs/gd.o
In file included from /usr/pkgsrc/graphics/php-gd/work/.buildlink/include/php/main/php.h:441:0,
                 from /usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/gd.c:30:
/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/gd.c: In function 'zm_startup_gd':
/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/gd.c:1140:48: error: 'GD_FLIP_HORINZONTAL' undeclared (first use in this function); did you mean 'GD_AFFINE_SHEAR_HORIZONTAL'?
  REGISTER_LONG_CONSTANT("IMG_FLIP_HORIZONTAL", GD_FLIP_HORINZONTAL, CONST_CS | CONST_PERSISTENT);
                                                ^
/usr/pkgsrc/graphics/php-gd/work/.buildlink/include/php/Zend/zend_constants.h:53:105: note: in definition of macro 'REGISTER_LONG_CONSTANT'
 #define REGISTER_LONG_CONSTANT(name, lval, flags)  zend_register_long_constant((name), sizeof(name)-1, (lval), (flags), module_number)
                                                                                                         ^~~~
/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/gd.c:1140:48: note: each undeclared identifier is reported only once for each function it appears in
  REGISTER_LONG_CONSTANT("IMG_FLIP_HORIZONTAL", GD_FLIP_HORINZONTAL, CONST_CS | CONST_PERSISTENT);
                                                ^
/usr/pkgsrc/graphics/php-gd/work/.buildlink/include/php/Zend/zend_constants.h:53:105: note: in definition of macro 'REGISTER_LONG_CONSTANT'
 #define REGISTER_LONG_CONSTANT(name, lval, flags)  zend_register_long_constant((name), sizeof(name)-1, (lval), (flags), module_number)
                                                                                                         ^~~~
/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/gd.c:1141:46: error: 'GD_FLIP_VERTICAL' undeclared (first use in this function); did you mean 'GD_FLIP_HORINZONTAL'?
  REGISTER_LONG_CONSTANT("IMG_FLIP_VERTICAL", GD_FLIP_VERTICAL, CONST_CS | CONST_PERSISTENT);
                                              ^
/usr/pkgsrc/graphics/php-gd/work/.buildlink/include/php/Zend/zend_constants.h:53:105: note: in definition of macro 'REGISTER_LONG_CONSTANT'
 #define REGISTER_LONG_CONSTANT(name, lval, flags)  zend_register_long_constant((name), sizeof(name)-1, (lval), (flags), module_number)
                                                                                                         ^~~~
/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/gd.c:1142:42: error: 'GD_FLIP_BOTH' undeclared (first use in this function); did you mean 'GD_IO_H'?
  REGISTER_LONG_CONSTANT("IMG_FLIP_BOTH", GD_FLIP_BOTH, CONST_CS | CONST_PERSISTENT);
                                          ^
/usr/pkgsrc/graphics/php-gd/work/.buildlink/include/php/Zend/zend_constants.h:53:105: note: in definition of macro 'REGISTER_LONG_CONSTANT'
 #define REGISTER_LONG_CONSTANT(name, lval, flags)  zend_register_long_constant((name), sizeof(name)-1, (lval), (flags), module_number)
                                                                                                         ^~~~
/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/gd.c: In function 'zif_imageflip':
/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/gd.c:4699:8: error: 'GD_FLIP_VERTICAL' undeclared (first use in this function); did you mean '_LIB_VERSION'?
   case GD_FLIP_VERTICAL:
        ^~~~~~~~~~~~~~~~
        _LIB_VERSION
/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/gd.c:4703:8: error: 'GD_FLIP_HORINZONTAL' undeclared (first use in this function); did you mean 'GD_FLIP_VERTICAL'?
   case GD_FLIP_HORINZONTAL:
        ^~~~~~~~~~~~~~~~~~~
        GD_FLIP_VERTICAL
/usr/pkgsrc/graphics/php-gd/work/php-7.4.23/ext/gd/gd.c:4707:8: error: 'GD_FLIP_BOTH' undeclared (first use in this function); did you mean 'GD_IO_H'?
   case GD_FLIP_BOTH:
        ^~~~~~~~~~~~
        GD_IO_H
*** Error code 1

>How-To-Repeat:

>Fix:


>Release-Note:

>Audit-Trail:

Responsible-Changed-From-To: pkg-manager->prlw1
Responsible-Changed-By: prlw1@NetBSD.org
Responsible-Changed-When: Sun, 19 Sep 2021 16:25:10 +0000
Responsible-Changed-Why:
just testing a trivial fix


From: "Patrick Welche" <prlw1@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/56409 CVS commit: pkgsrc/graphics/gd
Date: Sun, 19 Sep 2021 19:25:14 +0000

 Module Name:	pkgsrc
 Committed By:	prlw1
 Date:		Sun Sep 19 19:25:14 UTC 2021

 Modified Files:
 	pkgsrc/graphics/gd: Makefile distinfo
 Added Files:
 	pkgsrc/graphics/gd/patches: patch-src_gd.h

 Log Message:
 Fix php-gd build PR pkg/56409


 To generate a diff of this commit:
 cvs rdiff -u -r1.130 -r1.131 pkgsrc/graphics/gd/Makefile
 cvs rdiff -u -r1.51 -r1.52 pkgsrc/graphics/gd/distinfo
 cvs rdiff -u -r0 -r1.1 pkgsrc/graphics/gd/patches/patch-src_gd.h

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

From: John Klos <john@ziaspace.com>
To: gnats-bugs@netbsd.org
Cc: prlw1@netbsd.org, gnats-admin@netbsd.org, pkgsrc-bugs@netbsd.org
Subject: Re: PR/56409 CVS commit: pkgsrc/graphics/gd
Date: Mon, 20 Sep 2021 20:23:18 +0000 (UTC)

 > Log Message:
 > Fix php-gd build PR pkg/56409

 Confirmed that this now builds in all the places I can test.

 Thanks,
 John Klos

State-Changed-From-To: open->closed
State-Changed-By: prlw1@NetBSD.org
State-Changed-When: Tue, 21 Sep 2021 07:59:52 +0000
State-Changed-Why:
Confirmed fixed - thanks for testing


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.