PHP-GD enable support for PNG
Title says it all, how can one enable support for PNG? I don't want to use brew I don't want recompile whole PHP because of this mistake by Apple.
MacBook Pro (Retina, 15-inch, Mid 2014), OS X Yosemite (10.10)
Title says it all, how can one enable support for PNG? I don't want to use brew I don't want recompile whole PHP because of this mistake by Apple.
MacBook Pro (Retina, 15-inch, Mid 2014), OS X Yosemite (10.10)
Relying on apple to maintain your apache, php, and mysql installation is just plain silly. It only gets updated with major OS releases....
You are obviously a developer, part of being a developer is knowing how to maintain, and update your development environment....if you want php extensions that are not included with base OSX, the only way to get them is to download, compile and enable them in your php.ini.
Homebrew is ridiculously easy to use, and once setup it automatically will update your MAMP forever...
time to put on your grownup pants and learn the terminal....
FYI
I use macports, but homebrew is honestly even easier.
In the beginning you upamyanuli of MySql
I have already installed MySql end phpMyAdmin
Tell me, these operations do not harm the already configured server? I now tested on a virtual machine.
Here's a test server with a hosting provider
Such a result can not be achieved?
Your blog is not available in my country 😟
Ukraine.
No.
Reinstall new packages, JPEG Support / No
Please fix that worked too
Hi Michael,
Thanks for the putting all of these together!
I tried running the steps in the script. Got a couple of warnings with the configure command while in folder php-5.5.14:
checking for bison version... invalid
configure: WARNING: bison versions supported for regeneration of the Zend/PHP parsers: 2.4 2.4.1 2.4.2 2.4.3 2.5 2.5.1 2.6 2.6.1 2.6.2 2.6.3 2.6.4 2.6.5 2.7 (found: 2.3)
checking for re2c... no
configure: WARNING: You will need re2c 0.13.4 or later if you want to regenerate PHP parsers.
Then, it ended with this error:
configure: error: Cannot find OpenSSL's <evp.h>
Any idea how to fix this?
Thanks,
Luke
Isn't the clue in the error messages?
configure: WARNING: bison versions supported for regeneration of the Zend/PHP parsers: 2.4 2.4.1 2.4.2 2.4.3 2.5 2.5.1 2.6 2.6.1 2.6.2 2.6.3 2.6.4 2.6.5 2.7 (found: 2.3)
It wants a version of bison above what you have installed (or what was used here, you may have others on the system).
bison -V
…will show the version for the one in your path, perhaps macports has another installed?
Can you check for other versions?
locate bison
The final error looks like it is unable to find the openssl headers.
Is your PATH setup for use with macports?
Hi Drew,
You misread my comment / question. I am not using MacPorts (and do not want to use MacPorts and or Homebrew). I am following Michael Bagnall's steps.
Luke
lappsupcoml wrote:
Hi Drew,
You misread my comment / question. I am not using MacPorts (and do not want to use MacPorts and or Homebrew). I am following Michael Bagnall's steps.
Luke
Fair enough, it still appears you need an upgraded bison to use these features unless you don't need them. That is a warning not an error, so it should't be stopping the process.
The lack of openssl headers is an error. You probably need to work out how to install them.
Thank you Mike - your guide helped me and several employees - and thank you for your personal follow-up with email, I am sincerely grateful.
I only have two comments to add:
1. Make sure you have the Command Line Developer Tools for OS X 10.10 - several of the "tests" on my command line came back positive for the individual commands, but the necessary dependencies for the recompile were not present and resulted in failures. Once I installed the Command Line Developer Tools the recompile worked flawlessly.
2. If you find yourself having to recompile after going through once, you'll need to edit the /etc/php.ini file to remove the duplicated "extension=" entries at the bottom (keeping one set of the three entries).
Thanks this fixed my png problem perfectly
I went for a real simple solution:
My php code was:
imagepng($im);
Replaced with:
imagejpeg($im);
The images wasn't so good, but useable. And took 1 minute for my needs to update. Just a suggestion, if in my case, just one file I am relying on with this function.
\rf
PHP-GD enable support for PNG