diff options
-rwxr-xr-x | mkmodular | 23 |
1 files changed, 13 insertions, 10 deletions
@@ -206,9 +206,12 @@ function findPackages($from, $dest, $pat) { return $rpms; } -function genModule($srce, $dest, $pat, $ver, $arch, $deps, $template) { +function genModule($srce, $dest, $pats, $ver, $arch, $deps, $template) { - $rpms = findPackages($srce, $dest, $pat); + $rpms = []; + foreach ((array)$pats as $pat) { + $rpms += findPackages($srce, $dest, $pat); + } $deptxt = ''; foreach($deps as $n => $v) { $deptxt .= ($deptxt ? "\n" : '') . " $n: [$v]"; @@ -255,7 +258,7 @@ if (count($_SERVER['argv']) < 2 || in_array('f29', $_SERVER['argv'])) { echo "Populate $dest\n"; cleanup($dest); $deps = ['platform' => 'f29']; - $mod = genModule('fedora/29/remi/x86_64', $dest, 'php-*7.2*.rpm', '7.2', 'x86_64', $deps, $template_php); + $mod = genModule('fedora/29/remi/x86_64', $dest, ['unit-php*rpm', 'php-*7.2*.rpm'], '7.2', 'x86_64', $deps, $template_php); $mod .= genModule('fedora/29/php73/x86_64', $dest, '*.rpm', '7.3', 'x86_64', $deps, $template_php); $mod .= genModule('fedora/29/glpi92/x86_64', $dest, '*.rpm', '9.2', 'x86_64', $deps, $template_glpi); $mod .= genModule('fedora/29/glpi93/x86_64', $dest, '*.rpm', '9.3', 'x86_64', $deps, $template_glpi); @@ -267,7 +270,7 @@ if (count($_SERVER['argv']) < 2 || in_array('f29', $_SERVER['argv'])) { echo "Populate $dest\n"; cleanup($dest); $deps = ['platform' => 'f29']; - $mod = genModule('fedora/29/test/x86_64', $dest, 'php-*7.2*.rpm', '7.2', 'x86_64', $deps, $template_php); + $mod = genModule('fedora/29/test/x86_64', $dest, ['unit-php*rpm', 'php-*7.2*.rpm'], '7.2', 'x86_64', $deps, $template_php); $mod .= genModule('fedora/29/test73/x86_64', $dest, '*.rpm', '7.3', 'x86_64', $deps, $template_php); $mod .= $defaults; createRepo($dest, $mod); @@ -276,7 +279,7 @@ if (count($_SERVER['argv']) < 2 || in_array('f29', $_SERVER['argv'])) { echo "Populate $dest\n"; cleanup($dest); $deps = ['platform' => 'f29']; - $mod = genModule('fedora/29/remi/i386', $dest, 'php-*7.2*.rpm', '7.2', 'i386', $deps, $template_php); + $mod = genModule('fedora/29/remi/i386', $dest, ['unit-php*rpm', 'php-*7.2*.rpm'], '7.2', 'i386', $deps, $template_php); $mod .= genModule('fedora/29/php73/i386', $dest, '*.rpm', '7.3', 'i386', $deps, $template_php); $mod .= genModule('fedora/29/glpi92/i386', $dest, '*.rpm', '9.2', 'i386', $deps, $template_glpi); $mod .= genModule('fedora/29/glpi93/i386', $dest, '*.rpm', '9.3', 'i386', $deps, $template_glpi); @@ -288,7 +291,7 @@ if (count($_SERVER['argv']) < 2 || in_array('f29', $_SERVER['argv'])) { echo "Populate $dest\n"; cleanup($dest); $deps = ['platform' => 'f29']; - $mod = genModule('fedora/29/test/i386', $dest, 'php-*7.2*.rpm', '7.2', 'i386', $deps, $template_php); + $mod = genModule('fedora/29/test/i386', $dest, ['unit-php*rpm', 'php-*7.2*.rpm'], '7.2', 'i386', $deps, $template_php); $mod .= genModule('fedora/29/test73/i386', $dest, '*.rpm', '7.3', 'i386', $deps, $template_php); $mod .= $defaults; createRepo($dest, $mod); @@ -299,7 +302,7 @@ if (count($_SERVER['argv']) < 2 || in_array('f30', $_SERVER['argv'])) { echo "Populate $dest\n"; cleanup($dest); $deps = ['platform' => 'f30']; - $mod = genModule('fedora/30/remi/x86_64', $dest, 'php-*7.3*.rpm', '7.3', 'x86_64', $deps, $template_php); + $mod = genModule('fedora/30/remi/x86_64', $dest, ['unit-php*rpm', 'php-*7.3*.rpm'], '7.3', 'x86_64', $deps, $template_php); $mod .= genModule('fedora/30/glpi93/x86_64', $dest, '*.rpm', '9.3', 'x86_64', $deps, $template_glpi); $mod .= genModule('fedora/30/glpi94/x86_64', $dest, '*.rpm', '9.4', 'x86_64', $deps, $template_glpi); $mod .= $defaults; @@ -309,7 +312,7 @@ if (count($_SERVER['argv']) < 2 || in_array('f30', $_SERVER['argv'])) { echo "Populate $dest\n"; cleanup($dest); $deps = ['platform' => 'f30']; - $mod = genModule('fedora/30/test/x86_64', $dest, 'php-*7.3*.rpm', '7.3', 'x86_64', $deps, $template_php); + $mod = genModule('fedora/30/test/x86_64', $dest, ['unit-php*rpm', 'php-*7.3*.rpm'], '7.3', 'x86_64', $deps, $template_php); $mod .= $defaults; createRepo($dest, $mod); @@ -317,7 +320,7 @@ if (count($_SERVER['argv']) < 2 || in_array('f30', $_SERVER['argv'])) { echo "Populate $dest\n"; cleanup($dest); $deps = ['platform' => 'f30']; - $mod = genModule('fedora/30/remi/i386', $dest, 'php-*7.3*.rpm', '7.3', 'i386', $deps, $template_php); + $mod = genModule('fedora/30/remi/i386', $dest, ['unit-php*rpm', 'php-*7.3*.rpm'], '7.3', 'i386', $deps, $template_php); $mod .= genModule('fedora/30/glpi93/i386', $dest, '*.rpm', '9.3', 'i386', $deps, $template_glpi); $mod .= genModule('fedora/30/glpi94/i386', $dest, '*.rpm', '9.4', 'i386', $deps, $template_glpi); $mod .= $defaults; @@ -327,7 +330,7 @@ if (count($_SERVER['argv']) < 2 || in_array('f30', $_SERVER['argv'])) { echo "Populate $dest\n"; cleanup($dest); $deps = ['platform' => 'f30']; - $mod = genModule('fedora/30/test/i386', $dest, 'php-*7.3*.rpm', '7.3', 'i386', $deps, $template_php); + $mod = genModule('fedora/30/test/i386', $dest, ['unit-php*rpm', 'php-*7.3*.rpm'], '7.3', 'i386', $deps, $template_php); $mod .= $defaults; createRepo($dest, $mod); } |