Bug 268522 - www/yourls missing php modules
Summary: www/yourls missing php modules
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Po-Chuan Hsieh
URL:
Keywords: needs-patch
Depends on:
Blocks:
 
Reported: 2022-12-22 23:47 UTC by Jason Tubnor
Modified: 2023-02-05 16:14 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (sunpoet)


Attachments
Modified dependencies (339 bytes, patch)
2023-01-03 23:10 UTC, Jason Tubnor
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jason Tubnor 2022-12-22 23:47:31 UTC
The current packed yourls port requires the additional loading of the following php modules to operate correctly:

php81-iconv
php81-pdo_mysql

Below is a patch that could potentially fix the issue for users:

--- Makefile.orig       2022-12-23 10:38:06.682048000 +1100
+++ Makefile    2022-12-23 10:41:58.378126000 +1100
@@ -10,7 +10,9 @@ LICENSE=      MIT
 LICENSE_FILE=  ${WRKSRC}/LICENSE

 USES=          cpe php
-USE_PHP=       bcmath curl json mysqli pcre xml
+USE_PHP=       bcmath curl iconv json mysqli pcre pdo xml
+
+MYSQL_USE=     PHP=pdo_mysql

 NO_ARCH=       yes
 NO_BUILD=      yes
Comment 1 Graham Perrin freebsd_committer freebsd_triage 2022-12-24 03:36:45 UTC
Thanks, can you attach the patch as file?
Comment 2 Jason Tubnor 2023-01-03 23:08:35 UTC
The copy/paste still had an error in it. I have attached the patch file from the hosts that I built and ran the port from.

Yourls runs as expected and has all correct minimum dependencies.
Comment 3 Jason Tubnor 2023-01-03 23:10:21 UTC
Created attachment 239241 [details]
Modified dependencies

Attached patched Makefile enables yourls to run without pdo_mysql and iconv php errors.
Comment 4 commit-hook freebsd_committer freebsd_triage 2023-02-05 16:05:50 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=7d772f44a657b6fd380bbb46db7be084b7d26211

commit 7d772f44a657b6fd380bbb46db7be084b7d26211
Author:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
AuthorDate: 2023-02-05 15:29:59 +0000
Commit:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
CommitDate: 2023-02-05 15:50:16 +0000

    www/yourls: Fix PHP dependencies

    - Fix USE_PHP:
      - Add missing iconv
      - Replace mysqli with pdo_mysql
    - Bump PORTREVISION for dependency change

    PR:             268522
    Reported by:    Jason Tubnor <jason@tubnor.net>

 www/yourls/Makefile | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
Comment 5 Po-Chuan Hsieh freebsd_committer freebsd_triage 2023-02-05 16:14:37 UTC
Committed. Thanks!