diff --git a/www/phpvirtualbox-70/Makefile b/www/phpvirtualbox-70/Makefile index 22e8a6913dbe..b85b31ac272e 100644 --- a/www/phpvirtualbox-70/Makefile +++ b/www/phpvirtualbox-70/Makefile @@ -1,42 +1,43 @@ PORTNAME= phpvirtualbox DISTVERSION= 7.0 CATEGORIES= www MASTER_SITES= https://sourceforge.net/code-snapshots/git/p/ph/${PORTNAME}-7-0/code.git/ \ LOCAL/vvd SUFFIX= -70 PKGNAMESUFFIX= ${SUFFIX}${PHP_PKGNAMESUFFIX} DISTNAME= ${PORTNAME}-7-0-code-0737ff1c4106661672e69ef5ff26c3f494f4c65f MAINTAINER= vbox@FreeBSD.org COMMENT= AJAX Web Interface for VirtualBox WWW= https://sourceforge.net/projects/phpvirtualbox-7-0/ LICENSE= GPLv3 USES= php:flavors zip USE_PHP= session simplexml soap xml ETCDIR= ${WWWDIR} WWWDIR= ${PREFIX}/www/${PORTNAME}${SUFFIX} -EXTRA_PATCHES+= ${.CURDIR}/../phpvirtualbox/files/patch-panes_mediumEncryptionPasswords.html +EXTRA_PATCHES+= ${.CURDIR}/../phpvirtualbox-72/files/patch-endpoints_lib_vboxconnector.php \ + ${.CURDIR}/../phpvirtualbox-72/files/patch-panes_mediumEncryptionPasswords.html NO_ARCH= yes NO_BUILD= yes PORTSCOUT= limit:^7\.0\. WRKSRC_SUBDIR= ${PORTNAME}-${DISTVERSION} post-patch: @${MV} ${WRKSRC}/phpvirtualbox.conf ${WRKSRC}/phpvirtualbox${SUFFIX}.conf @${REINPLACE_CMD} -e 's#Alias /phpvirtualbox#Alias /phpvirtualbox${SUFFIX}#' \ -e 's#/usr/share/phpvirtualbox#${WWWDIR}#g' \ ${WRKSRC}/phpvirtualbox${SUFFIX}.conf @${REINPLACE_CMD} -e 's#\r#\n#g' ${WRKSRC}/languages/zh_tw.xml do-install: ${MKDIR} ${STAGEDIR}${WWWDIR} (cd ${WRKSRC}/ && ${COPYTREE_SHARE} "*" ${STAGEDIR}${WWWDIR} \ "-not -name *.orig -not -name config.php-example") ${INSTALL_DATA} ${WRKSRC}/config.php-example \ ${STAGEDIR}${WWWDIR}/config.php.sample .include diff --git a/www/phpvirtualbox-70/files/patch-endpoints_lib_vboxconnector.php b/www/phpvirtualbox-70/files/patch-endpoints_lib_vboxconnector.php deleted file mode 100644 index 3ce4bd1b67fa..000000000000 --- a/www/phpvirtualbox-70/files/patch-endpoints_lib_vboxconnector.php +++ /dev/null @@ -1,21 +0,0 @@ ---- endpoints/lib/vboxconnector.php.orig 2025-03-09 01:02:03 UTC -+++ endpoints/lib/vboxconnector.php -@@ -113,6 +113,8 @@ class vboxconnector { - */ - var $dsep = null; - -+ var $client = null; -+ - /** - * Obtain configuration settings and set object vars - * @param boolean $useAuthMaster use the authentication master obtained from configuration class -@@ -388,7 +390,8 @@ class vboxconnector { - - // The amount of time we will wait for events is determined by - // the amount of listeners - at least half a second -- $listenerWait = max(100,intval(500/count($this->persistentRequest['vboxEventListeners']))); -+ $listenerCount = count($this->persistentRequest['vboxEventListeners']); -+ $listenerWait = max(100,intval(500/($listenerCount > 0 ? $listenerCount : 1))); - } - - // Get events from each configured event listener diff --git a/www/phpvirtualbox-71/Makefile b/www/phpvirtualbox-71/Makefile index 085e05e3a3a9..9d48563e1730 100644 --- a/www/phpvirtualbox-71/Makefile +++ b/www/phpvirtualbox-71/Makefile @@ -1,39 +1,41 @@ PORTNAME= phpvirtualbox DISTVERSION= 7.1-1 PORTREVISION= 1 CATEGORIES= www SUFFIX= -71 PKGNAMESUFFIX= ${SUFFIX}${PHP_PKGNAMESUFFIX} MAINTAINER= vbox@FreeBSD.org COMMENT= AJAX Web Interface for VirtualBox WWW= https://github.com/phpvirtualbox/phpvirtualbox/ LICENSE= GPLv3 USES= php:flavors USE_GITHUB= yes USE_PHP= session simplexml soap xml ETCDIR= ${WWWDIR} WWWDIR= ${PREFIX}/www/${PORTNAME}${SUFFIX} -EXTRA_PATCHES+= ${.CURDIR}/../phpvirtualbox/files/patch-panes_mediumEncryptionPasswords.html +EXTRA_PATCHES+= ${.CURDIR}/../phpvirtualbox-72/files/patch-endpoints_lib_config.php \ + ${.CURDIR}/../phpvirtualbox-72/files/patch-endpoints_lib_vboxconnector.php \ + ${.CURDIR}/../phpvirtualbox-72/files/patch-panes_mediumEncryptionPasswords.html NO_ARCH= yes NO_BUILD= yes PORTSCOUT= limit:^7\.1\. post-patch: @${MV} ${WRKSRC}/phpvirtualbox.conf ${WRKSRC}/phpvirtualbox${SUFFIX}.conf @${REINPLACE_CMD} -e 's#Alias /phpvirtualbox#Alias /phpvirtualbox${SUFFIX}#' \ -e 's#/usr/share/phpvirtualbox#${WWWDIR}#g' \ ${WRKSRC}/phpvirtualbox${SUFFIX}.conf @${REINPLACE_CMD} -e 's#\r#\n#g' ${WRKSRC}/languages/zh_tw.xml do-install: ${MKDIR} ${STAGEDIR}${WWWDIR} (cd ${WRKSRC}/ && ${COPYTREE_SHARE} "*" ${STAGEDIR}${WWWDIR} \ "-not -name *.orig -not -name config.php-example") ${INSTALL_DATA} ${WRKSRC}/config.php-example \ ${STAGEDIR}${WWWDIR}/config.php.sample .include diff --git a/www/phpvirtualbox-71/files/patch-endpoints_lib_config.php b/www/phpvirtualbox-71/files/patch-endpoints_lib_config.php deleted file mode 100644 index 82de95a4947b..000000000000 --- a/www/phpvirtualbox-71/files/patch-endpoints_lib_config.php +++ /dev/null @@ -1,10 +0,0 @@ ---- endpoints/lib/config.php.orig 2025-04-26 04:11:44 UTC -+++ endpoints/lib/config.php -@@ -143,6 +143,7 @@ class phpVBoxConfigClass { - // added vars to satisfy PHP 8.2+ dynamic property deprecation - var $enableAdvancedConfig; - var $enableHDFlushConfig; -+ var $authMaster = false; - - /** - * Read user configuration, apply defaults, and do some sanity checking diff --git a/www/phpvirtualbox-71/files/patch-endpoints_lib_vboxconnector.php b/www/phpvirtualbox-71/files/patch-endpoints_lib_vboxconnector.php deleted file mode 100644 index 3ce4bd1b67fa..000000000000 --- a/www/phpvirtualbox-71/files/patch-endpoints_lib_vboxconnector.php +++ /dev/null @@ -1,21 +0,0 @@ ---- endpoints/lib/vboxconnector.php.orig 2025-03-09 01:02:03 UTC -+++ endpoints/lib/vboxconnector.php -@@ -113,6 +113,8 @@ class vboxconnector { - */ - var $dsep = null; - -+ var $client = null; -+ - /** - * Obtain configuration settings and set object vars - * @param boolean $useAuthMaster use the authentication master obtained from configuration class -@@ -388,7 +390,8 @@ class vboxconnector { - - // The amount of time we will wait for events is determined by - // the amount of listeners - at least half a second -- $listenerWait = max(100,intval(500/count($this->persistentRequest['vboxEventListeners']))); -+ $listenerCount = count($this->persistentRequest['vboxEventListeners']); -+ $listenerWait = max(100,intval(500/($listenerCount > 0 ? $listenerCount : 1))); - } - - // Get events from each configured event listener diff --git a/www/phpvirtualbox-legacy/Makefile b/www/phpvirtualbox-legacy/Makefile index 6294abb5cd5e..d1d886b7c58c 100644 --- a/www/phpvirtualbox-legacy/Makefile +++ b/www/phpvirtualbox-legacy/Makefile @@ -1,41 +1,40 @@ PORTNAME= phpvirtualbox DISTVERSION= 5.2-1 PORTREVISION= 7 CATEGORIES= www SUFFIX= -legacy PKGNAMESUFFIX= ${SUFFIX}${PHP_PKGNAMESUFFIX} MAINTAINER= vbox@FreeBSD.org COMMENT= AJAX Web Interface for VirtualBox WWW= https://sourceforge.net/projects/phpvirtualbox/ LICENSE= GPLv3 USES= dos2unix php:flavors DOS2UNIX_REGEX= .*\.(php|txt|js|css|html) USE_GITHUB= yes USE_PHP= session simplexml soap xml ETCDIR= ${WWWDIR} WWWDIR= ${PREFIX}/www/${PORTNAME}${SUFFIX} -EXTRA_PATCHES+= ${.CURDIR}/../phpvirtualbox/files/patch-php8 \ - ${.CURDIR}/../phpvirtualbox/files/patch-panes_mediumEncryptionPasswords.html +EXTRA_PATCHES+= ${.CURDIR}/../phpvirtualbox-72/files/patch-panes_mediumEncryptionPasswords.html NO_ARCH= yes NO_BUILD= yes PORTSCOUT= limit:^5\. post-patch: @${MV} ${WRKSRC}/phpvirtualbox.conf ${WRKSRC}/phpvirtualbox-legacy.conf @${REINPLACE_CMD} -e 's#Alias /phpvirtualbox#Alias /phpvirtualbox-legacy#' \ -e 's#/usr/share/phpvirtualbox#${WWWDIR}#g' \ ${WRKSRC}/phpvirtualbox-legacy.conf @${REINPLACE_CMD} -e 's#\r#\n#g' ${WRKSRC}/languages/zh_tw.xml do-install: ${MKDIR} ${STAGEDIR}${WWWDIR} (cd ${WRKSRC}/ && ${COPYTREE_SHARE} "*" ${STAGEDIR}${WWWDIR} \ "-not -name *.orig -not -name config.php-example") ${INSTALL_DATA} ${WRKSRC}/config.php-example \ ${STAGEDIR}${WWWDIR}/config.php.sample .include diff --git a/www/phpvirtualbox/files/patch-php8 b/www/phpvirtualbox-legacy/files/patch-php8 similarity index 100% rename from www/phpvirtualbox/files/patch-php8 rename to www/phpvirtualbox-legacy/files/patch-php8 diff --git a/www/phpvirtualbox/Makefile b/www/phpvirtualbox/Makefile index a30672cc413d..bcd01b010d36 100644 --- a/www/phpvirtualbox/Makefile +++ b/www/phpvirtualbox/Makefile @@ -1,36 +1,38 @@ PORTNAME= phpvirtualbox DISTVERSION= 6.1 PORTREVISION= 6 CATEGORIES= www PKGNAMESUFFIX= ${PHP_PKGNAMESUFFIX} MAINTAINER= vbox@FreeBSD.org COMMENT= AJAX Web Interface for VirtualBox WWW= https://sourceforge.net/projects/phpvirtualbox/ LICENSE= GPLv3 USES= dos2unix php:flavors DOS2UNIX_REGEX= .*\.(php|txt|js|css|html) USE_GITHUB= yes GH_TAGNAME= cf82d58f2 USE_PHP= session simplexml soap xml ETCDIR= ${WWWDIR} +EXTRA_PATCHES+= ${.CURDIR}/../phpvirtualbox-72/files/patch-panes_mediumEncryptionPasswords.html \ + ${.CURDIR}/../phpvirtualbox-legacy/files/patch-php8 NO_ARCH= yes NO_BUILD= yes PORTSCOUT= limit:^6\. post-patch: @${REINPLACE_CMD} -e 's#/usr/share/phpvirtualbox#${WWWDIR}#g' \ ${WRKSRC}/phpvirtualbox.conf @${REINPLACE_CMD} -e 's#\r#\n#g' ${WRKSRC}/languages/zh_tw.xml do-install: ${MKDIR} ${STAGEDIR}${WWWDIR} (cd ${WRKSRC}/ && ${COPYTREE_SHARE} "*" ${STAGEDIR}${WWWDIR} \ "-not -name *.orig -not -name config.php-example") ${INSTALL_DATA} ${WRKSRC}/config.php-example \ ${STAGEDIR}${WWWDIR}/config.php.sample .include diff --git a/www/phpvirtualbox/files/patch-panes_mediumEncryptionPasswords.html b/www/phpvirtualbox/files/patch-panes_mediumEncryptionPasswords.html deleted file mode 100644 index 3e8a7c62dfb7..000000000000 --- a/www/phpvirtualbox/files/patch-panes_mediumEncryptionPasswords.html +++ /dev/null @@ -1,34 +0,0 @@ ---- panes/mediumEncryptionPasswords.html.orig 2017-07-27 16:54:58 UTC -+++ panes/mediumEncryptionPasswords.html -@@ -15,6 +15,7 @@ - Status - ID - Password -+ Clear on suspend - - - -@@ -37,9 +38,12 @@ function vboxMediumEncryptionPasswordAdd - .append($('') - .append( - valid ? '*****' : -- $('').attr({'type':'password','style':'width:95%'}).addClass('vboxText') -+ $('').attr({'type':'password','style':'width:90%'}).addClass('vboxText') - ) - ) -+ .append($('') -+ .append($('').attr({'type':'checkbox', 'checked':'checked'})) -+ ) - .appendTo($('#vboxMediumEncryptionPasswordList')) - } - -@@ -55,7 +59,8 @@ function vboxMediumEncryptionPasswordsGe - continue; - encryptionPWs.push({ - 'id': $(rowlist[i]).data('vboxEncryptionId'), -- 'password': $(rowlist[i]).find('input').first().val() -+ 'password': $(rowlist[i]).find('input[type="password"]').first().val(), -+ 'clearOnSuspend': $(rowlist[i]).find('input[type="checkbox"]').first().is(':checked') ? '1' : '0' - }); - - }