Bug 217318 - www/piwigo build error with php70
Summary: www/piwigo build error with php70
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: amd64 Any
: --- Affects Some People
Assignee: Torsten Zuehlsdorff
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-02-24 09:15 UTC by Marko Cupać
Modified: 2017-03-14 11:44 UTC (History)
2 users (show)

See Also:
tremere: maintainer-feedback+


Attachments
piwigo poudriere log (4.70 KB, text/plain)
2017-02-24 09:15 UTC, Marko Cupać
no flags Details
Patch proposal for PHP 7 fix (469 bytes, patch)
2017-02-24 09:23 UTC, Torsten Zuehlsdorff
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Marko Cupać 2017-02-24 09:15:57 UTC
Created attachment 180255 [details]
piwigo poudriere log

Hi,

I am trying to build piwigo in poudriere with default version of php changed to php70, but I get an error (poudriere log attached).

Regards,
Comment 1 Torsten Zuehlsdorff freebsd_committer freebsd_triage 2017-02-24 09:23:10 UTC
Created attachment 180256 [details]
Patch proposal for PHP 7 fix

Hello Marko,

after a short look at the Makefile, i noticed that there is a dependency to "mysql" AND "mysqli".
The "mysql" module was dropped in PHP 7 so therefore the build-error. Since "mysql" was already deprecated in PHP 5.6 and the user is advised to choose between "mysql" and "mysqli" i think its save to remove "mysql". 

I attached a patch. Please check if it builds now and if it still works with PHP 5.6

Greetings,
Torsten
Comment 2 Marko Cupać 2017-02-24 10:28:09 UTC
(In reply to Torsten Zuehlsdorff from comment #1)
Hi Torsten,

thank you for the tip, after removing 'mysql' from USE_PHP (ie. applying your patch), I have successfully built and installed piwigo.

Unfortunately I don't have php56 environment at the moment so I can't test whether this broke things for php56.

Best regards,
Comment 3 Ralf van der Enden 2017-02-27 13:12:47 UTC
Looks good.
Comment 4 commit-hook freebsd_committer freebsd_triage 2017-03-14 11:43:30 UTC
A commit references this bug:

Author: tz
Date: Tue Mar 14 11:43:01 UTC 2017
New revision: 436148
URL: https://svnweb.freebsd.org/changeset/ports/436148

Log:
  www/piwigo: Fix build error with php70

  This is done by removing the obsoleted mysql module from USE_PHP,
  especially since its replacement mysqli is already in it.

  PR:           217318
  Submitted by: tz
  Reported by:  Marko Cupa? <marko.cupac@mimar.rs>
  Reviewed by:  Marko Cupa? <marko.cupac@mimar.rs>
  Approved by:  Ralf van der Enden (maintainer)

Changes:
  head/www/piwigo/Makefile
Comment 5 Torsten Zuehlsdorff freebsd_committer freebsd_triage 2017-03-14 11:44:03 UTC
Committed, thanks! :)