how to install php composer?

Ryan Schmidt ryandesign at macports.org
Tue Dec 19 14:14:36 UTC 2017


> On Dec 16, 2017, at 11:45, macports at parvis.nl wrote:
> 
> 
> without macports, it should be something like this:
> 
> curl -sS https://getcomposer.org/installer | php
> sudo mv composer.phar /usr/local/bin/composer
> 
> but i am afraid that this way interfers with macports.
> 
> -----
> 
> then i found the following:  https://github.com/sjorek/MacPorts-PHP
> 
> it looks it works like a local port installation.
> 
> as this isnt a formal port i think i cannot create a ticket.
> 
> this is what happens:
> 
> # port install composer composer-php56 composer-select +iconv +openssl
> --->  Cleaning composer
> --->  Computing dependencies for composer-php56
> --->  Building composer-php56
> Error: Failed to build composer-php56:
> Warning: PHP Startup: Unable to load dynamic library '/opt/local/lib/php56/extensions/no-debug-non-zts-20131226/gd.so' - dlopen(/opt/local/lib/php56/extensions/no-debug-non-zts-20131226/gd.so, 9): image not found in Unknown on line 0
> 
> Warning: PHP Startup: Unable to load dynamic library '/opt/local/lib/php56/extensions/no-debug-non-zts-20131226/gdchart.so' - dlopen(/opt/local/lib/php56/extensions/no-debug-non-zts-20131226/gdchart.so, 9): image not found in Unknown on line 0
> All settings correct for using Composer
> PHP Warning:  PHP Startup: Unable to load dynamic library '/opt/local/lib/php56/extensions/no-debug-non-zts-20131226/gd.so' - dlopen(/opt/local/lib/php56/extensions/no-debug-non-zts-20131226/gd.so, 9): image not found in Unknown on line 0
> PHP Warning:  PHP Startup: Unable to load dynamic library '/opt/local/lib/php56/extensions/no-debug-non-zts-20131226/gdchart.so' - dlopen(/opt/local/lib/php56/extensions/no-debug-non-zts-20131226/gdchart.so, 9): image not found in Unknown on line 0
> Error: See /opt/local/var/macports/logs/_Users_paul_Develop_macports_MacPorts-PHP_php_composer/composer-php56/main.log for details.
> Error: Follow https://guide.macports.org/#project.tickets to report a bug.
> Error: Processing of port composer-php56 failed
> 
> so it probably isnt the right way too.
> 
> -----
> 
> could anybody please tell me the right way to install/use php composer with macports ?

The simple answer is: PHP composer is not in MacPorts. If you want it in MacPorts, file a ticket in our issue tracker.

Since someone has already created a separate ports repository on GitHub, you might ask them why they did that, and if they would consider instead submitting their ports to our official ports collection.





More information about the macports-dev mailing list