% php artisan serve
dyld[2343]: Library not loaded: /opt/homebrew/opt/icu4c/lib/libicuio.71.dylib
Referenced from: <1574B3CC-A9C9-3EAD-9D0E-9862223FF7BA> /opt/homebrew/Cellar/php#7.4/7.4.30_1/bin/php
Reason: tried: '/opt/homebrew/opt/icu4c/lib/libicuio.71.dylib' (no such file), '/System/Volumes/Preboot/Cryptexes/OS/opt/homebrew/opt/icu4c/lib/libicuio.71.dylib' (no such file), '/opt/homebrew/opt/icu4c/lib/libicuio.71.dylib' (no such file), '/usr/local/lib/libicuio.71.dylib' (no such file), '/usr/lib/libicuio.71.dylib' (no such file, not in dyld cache), '/opt/homebrew/Cellar/icu4c/72.1/lib/libicuio.71.dylib' (no such file), '/System/Volumes/Preboot/Cryptexes/OS/opt/homebrew/Cellar/icu4c/72.1/lib/libicuio.71.dylib' (no such file), '/opt/homebrew/Cellar/icu4c/72.1/lib/libicuio.71.dylib' (no such file), '/usr/local/lib/libicuio.71.dylib' (no such file), '/usr/lib/libicuio.71.dylib' (no such file, not in dyld cache)
zsh: abort php artisan serve
How do I fix it ?
help me
This is most likely because you changed the PHP versions, try to do the following:
brew cleanup
to fix any ongoing issues with brew if that fails
brew upgrade
to update/upgrade everything, then run again cleanup
Related
(wamp on Windows)
I've composer.phar and composer.bat in c:\bin (Path variable is OK)
letting composer command from cmd window I get: "php is not an internal or external command"
after setting the PHP directory in the PATH, PHP server will have complained: it will work improperly by reason of PATH variable.
How can I reach #php command from anywhere without setting PHP directory in the PATH
(I've the save problem width PHPUnit installing)
Thx a lot
I am using OSX running on El Capitan and setting up PhpStorm and the Laravel environment has been a nightmare. I created a project setting up Composer and created it with laravel/laravel from the options menu.
As you can see in the screen shot, the PHP version says 5.6.31.. but if I type php -v in the command line. It gives me php 5.5 (as shown in the bottom left)
If I type php -v in the terminal I also get php 5.6.
which php returns me /usr/local/bin/php
I originally had a problem where PHP would not upgrade to 5.6.. but I managed to solve this with homebrew.
And if I use terminal and cd into the folder to run artisan key:generate and config:clear .. I am able to get the Laravel homepage to load (but typing this from the PhpStorm command line does not work).
My understanding is that the command line is pointing to the directory of PHP that came with my Mac? So how do I point it to the upgraded version? Or is the problem something else?
I think this is a strange problem and already a few people I have asked have not been able to solve it (also setting this up is all very new to me).
what I did is to set an alias on my ~/.bashrc to point php command to point to /Applications/XAMPP/bin/php
e.g. alias php="/Applications/XAMPP/bin/php"
in your case, you can use your XAMPP's full path to your php binary file as you might have different installation paths.
You should be able to add:
export PATH=/Applications/XAMPP/xamppfiles/bin/php5.6.31:$PATH
to your ~/.bash_profile (assuming you're running a bash shell). Then just run source ~/.bash_profile and it should all work.
I installed Git version 2.6.2.windows.1. After installing, any other programs in my PATH environment variable will display a flash console whenever I check their versions.
For example, from current pointer, I run "node -v" or "php --version" (both node & php are in PATH), the result which I got is a new console just flashes.
I think the content of any commands above are displayed in that console.
And in main console which I run command to check just like below:
This thing causes so many problems for me .
I tried to setup debug on my ide - phpstorm. But it seems not to recognize php version. Because the result is displayed in a new console and that console will be disappeared most immediately.
So could anybody help me fix this?
First, forget cygwin.
Then (for a Windows 64 bits), uncompress or install in path without spaces and in lowercase (so not the default C:\Program Files\..., but rather C:\prgs\git or C:\prgs\php for instance):
php-7.0.1-Win32-VC14-x64.zip
PortableGit-2.6.4-64-bit.7z.exe
node-v4.2.3-x64.msi (it is an installer, see "How to Install Node.jsĀ® and NPM on Windows", but use a simpler path like C:\prgs\node)
phpstorm (you already have it in your case)
In a brand new CMD session, type:
set PATH=C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Windows\system32
set PATH=%PATH%;c:\prgs\php\bin
set PATH=%PATH%;c:\prgs\git\nodejs
cd c:\path\to\phpstorm
PhpStorm.exe
In that new PhpStorm editor, configure the path of php, and see if the issue persists.
Each time I try to run tests with PHPStorm I get this error:
/usr/bin/php /private/var/folders/jl/34t9y2h94jsgchv4wfcxl6g80000gn/T/ide-phpunit.php -c app --configuration /Users/simonegentili/Sviluppo/web/wishventures/SendA/app/phpunit.xml.dist WishVentures\GeeftyApiBundle\Test\Controller\ApiControllerTest /Users/simonegentili/Sviluppo/web/wishventures/SendA/src/WishVentures/GeeftyApiBundle/Tests/Controller/ApiControllerTest.php
Testing started at 18:46 ...
dyld: Library not loaded: /usr/local/lib/libpng15.15.dylib
Referenced from: /usr/bin/php
Reason: image not found
Process finished with exit code 133
I've found this question but
$ brew update && brew upgrade
$ brew reinstall php55
did not solve my troubles. Well, ... PHPStorm is looking for libpng15.15.dylib, but I've libpng16.16.dylib. I think is a broken link issue. How to solve it?
The reason was that I had two version of php installed on my computer. One reached via /usr/bin/php and another from /usr/local/bin/php. The first one was a link to php version 5.5.8 and the second one was 5.5.14
I sow that dyld (dynamic linker of Operating System) was looking for /usr/local/lib/libpng15.15.dylib (maybe called by php 5.5.8) but inside my /usr/local/lib/ there was not. In that folder, I got libpng16.16.dylib (I think ... because I've installed php55 via brew and this version oh php needs new version of libpng).
I undestood that my /usr/bin/php was a pointer to php 5.5.8. Instead, ... /usr/local/bin/php was 5.5.14. PHPStorm worked with /usr/bin/php that is default configuration. When I run php via console, I run /urs/local/bin/php.
is there a way to change the default version of PHP that is called on the command line?
I am trying to install Laravel using composer the problem is composer is calling php (which is version 4.4) when it needs to call php5.4, i have changed the binary in the header from #!/usr/bin/env php to #!/usr/bin/env php5.4 but this throws an error!
here is my php set-up
php: /usr/bin/php /usr/bin/php5.4 /usr/bin/php5.5 /usr/lib/php /usr/lib/php.ini-nourl /usr/lib/php.ini /usr/lib/php5.4 /usr/lib/php5.5 /usr/local/bin/php /usr/local/bin/php5.4 /usr/local/bin/php5.5 /usr/local/lib/php.ini-nourl /usr/include/php /usr/include/php5.4 /usr/include/php5.5 /usr/local/php /usr/share/php
There are a couple options here, but really this is not php specific, this is about basic execution path rules.
The #!/usr/bin/env php header means that when you run composer alone it runs it with php, so if you manually run it like php5.4 /path/to/composer you can bypass that header.
The other option is to define a symlink in /usr/local/bin/php or something that:
points to /usr/bin/php5.4
is in a directory that has precedence over /usr/bin inside your PATH environment variable.