summaryrefslogtreecommitdiffstats
path: root/pts-core/functions/pts-functions-install_dependencies.php
diff options
context:
space:
mode:
Diffstat (limited to 'pts-core/functions/pts-functions-install_dependencies.php')
-rw-r--r--pts-core/functions/pts-functions-install_dependencies.php31
1 files changed, 14 insertions, 17 deletions
diff --git a/pts-core/functions/pts-functions-install_dependencies.php b/pts-core/functions/pts-functions-install_dependencies.php
index d33b7f3..d410322 100644
--- a/pts-core/functions/pts-functions-install_dependencies.php
+++ b/pts-core/functions/pts-functions-install_dependencies.php
@@ -21,6 +21,19 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
+function pts_install_package_on_distribution($identifier)
+{
+ // PTS External Dependencies install on distribution
+ if(getenv("SILENT_INSTALL") == false)
+ {
+ echo "Checking For Needed External Dependencies.\n";
+ }
+
+ $identifier = strtolower($identifier);
+ $install_objects = array();
+ pts_start_install_dependencies($identifier, $install_objects);
+ pts_install_packages_on_distribution_process($install_objects);
+}
function pts_start_install_dependencies($TO_INSTALL, &$PLACE_LIST)
{
if(IS_SCTP_MODE)
@@ -95,10 +108,7 @@ function pts_install_external_dependencies_list($identifier, &$INSTALL_OBJ)
{
$dependencies = explode(",", $dependencies);
- for($i = 0; $i < count($dependencies); $i++)
- {
- $dependencies[$i] = trim($dependencies[$i]);
- }
+ $dependencies = array_map("trim", $dependencies);
if(!defined("PTS_EXDEP_FIRST_RUN"))
{
@@ -168,19 +178,6 @@ function pts_package_generic_to_distro_name(&$package_install_array, $generic_na
return $generated;
}
-function pts_install_package_on_distribution($identifier)
-{
- // PTS External Dependencies install on distribution
- if(getenv("SILENT_INSTALL") == false)
- {
- echo "Checking For Needed External Dependencies.\n";
- }
-
- $identifier = strtolower($identifier);
- $install_objects = array();
- pts_start_install_dependencies($identifier, $install_objects);
- pts_install_packages_on_distribution_process($install_objects);
-}
function pts_install_packages_on_distribution_process($install_objects)
{
// Do the actual installing process of packages using the distribution's package management system