Bug 219837

Summary: lang/php71, graphics/php71-gd, lang/php70, graphics/php70-gd: Remove unsupported options and add new option for webp
Product: Ports & Packages Reporter: Dani I. <i.dani>
Component: Individual Port(s)Assignee: Torsten Zuehlsdorff <tz>
Status: Closed FIXED    
Severity: Affects Many People CC: i.dani, tz
Priority: --- Flags: bugzilla: maintainer-feedback? (tz)
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
Remove unsupported options and add new option for webp (php71)
none
Remove unsupported options and add new option for webp support(php70&php71) i.dani: maintainer-approval? (tz)

Description Dani I. 2017-06-07 10:33:58 UTC
Created attachment 183285 [details]
Remove unsupported options and add new option for webp (php71)

As of PHP version 7.x, they removed support for the config-options T1LIB and VPX for the php7x-gd port/extension. In the same step they added webp-support, as successor for VPX. See: http://php.net/manual/en/image.installation.php

For this reason the Makefile.ext has to be patched and lang/php71 or just the graphics/php71-gd port has to be bumped.

Thanks for taking a look at it.

Bevor fixing the Makefile.ext the build log said the following:

---Begin OPTIONS List---
===> The following configuration options are available for php71-gd-7.1.5:
     T1LIB=on: Include T1lib support
     TRUETYPE=on: Enable TrueType string function
     JIS=off: Enable JIS-mapped Japanese font support
     X11=off: Enable XPM support
     VPX=on: Enable VP8 codec support
     
--CONFIGURE_ARGS--
--with-gd  --with-freetype-dir=/usr/local  --with-jpeg-dir=/usr/local  --with-png-dir=/usr/local  --with-zlib-dir=/usr --with-php-config=/usr/local/php71/bin/php-config --with-t1lib=/usr/local --enable-gd-native-ttf --with-vpx-dir=/usr/local --prefix=/usr/local/php71 ${_LATE_CONFIGURE_ARGS}
--End CONFIGURE_ARGS--

===>  Configuring for php71-gd-7.1.5
configure: WARNING: unrecognized options: --with-t1lib, --with-vpx-dir

-------------------------------------------------------------

After adding the patch, everything builds&works fine.

pkg info:
php71-gd-7.1.5
Name           : php71-gd
Version        : 7.1.5
Installed on   : Wed Jun  7 11:44:23 2017 CEST
Origin         : graphics/php71-gd
Architecture   : FreeBSD:10:amd64
Prefix         : /usr/local/php71
Categories     : graphics
Licenses       : PHP301
Maintainer     : tz@FreeBSD.org
WWW            : http://www.php.net/
Comment        : The gd shared extension for php
Options        :
	JIS            : off
	TRUETYPE       : on
	WEBP           : on
	X11            : off
Shared Libs required:
	libfreetype.so.6
	libwebp.so.7
	libpng16.so.16
	libjpeg.so.8

phpinfo:
GD Support 	enabled
GD Version 	bundled (2.1.0 compatible)
FreeType Support 	enabled
FreeType Linkage 	with freetype
FreeType Version 	2.8.0
GIF Read Support 	enabled
GIF Create Support 	enabled
JPEG Support 	enabled
libJPEG Version 	8
PNG Support 	enabled
libPNG Version 	1.6.29+apng
WBMP Support 	enabled
XBM Support 	enabled
WebP Support 	enabled
Comment 1 Dani I. 2017-06-07 10:38:54 UTC
The same has to be done for lang/php70 / graphics/php70-gd..

---Begin OPTIONS List---
===> The following configuration options are available for php70-gd-7.0.19:
     TRUETYPE=on: Enable TrueType string function
     JIS=off: Enable JIS-mapped Japanese font support
     WEBP=on: Enable WebP image format support
     X11=off: Enable XPM support
     
--CONFIGURE_ARGS--
--with-gd  --with-freetype-dir=/usr/local  --with-jpeg-dir=/usr/local  --with-png-dir=/usr/local  --with-zlib-dir=/usr --with-php-config=/usr/local/php70/bin/php-config --enable-gd-native-ttf --with-webp-dir=/usr/local --prefix=/usr/local/php70 ${_LATE_CONFIGURE_ARGS}
--End CONFIGURE_ARGS--  
     

php70-gd-7.0.19
Name           : php70-gd
Version        : 7.0.19
Installed on   : Wed Jun  7 11:57:44 2017 CEST
Origin         : graphics/php70-gd
Architecture   : FreeBSD:10:amd64
Prefix         : /usr/local/php70
Categories     : graphics
Licenses       : PHP301
Maintainer     : tz@FreeBSD.org
WWW            : http://www.php.net/
Comment        : The gd shared extension for php
Options        :
	JIS            : off
	TRUETYPE       : on
	WEBP           : on
	X11            : off
Shared Libs required:
	libfreetype.so.6
	libwebp.so.7
	libpng16.so.16
	libjpeg.so.8
Comment 2 Dani I. 2017-06-07 10:42:12 UTC
Created attachment 183286 [details]
Remove unsupported options and add new option for webp support(php70&php71)
Comment 3 commit-hook freebsd_committer freebsd_triage 2017-06-09 09:44:17 UTC
A commit references this bug:

Author: tz
Date: Fri Jun  9 09:43:52 UTC 2017
New revision: 442977
URL: https://svnweb.freebsd.org/changeset/ports/442977

Log:
  graphics/php70-gd: remove options T1LIB and VPX, add option WEBP

  Support for T1LIB and VPX was removed in PHP 7.0
  Support for WebP support was added in PHP 7.0

  PR:           219837
  Submitted by: Dani <i.dani@outlook.com>

Changes:
  head/graphics/php70-gd/Makefile
  head/lang/php70/Makefile.ext
Comment 4 commit-hook freebsd_committer freebsd_triage 2017-06-09 09:45:19 UTC
A commit references this bug:

Author: tz
Date: Fri Jun  9 09:44:34 UTC 2017
New revision: 442978
URL: https://svnweb.freebsd.org/changeset/ports/442978

Log:
  graphics/php71-gd: remove options T1LIB and VPX, add option WEBP

  Support for T1LIB and VPX was removed in PHP 7.0
  Support for WebP support was added in PHP 7.0

  PR:           219837
  Submitted by: Dani <i.dani@outlook.com>

Changes:
  head/graphics/php71-gd/Makefile
  head/lang/php71/Makefile.ext
Comment 5 Torsten Zuehlsdorff freebsd_committer freebsd_triage 2017-06-09 09:46:36 UTC
Great catch, patch and PR. Committed, thanks! :)

Since there was already a new PHP version released i plan to merge this commit together with the update into quarterly next week.