Browse Source

Add PHP Composer to multiple frameworks

Hamilton Turner 11 years ago
parent
commit
a79d547828

+ 3 - 1
frameworks/PHP/php-phpixie/bash_profile.sh

@@ -4,4 +4,6 @@ export PHP_HOME=${IROOT}/php-5.4.13
 
 export PHP_FPM=$PHP_HOME/sbin/php-fpm
 
-export PATH="$PHP_HOME/bin:$PHP_HOME/sbin:$PATH"
+export COMPOSER_HOME=${IROOT}/php-composer
+
+export PATH="$COMPOSER_HOME:$PHP_HOME/bin:$PHP_HOME/sbin:$PATH"

+ 1 - 1
frameworks/PHP/php-phpixie/install.sh

@@ -1 +1 @@
-#!/bin/bash

fw_depends php nginx
+#!/bin/bash

fw_depends php composer nginx

+ 3 - 1
frameworks/PHP/php-pimf/bash_profile.sh

@@ -4,4 +4,6 @@ export PHP_HOME=${IROOT}/php-5.4.13
 
 export PHP_FPM=$PHP_HOME/sbin/php-fpm
 
-export PATH="$PHP_HOME/bin:$PHP_HOME/sbin:$PATH"
+export COMPOSER_HOME=${IROOT}/php-composer
+
+export PATH="$COMPOSER_HOME:$PHP_HOME/bin:$PHP_HOME/sbin:$PATH"

+ 1 - 1
frameworks/PHP/php-pimf/install.sh

@@ -1,3 +1,3 @@
 #!/bin/bash
 
-fw_depends php nginx
+fw_depends php composer nginx

+ 9 - 0
frameworks/PHP/php-silex-orm/bash_profile.sh

@@ -0,0 +1,9 @@
+#!/bin/bash
+
+export PHP_HOME=${IROOT}/php-5.4.13
+
+export PHP_FPM=$PHP_HOME/sbin/php-fpm
+
+export COMPOSER_HOME=${IROOT}/php-composer
+
+export PATH="$COMPOSER_HOME:$PHP_HOME/bin:$PHP_HOME/sbin:$PATH"

+ 1 - 1
frameworks/PHP/php-silex-orm/install.sh

@@ -1,3 +1,3 @@
 #!/bin/bash
 
-fw_depends php nginx
+fw_depends php composer nginx

+ 3 - 1
frameworks/PHP/php-silex/bash_profile.sh

@@ -4,4 +4,6 @@ export PHP_HOME=${IROOT}/php-5.4.13
 
 export PHP_FPM=$PHP_HOME/sbin/php-fpm
 
-export PATH="$PHP_HOME/bin:$PHP_HOME/sbin:$PATH"
+export COMPOSER_HOME=${IROOT}/php-composer
+
+export PATH="$COMPOSER_HOME:$PHP_HOME/bin:$PHP_HOME/sbin:$PATH"

+ 1 - 1
frameworks/PHP/php-silex/install.sh

@@ -1,3 +1,3 @@
 #!/bin/bash
 
-fw_depends php nginx
+fw_depends php composer nginx

+ 9 - 0
frameworks/PHP/php-silica/bash_profile.sh

@@ -0,0 +1,9 @@
+#!/bin/bash
+
+export PHP_HOME=${IROOT}/php-5.4.13
+
+export PHP_FPM=$PHP_HOME/sbin/php-fpm
+
+export COMPOSER_HOME=${IROOT}/php-composer
+
+export PATH="$COMPOSER_HOME:$PHP_HOME/bin:$PHP_HOME/sbin:$PATH"

+ 1 - 1
frameworks/PHP/php-silica/install.sh

@@ -1,3 +1,3 @@
 #!/bin/bash
 
-fw_depends php nginx
+fw_depends php composer nginx

+ 9 - 0
frameworks/PHP/php-symfony2-stripped/bash_profile.sh

@@ -0,0 +1,9 @@
+#!/bin/bash
+
+export PHP_HOME=${IROOT}/php-5.4.13
+
+export PHP_FPM=$PHP_HOME/sbin/php-fpm
+
+export COMPOSER_HOME=${IROOT}/php-composer
+
+export PATH="$COMPOSER_HOME:$PHP_HOME/bin:$PHP_HOME/sbin:$PATH"

+ 1 - 1
frameworks/PHP/php-symfony2-stripped/install.sh

@@ -1,3 +1,3 @@
 #!/bin/bash
 
-fw_depends php nginx
+fw_depends php composer nginx

+ 9 - 0
frameworks/PHP/php-symfony2/bash_profile.sh

@@ -0,0 +1,9 @@
+#!/bin/bash
+
+export PHP_HOME=${IROOT}/php-5.4.13
+
+export PHP_FPM=$PHP_HOME/sbin/php-fpm
+
+export COMPOSER_HOME=${IROOT}/php-composer
+
+export PATH="$COMPOSER_HOME:$PHP_HOME/bin:$PHP_HOME/sbin:$PATH"

+ 1 - 1
frameworks/PHP/php-symfony2/install.sh

@@ -1,3 +1,3 @@
 #!/bin/bash
 
-fw_depends php nginx
+fw_depends php composer nginx

+ 9 - 0
frameworks/PHP/php-zend-framework/bash_profile.sh

@@ -0,0 +1,9 @@
+#!/bin/bash
+
+export PHP_HOME=${IROOT}/php-5.4.13
+
+export PHP_FPM=$PHP_HOME/sbin/php-fpm
+
+export COMPOSER_HOME=${IROOT}/php-composer
+
+export PATH="$COMPOSER_HOME:$PHP_HOME/bin:$PHP_HOME/sbin:$PATH"

+ 1 - 1
frameworks/PHP/php-zend-framework/install.sh

@@ -1,3 +1,3 @@
 #!/bin/bash
 
-fw_depends php nginx
+fw_depends php composer nginx

+ 10 - 3
toolset/setup/linux/languages/composer.sh

@@ -1,9 +1,16 @@
 #!/bin/bash
 
-RETCODE=$(fw_exists bin/composer.phar)
+RETCODE=$(fw_exists php-composer.installed)
 [ ! "$RETCODE" == 0 ] || { return 0; }
 
 fw_depends php
 fw_get https://getcomposer.org/installer -O composer-installer.php
-mkdir -p bin
-php composer-installer.php --install-dir=bin
+
+mkdir -p php-composer
+
+# Use the PHP from our IROOT directory
+PHP_HOME=${IROOT}/php-5.4.13
+${PHP_HOME}/bin/php composer-installer.php --install-dir=$IROOT/php-composer
+
+touch php-composer.installed
+