This repository has been archived by the owner. It is now read-only.

Yosemite DP - configure: error: Cannot find OpenSSL's <evp.h> #1181

Closed
OKNoah opened this Issue Jun 5, 2014 · 64 comments

Comments

Projects
None yet
@OKNoah

OKNoah commented Jun 5, 2014

I get this in Yosemite DP

==> Installing dependencies for php54-intl: php54, icu4c
==> Installing php54-intl dependency: php54
==> Downloading http://www.php.net/get/php-5.4.29.tar.bz2/from/this/mirror
######################################################################## 100.0%
==> ./configure --prefix=/usr/local/Cellar/php54/5.4.29 --localstatedir=/usr/local/var --sysconfdir=/usr/local/etc/php/5.4 --with-config-file-path=/usr/local/etc/php/5.4 --with-config-file-scan-dir=/usr/l
checking for krb5-config... /usr/bin/krb5-config
checking for DSA_get_default_method in -lssl... no
checking for X509_free in -lcrypto... yes
checking for pkg-config... no
configure: error: Cannot find OpenSSL's <evp.h>

READ THIS: https://github.com/Homebrew/homebrew/wiki/troubleshooting
If reporting this issue please do so at (not Homebrew/homebrew):
  https://github.com/josegonzalez/homebrew-php/issues

/usr/local/Library/Homebrew/utils.rb:313:in `rescue in open': uninitialized constant GitHub::OpenSSL (NameError)
    from /usr/local/Library/Homebrew/utils.rb:298:in `open'
    from /usr/local/Library/Homebrew/utils.rb:339:in `issues_matching'
    from /usr/local/Library/Homebrew/utils.rb:367:in `issues_for_formula'
    from /usr/local/Library/Homebrew/exceptions.rb:171:in `fetch_issues'
    from /usr/local/Library/Homebrew/exceptions.rb:167:in `issues'
    from /usr/local/Library/Homebrew/exceptions.rb:208:in `dump'
    from /usr/local/Library/brew.rb:133:in `rescue in <main>'
    from /usr/local/Library/brew.rb:72:in `<main>'
@arsonik

This comment has been minimized.

Show comment
Hide comment
@arsonik

arsonik Jun 7, 2014

Same issue here

brew install php55 php55-mcrypt
==> Downloading http://www.php.net/get/php-5.5.13.tar.bz2/from/this/mirror
Already downloaded: /Library/Caches/Homebrew/php55-5.5.13
==> ./configure --prefix=/usr/local/Cellar/php55/5.5.13 --localstatedir=/usr/local/var --sysconfdir=/usr/local/etc/php/5.5 --with-config-file-path=/usr/local/etc/php/5.5 --with-config-file-scan-dir=/usr/local/etc/php/5
checking for krb5-config... /usr/bin/krb5-config
checking for DSA_get_default_method in -lssl... no
checking for X509_free in -lcrypto... yes
checking for pkg-config... no
configure: error: Cannot find OpenSSL's <evp.h>
Error: Homebrew doesn't know what compiler versions ship with your version
of Xcode (6.0). Please `brew update` and if that doesn't help, file
an issue with the output of `brew --config`:
  https://github.com/Homebrew/homebrew/issues

Note that we only track stable, released versions of Xcode.

Thanks!

READ THIS: https://github.com/Homebrew/homebrew/wiki/troubleshooting
If reporting this issue please do so at (not Homebrew/homebrew):
  https://github.com/homebrew/homebrew-php/issues

/usr/local/Library/Homebrew/utils.rb:315:in `rescue in open': uninitialized constant GitHub::OpenSSL (NameError)
    from /usr/local/Library/Homebrew/utils.rb:300:in `open'
    from /usr/local/Library/Homebrew/utils.rb:341:in `issues_matching'
    from /usr/local/Library/Homebrew/utils.rb:369:in `issues_for_formula'
    from /usr/local/Library/Homebrew/exceptions.rb:171:in `fetch_issues'
    from /usr/local/Library/Homebrew/exceptions.rb:167:in `issues'
    from /usr/local/Library/Homebrew/exceptions.rb:208:in `dump'
    from /usr/local/Library/brew.rb:133:in `rescue in <main>'
    from /usr/local/Library/brew.rb:72:in `<main>'
brew --config
HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/Homebrew/homebrew
HEAD: 58f191e92525fe184db40881161aee93cdff1731
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: 8-core 64-bit ivybridge
OS X: 10.10-x86_64
Xcode: 6.0 => /Applications/Xcode6-Beta.app/Contents/Developer
Clang: 6.0 build 600
X11: N/A
System Ruby: 2.0.0-451
Perl: /usr/bin/perl
Python: /usr/bin/python
Ruby: /usr/bin/ruby

arsonik commented Jun 7, 2014

Same issue here

brew install php55 php55-mcrypt
==> Downloading http://www.php.net/get/php-5.5.13.tar.bz2/from/this/mirror
Already downloaded: /Library/Caches/Homebrew/php55-5.5.13
==> ./configure --prefix=/usr/local/Cellar/php55/5.5.13 --localstatedir=/usr/local/var --sysconfdir=/usr/local/etc/php/5.5 --with-config-file-path=/usr/local/etc/php/5.5 --with-config-file-scan-dir=/usr/local/etc/php/5
checking for krb5-config... /usr/bin/krb5-config
checking for DSA_get_default_method in -lssl... no
checking for X509_free in -lcrypto... yes
checking for pkg-config... no
configure: error: Cannot find OpenSSL's <evp.h>
Error: Homebrew doesn't know what compiler versions ship with your version
of Xcode (6.0). Please `brew update` and if that doesn't help, file
an issue with the output of `brew --config`:
  https://github.com/Homebrew/homebrew/issues

Note that we only track stable, released versions of Xcode.

Thanks!

READ THIS: https://github.com/Homebrew/homebrew/wiki/troubleshooting
If reporting this issue please do so at (not Homebrew/homebrew):
  https://github.com/homebrew/homebrew-php/issues

/usr/local/Library/Homebrew/utils.rb:315:in `rescue in open': uninitialized constant GitHub::OpenSSL (NameError)
    from /usr/local/Library/Homebrew/utils.rb:300:in `open'
    from /usr/local/Library/Homebrew/utils.rb:341:in `issues_matching'
    from /usr/local/Library/Homebrew/utils.rb:369:in `issues_for_formula'
    from /usr/local/Library/Homebrew/exceptions.rb:171:in `fetch_issues'
    from /usr/local/Library/Homebrew/exceptions.rb:167:in `issues'
    from /usr/local/Library/Homebrew/exceptions.rb:208:in `dump'
    from /usr/local/Library/brew.rb:133:in `rescue in <main>'
    from /usr/local/Library/brew.rb:72:in `<main>'
brew --config
HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/Homebrew/homebrew
HEAD: 58f191e92525fe184db40881161aee93cdff1731
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: 8-core 64-bit ivybridge
OS X: 10.10-x86_64
Xcode: 6.0 => /Applications/Xcode6-Beta.app/Contents/Developer
Clang: 6.0 build 600
X11: N/A
System Ruby: 2.0.0-451
Perl: /usr/bin/perl
Python: /usr/bin/python
Ruby: /usr/bin/ruby
@jameslittle230

This comment has been minimized.

Show comment
Hide comment
@jameslittle230

jameslittle230 Jun 8, 2014

Yup.

brew install PHP55
==> Downloading http://www.php.net/get/php-5.5.13.tar.bz2/from/this/mirror
Already downloaded: /Library/Caches/Homebrew/php55-5.5.13
==> ./configure --prefix=/usr/local/Cellar/php55/5.5.13 --localstatedir=/usr/local/var --sysconfdir=/usr/local/etc/php/5.5 --with-config-file-path=/usr/local/etc/php/5.5 --with-config-file-scan-dir=/usr/local/etc/php/5.5/conf.d --with-iconv-dir=/usr --enable-dba --with-
checking for krb5-config... /usr/bin/krb5-config
checking for DSA_get_default_method in -lssl... no
checking for X509_free in -lcrypto... yes
checking for pkg-config... no
configure: error: Cannot find OpenSSL's <evp.h>
Error: Homebrew doesn't know what compiler versions ship with your version
of Xcode (6.0). Please `brew update` and if that doesn't help, file
an issue with the output of `brew --config`:
  https://github.com/Homebrew/homebrew/issues

Note that we only track stable, released versions of Xcode.

Thanks!

READ THIS: https://github.com/Homebrew/homebrew/wiki/troubleshooting
If reporting this issue please do so at (not Homebrew/homebrew):
  https://github.com/homebrew/homebrew-php/issues

/usr/local/Library/Homebrew/utils.rb:315:in `rescue in open': uninitialized constant GitHub::OpenSSL (NameError)
    from /usr/local/Library/Homebrew/utils.rb:300:in `open'
    from /usr/local/Library/Homebrew/utils.rb:341:in `issues_matching'
    from /usr/local/Library/Homebrew/utils.rb:369:in `issues_for_formula'
    from /usr/local/Library/Homebrew/exceptions.rb:171:in `fetch_issues'
    from /usr/local/Library/Homebrew/exceptions.rb:167:in `issues'
    from /usr/local/Library/Homebrew/exceptions.rb:208:in `dump'
    from /usr/local/Library/brew.rb:133:in `rescue in <main>'
    from /usr/local/Library/brew.rb:72:in `<main>'

and

brew --config
HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/Homebrew/homebrew.git
HEAD: 0ad9174676adbfccaca3130f17d31a2c72dd6f44
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: 8-core 64-bit ivybridge
OS X: 10.10-x86_64
Xcode: 6.0
Clang: 6.0 build 600
X11: N/A
System Ruby: 2.0.0-451
Perl: /usr/bin/perl
Python: /usr/bin/python
Ruby: /usr/bin/ruby

jameslittle230 commented Jun 8, 2014

Yup.

brew install PHP55
==> Downloading http://www.php.net/get/php-5.5.13.tar.bz2/from/this/mirror
Already downloaded: /Library/Caches/Homebrew/php55-5.5.13
==> ./configure --prefix=/usr/local/Cellar/php55/5.5.13 --localstatedir=/usr/local/var --sysconfdir=/usr/local/etc/php/5.5 --with-config-file-path=/usr/local/etc/php/5.5 --with-config-file-scan-dir=/usr/local/etc/php/5.5/conf.d --with-iconv-dir=/usr --enable-dba --with-
checking for krb5-config... /usr/bin/krb5-config
checking for DSA_get_default_method in -lssl... no
checking for X509_free in -lcrypto... yes
checking for pkg-config... no
configure: error: Cannot find OpenSSL's <evp.h>
Error: Homebrew doesn't know what compiler versions ship with your version
of Xcode (6.0). Please `brew update` and if that doesn't help, file
an issue with the output of `brew --config`:
  https://github.com/Homebrew/homebrew/issues

Note that we only track stable, released versions of Xcode.

Thanks!

READ THIS: https://github.com/Homebrew/homebrew/wiki/troubleshooting
If reporting this issue please do so at (not Homebrew/homebrew):
  https://github.com/homebrew/homebrew-php/issues

/usr/local/Library/Homebrew/utils.rb:315:in `rescue in open': uninitialized constant GitHub::OpenSSL (NameError)
    from /usr/local/Library/Homebrew/utils.rb:300:in `open'
    from /usr/local/Library/Homebrew/utils.rb:341:in `issues_matching'
    from /usr/local/Library/Homebrew/utils.rb:369:in `issues_for_formula'
    from /usr/local/Library/Homebrew/exceptions.rb:171:in `fetch_issues'
    from /usr/local/Library/Homebrew/exceptions.rb:167:in `issues'
    from /usr/local/Library/Homebrew/exceptions.rb:208:in `dump'
    from /usr/local/Library/brew.rb:133:in `rescue in <main>'
    from /usr/local/Library/brew.rb:72:in `<main>'

and

brew --config
HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/Homebrew/homebrew.git
HEAD: 0ad9174676adbfccaca3130f17d31a2c72dd6f44
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: 8-core 64-bit ivybridge
OS X: 10.10-x86_64
Xcode: 6.0
Clang: 6.0 build 600
X11: N/A
System Ruby: 2.0.0-451
Perl: /usr/bin/perl
Python: /usr/bin/python
Ruby: /usr/bin/ruby
@ericdowell

This comment has been minimized.

Show comment
Hide comment
@ericdowell

ericdowell Jun 9, 2014

Same problem, but I figured it out with some research. (this helped Issues #241)

  • Side note: to get brew doctor to work, copy the ruby 1.8 folder from Mavericks (System/Library/Frameworks/Ruby/Versions/1.8) into the same place on your Mac OS X 10.10 install. (Issues #29795)
  1. Download Xcode 5.1.1 and Command Line Tools for OS X 10 10 June 2014 from Apple Developer Portal
  2. Copy Xcode 5.1.1 into applications, open it and agree to the terms.
  3. Install Command Line Tools for OS X 10 10 June 2014
  4. Make sure brew --config is equal to this:
HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/Homebrew/homebrew
HEAD: 4f2d5ad603afb4074572ef53801b57ad389dc0b6
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: quad-core 64-bit arrandale
OS X: 10.10-x86_64
Xcode: 5.1.1
Clang: 5.1 build 503
X11: N/A
System Ruby: 2.0.0-451
Perl: /usr/bin/perl
Python: /usr/bin/python
Ruby: /usr/bin/ruby

and to finish (Took several minutes to complete.)

brew install php55
==> Downloading http://www.php.net/get/php-5.5.13.tar.bz2/from/this/mirror
Already downloaded: /Library/Caches/Homebrew/php55-5.5.13
==> ./configure --prefix=/usr/local/Cellar/php55/5.5.13 --localstatedir=/usr/loc
==> make
==> make install
==> /usr/local/Cellar/php55/5.5.13/bin/pear config-set php_ini /usr/local/etc/ph
==> Caveats
To enable PHP in Apache add the following to httpd.conf and restart Apache:
    LoadModule php5_module    /usr/local/opt/php55/libexec/apache2/libphp5.so

The php.ini file can be found in:
    /usr/local/etc/php/5.5/php.ini

✩✩✩✩ PEAR ✩✩✩✩

If PEAR complains about permissions, 'fix' the default PEAR permissions and config:
    chmod -R ug+w /usr/local/Cellar/php55/5.5.13/lib/php
    pear config-set php_ini /usr/local/etc/php/5.5/php.ini

✩✩✩✩ Extensions ✩✩✩✩

If you are having issues with custom extension compiling, ensure that
you are using the brew version, by placing /usr/local/bin before /usr/sbin in your PATH:

      PATH="/usr/local/bin:$PATH"

PHP55 Extensions will always be compiled against this PHP. Please install them
using --without-homebrew-php to enable compiling against system PHP.

✩✩✩✩ PHP CLI ✩✩✩✩

If you wish to swap the PHP you use on the command line, you should add the following to ~/.bashrc,
~/.zshrc, ~/.profile or your shell's equivalent configuration file:

      export PATH="$(brew --prefix homebrew/php/php55)/bin:$PATH"

To have launchd start php55 at login:
    ln -sfv /usr/local/opt/php55/*.plist ~/Library/LaunchAgents
Then to load php55 now:
    launchctl load ~/Library/LaunchAgents/homebrew.mxcl.php55.plist
==> Summary
  /usr/local/Cellar/php55/5.5.13: 492 files, 38M, built in 11.8 minutes

ericdowell commented Jun 9, 2014

Same problem, but I figured it out with some research. (this helped Issues #241)

  • Side note: to get brew doctor to work, copy the ruby 1.8 folder from Mavericks (System/Library/Frameworks/Ruby/Versions/1.8) into the same place on your Mac OS X 10.10 install. (Issues #29795)
  1. Download Xcode 5.1.1 and Command Line Tools for OS X 10 10 June 2014 from Apple Developer Portal
  2. Copy Xcode 5.1.1 into applications, open it and agree to the terms.
  3. Install Command Line Tools for OS X 10 10 June 2014
  4. Make sure brew --config is equal to this:
HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/Homebrew/homebrew
HEAD: 4f2d5ad603afb4074572ef53801b57ad389dc0b6
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: quad-core 64-bit arrandale
OS X: 10.10-x86_64
Xcode: 5.1.1
Clang: 5.1 build 503
X11: N/A
System Ruby: 2.0.0-451
Perl: /usr/bin/perl
Python: /usr/bin/python
Ruby: /usr/bin/ruby

and to finish (Took several minutes to complete.)

brew install php55
==> Downloading http://www.php.net/get/php-5.5.13.tar.bz2/from/this/mirror
Already downloaded: /Library/Caches/Homebrew/php55-5.5.13
==> ./configure --prefix=/usr/local/Cellar/php55/5.5.13 --localstatedir=/usr/loc
==> make
==> make install
==> /usr/local/Cellar/php55/5.5.13/bin/pear config-set php_ini /usr/local/etc/ph
==> Caveats
To enable PHP in Apache add the following to httpd.conf and restart Apache:
    LoadModule php5_module    /usr/local/opt/php55/libexec/apache2/libphp5.so

The php.ini file can be found in:
    /usr/local/etc/php/5.5/php.ini

✩✩✩✩ PEAR ✩✩✩✩

If PEAR complains about permissions, 'fix' the default PEAR permissions and config:
    chmod -R ug+w /usr/local/Cellar/php55/5.5.13/lib/php
    pear config-set php_ini /usr/local/etc/php/5.5/php.ini

✩✩✩✩ Extensions ✩✩✩✩

If you are having issues with custom extension compiling, ensure that
you are using the brew version, by placing /usr/local/bin before /usr/sbin in your PATH:

      PATH="/usr/local/bin:$PATH"

PHP55 Extensions will always be compiled against this PHP. Please install them
using --without-homebrew-php to enable compiling against system PHP.

✩✩✩✩ PHP CLI ✩✩✩✩

If you wish to swap the PHP you use on the command line, you should add the following to ~/.bashrc,
~/.zshrc, ~/.profile or your shell's equivalent configuration file:

      export PATH="$(brew --prefix homebrew/php/php55)/bin:$PATH"

To have launchd start php55 at login:
    ln -sfv /usr/local/opt/php55/*.plist ~/Library/LaunchAgents
Then to load php55 now:
    launchctl load ~/Library/LaunchAgents/homebrew.mxcl.php55.plist
==> Summary
  /usr/local/Cellar/php55/5.5.13: 492 files, 38M, built in 11.8 minutes
@lucasmichot

This comment has been minimized.

Show comment
Hide comment
@lucasmichot

lucasmichot Jun 9, 2014

Contributor

Thanks for input @ericdowell
@OKNoah @arsonik @littleguy230 , can you also ensure openssl is properly installed and linked ?
Can you try again and then give feedback ?

Contributor

lucasmichot commented Jun 9, 2014

Thanks for input @ericdowell
@OKNoah @arsonik @littleguy230 , can you also ensure openssl is properly installed and linked ?
Can you try again and then give feedback ?

@arsonik

This comment has been minimized.

Show comment
Hide comment
@arsonik

arsonik Jun 9, 2014

I've found a way on a different post:
#591

sudo ln -s /Applications/Xcode6-Beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include /usr/include

And it's working !

arsonik commented Jun 9, 2014

I've found a way on a different post:
#591

sudo ln -s /Applications/Xcode6-Beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include /usr/include

And it's working !

@SamXiao

This comment has been minimized.

Show comment
Hide comment
@SamXiao

SamXiao Jun 17, 2014

@lucasmichot , It still happen when I updated my openssl to "OpenSSL 1.0.1h 5 Jun 2014".
brew --config
HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/Homebrew/homebrew
HEAD: 0017f2efd451a18dc8452a65db3cbd560c289360
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: 8-core 64-bit haswell
OS X: 10.9.3-x86_64
Xcode: 5.1.1
Clang: 5.1 build 503
X11: N/A
System Ruby: 2.0.0-451
Perl: /usr/bin/perl
Python: /usr/bin/python
Ruby: /usr/bin/ruby

SamXiao commented Jun 17, 2014

@lucasmichot , It still happen when I updated my openssl to "OpenSSL 1.0.1h 5 Jun 2014".
brew --config
HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/Homebrew/homebrew
HEAD: 0017f2efd451a18dc8452a65db3cbd560c289360
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: 8-core 64-bit haswell
OS X: 10.9.3-x86_64
Xcode: 5.1.1
Clang: 5.1 build 503
X11: N/A
System Ruby: 2.0.0-451
Perl: /usr/bin/perl
Python: /usr/bin/python
Ruby: /usr/bin/ruby

@lucasmichot

This comment has been minimized.

Show comment
Hide comment
@lucasmichot

lucasmichot Jun 17, 2014

Contributor

@SamXiao : Can you output which openssl and brew link openssl ?

Contributor

lucasmichot commented Jun 17, 2014

@SamXiao : Can you output which openssl and brew link openssl ?

@SamXiao

This comment has been minimized.

Show comment
Hide comment
@SamXiao

SamXiao Jun 18, 2014

@lucasmichot
which openssl
/usr/local/bin/openssl

brew link openssl
Warning: Already linked: /usr/local/Cellar/openssl/1.0.1h
To relink: brew unlink openssl && brew link openssl

SamXiao commented Jun 18, 2014

@lucasmichot
which openssl
/usr/local/bin/openssl

brew link openssl
Warning: Already linked: /usr/local/Cellar/openssl/1.0.1h
To relink: brew unlink openssl && brew link openssl

@lucasmichot

This comment has been minimized.

Show comment
Hide comment
@lucasmichot

lucasmichot Jun 18, 2014

Contributor

OK @SamXiao
So what you should probably do is brew link openssl --force then install your formula. Can you have a try ?

Contributor

lucasmichot commented Jun 18, 2014

OK @SamXiao
So what you should probably do is brew link openssl --force then install your formula. Can you have a try ?

@SamXiao

This comment has been minimized.

Show comment
Hide comment
@SamXiao

SamXiao Jun 18, 2014

@lucasmichot, I already did it, linked force after installed openssl. That error still happened.

brew install php55
==> Downloading http://www.php.net/get/php-5.5.13.tar.bz2/from/this/mirror
Already downloaded: /Library/Caches/Homebrew/php55-5.5.13
==> ./configure --prefix=/usr/local/Cellar/php55/5.5.13 --localstatedir=/usr/local/var --sysconfdir=/usr/local/etc/php/5.5 --with-config-file-path=/usr/local/etc/php/5.5 --with-config-file-scan-dir=/usr/local/etc/php/5.5/conf
checking for krb5-config... /usr/bin/krb5-config
checking for DSA_get_default_method in -lssl... no
checking for X509_free in -lcrypto... yes
checking for pkg-config... no
configure: error: Cannot find OpenSSL's <evp.h>

READ THIS: https://github.com/Homebrew/homebrew/wiki/troubleshooting
If reporting this issue please do so at (not Homebrew/homebrew):
https://github.com/homebrew/homebrew-php/issues

/usr/local/Library/Homebrew/utils.rb:319:in rescue in open': uninitialized constant GitHub::OpenSSL (NameError) from /usr/local/Library/Homebrew/utils.rb:304:inopen'
from /usr/local/Library/Homebrew/utils.rb:345:in issues_matching' from /usr/local/Library/Homebrew/utils.rb:373:inissues_for_formula'
from /usr/local/Library/Homebrew/exceptions.rb:171:in fetch_issues' from /usr/local/Library/Homebrew/exceptions.rb:167:inissues'
from /usr/local/Library/Homebrew/exceptions.rb:208:in dump' from /usr/local/Library/brew.rb:133:inrescue in

'
from /usr/local/Library/brew.rb:72:in `'

SamXiao commented Jun 18, 2014

@lucasmichot, I already did it, linked force after installed openssl. That error still happened.

brew install php55
==> Downloading http://www.php.net/get/php-5.5.13.tar.bz2/from/this/mirror
Already downloaded: /Library/Caches/Homebrew/php55-5.5.13
==> ./configure --prefix=/usr/local/Cellar/php55/5.5.13 --localstatedir=/usr/local/var --sysconfdir=/usr/local/etc/php/5.5 --with-config-file-path=/usr/local/etc/php/5.5 --with-config-file-scan-dir=/usr/local/etc/php/5.5/conf
checking for krb5-config... /usr/bin/krb5-config
checking for DSA_get_default_method in -lssl... no
checking for X509_free in -lcrypto... yes
checking for pkg-config... no
configure: error: Cannot find OpenSSL's <evp.h>

READ THIS: https://github.com/Homebrew/homebrew/wiki/troubleshooting
If reporting this issue please do so at (not Homebrew/homebrew):
https://github.com/homebrew/homebrew-php/issues

/usr/local/Library/Homebrew/utils.rb:319:in rescue in open': uninitialized constant GitHub::OpenSSL (NameError) from /usr/local/Library/Homebrew/utils.rb:304:inopen'
from /usr/local/Library/Homebrew/utils.rb:345:in issues_matching' from /usr/local/Library/Homebrew/utils.rb:373:inissues_for_formula'
from /usr/local/Library/Homebrew/exceptions.rb:171:in fetch_issues' from /usr/local/Library/Homebrew/exceptions.rb:167:inissues'
from /usr/local/Library/Homebrew/exceptions.rb:208:in dump' from /usr/local/Library/brew.rb:133:inrescue in

'
from /usr/local/Library/brew.rb:72:in `'

@SamXiao

This comment has been minimized.

Show comment
Hide comment
@SamXiao

SamXiao Jun 18, 2014

But when I run brew doctor after brew link openssl --force
It return

Warning: Some keg-only formula are linked into the Cellar.
Linking a keg-only formula, such as gettext, into the cellar with
brew link <formula> will cause other formulae to detect them during
the ./configure step. This may cause problems when compiling those
other formulae.

Binaries provided by keg-only formulae may override system binaries
with other strange results.

You may wish to brew unlink these brews:

openssl

SamXiao commented Jun 18, 2014

But when I run brew doctor after brew link openssl --force
It return

Warning: Some keg-only formula are linked into the Cellar.
Linking a keg-only formula, such as gettext, into the cellar with
brew link <formula> will cause other formulae to detect them during
the ./configure step. This may cause problems when compiling those
other formulae.

Binaries provided by keg-only formulae may override system binaries
with other strange results.

You may wish to brew unlink these brews:

openssl
@ghost

This comment has been minimized.

Show comment
Hide comment
@ghost

ghost Jun 20, 2014

I'm trying to install php53 under Mavericks and I also get the same error:

$ brew --config
HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/Homebrew/homebrew.git
HEAD: ac850a58ff9b978670771b71dbcf4eec4418db32
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: quad-core 64-bit haswell
OS X: 10.9.3-x86_64
Xcode: 5.1.1
CLT: 5.1.0.0.1.1396320587
Clang: 5.1 build 503
X11: 2.7.6 => /opt/X11
System Ruby: 2.0.0-451
Perl: /usr/bin/perl
Python: /usr/bin/python
Ruby: /usr/bin/ruby
$ brew install php53
==> Downloading http://www.php.net/get/php-5.3.28.tar.bz2/from/this/mirror
Already downloaded: /Library/Caches/Homebrew/php53-5.3.28
==> Patching
patching file configure
patching file configure.in
patching file Zend/zend_language_parser.y
patching file configure
patching file Zend/acinclude.m4
==> rm Zend/zend_{language,ini}_parser.[ch]
Warning: Backing up all known pear.conf and .pearrc files
Warning: If you have a pre-existing pear install outside
         of homebrew-php, or you are using a non-standard
         pear.conf location, installation may fail.
==> ./configure --prefix=/usr/local/Cellar/php53/5.3.28 --localstatedir=/usr/local/var --sysconfdir=/usr/local/etc/php/5.3 --with-config-file-path=/usr/local/etc/php/5.3 --with-config-file-scan-dir=/usr/local/etc/php/5.3/conf.d --with-iconv-dir=/usr --enable-dba --with-
checking whether to enable LIBXML support... yes
checking libxml2 install dir... no
checking for xml2-config path... /usr/bin/xml2-config
checking whether libxml build works... no
configure: error: build test failed.  Please check the config.log for details.

READ THIS: https://github.com/Homebrew/homebrew/wiki/troubleshooting
If reporting this issue please do so at (not Homebrew/homebrew):
  https://github.com/josegonzalez/homebrew-php/issues

/usr/local/Library/Homebrew/utils.rb:319:in `rescue in open': uninitialized constant GitHub::OpenSSL (NameError)
    from /usr/local/Library/Homebrew/utils.rb:304:in `open'
    from /usr/local/Library/Homebrew/utils.rb:345:in `issues_matching'
    from /usr/local/Library/Homebrew/utils.rb:373:in `issues_for_formula'
    from /usr/local/Library/Homebrew/exceptions.rb:171:in `fetch_issues'
    from /usr/local/Library/Homebrew/exceptions.rb:167:in `issues'
    from /usr/local/Library/Homebrew/exceptions.rb:208:in `dump'
    from /usr/local/Library/brew.rb:133:in `rescue in <main>'
    from /usr/local/Library/brew.rb:72:in `<main>'

ghost commented Jun 20, 2014

I'm trying to install php53 under Mavericks and I also get the same error:

$ brew --config
HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/Homebrew/homebrew.git
HEAD: ac850a58ff9b978670771b71dbcf4eec4418db32
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: quad-core 64-bit haswell
OS X: 10.9.3-x86_64
Xcode: 5.1.1
CLT: 5.1.0.0.1.1396320587
Clang: 5.1 build 503
X11: 2.7.6 => /opt/X11
System Ruby: 2.0.0-451
Perl: /usr/bin/perl
Python: /usr/bin/python
Ruby: /usr/bin/ruby
$ brew install php53
==> Downloading http://www.php.net/get/php-5.3.28.tar.bz2/from/this/mirror
Already downloaded: /Library/Caches/Homebrew/php53-5.3.28
==> Patching
patching file configure
patching file configure.in
patching file Zend/zend_language_parser.y
patching file configure
patching file Zend/acinclude.m4
==> rm Zend/zend_{language,ini}_parser.[ch]
Warning: Backing up all known pear.conf and .pearrc files
Warning: If you have a pre-existing pear install outside
         of homebrew-php, or you are using a non-standard
         pear.conf location, installation may fail.
==> ./configure --prefix=/usr/local/Cellar/php53/5.3.28 --localstatedir=/usr/local/var --sysconfdir=/usr/local/etc/php/5.3 --with-config-file-path=/usr/local/etc/php/5.3 --with-config-file-scan-dir=/usr/local/etc/php/5.3/conf.d --with-iconv-dir=/usr --enable-dba --with-
checking whether to enable LIBXML support... yes
checking libxml2 install dir... no
checking for xml2-config path... /usr/bin/xml2-config
checking whether libxml build works... no
configure: error: build test failed.  Please check the config.log for details.

READ THIS: https://github.com/Homebrew/homebrew/wiki/troubleshooting
If reporting this issue please do so at (not Homebrew/homebrew):
  https://github.com/josegonzalez/homebrew-php/issues

/usr/local/Library/Homebrew/utils.rb:319:in `rescue in open': uninitialized constant GitHub::OpenSSL (NameError)
    from /usr/local/Library/Homebrew/utils.rb:304:in `open'
    from /usr/local/Library/Homebrew/utils.rb:345:in `issues_matching'
    from /usr/local/Library/Homebrew/utils.rb:373:in `issues_for_formula'
    from /usr/local/Library/Homebrew/exceptions.rb:171:in `fetch_issues'
    from /usr/local/Library/Homebrew/exceptions.rb:167:in `issues'
    from /usr/local/Library/Homebrew/exceptions.rb:208:in `dump'
    from /usr/local/Library/brew.rb:133:in `rescue in <main>'
    from /usr/local/Library/brew.rb:72:in `<main>'
@lucasmichot

This comment has been minimized.

Show comment
Hide comment
@lucasmichot

lucasmichot Jun 20, 2014

Contributor

Can you check that libxml is properly installed and linked ?

Contributor

lucasmichot commented Jun 20, 2014

Can you check that libxml is properly installed and linked ?

@JJones-Yottaa

This comment has been minimized.

Show comment
Hide comment
@JJones-Yottaa

JJones-Yottaa Jun 25, 2014

FYI I did what @arsonik suggested (adapted to my platform) and it worked. Use tab-complete to help you find the appropriate /usr/include path, i.e.
sudo ln -s /Applications/Xcode TAB
(should autocomplete if you only have one Xcode installed)
Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10. TAB TAB
(lists OS versions for SDKs; type the minor version number for your OS, e.g. "8" for 10.8/Mountain Lion or "9" for 10.9/Mavericks, and press TAB to autocomplete the SDK path)
usr/include /usr/include ENTER

JJones-Yottaa commented Jun 25, 2014

FYI I did what @arsonik suggested (adapted to my platform) and it worked. Use tab-complete to help you find the appropriate /usr/include path, i.e.
sudo ln -s /Applications/Xcode TAB
(should autocomplete if you only have one Xcode installed)
Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10. TAB TAB
(lists OS versions for SDKs; type the minor version number for your OS, e.g. "8" for 10.8/Mountain Lion or "9" for 10.9/Mavericks, and press TAB to autocomplete the SDK path)
usr/include /usr/include ENTER

@motou

This comment has been minimized.

Show comment
Hide comment
@motou

motou Jul 8, 2014

I did a little more to overcome the error messages. ;)

  1. "Error: Homebrew doesn't know what compiler versions ship with your version
    of Xcode (6.0). Please brew update and if that doesn't help, file
    an issue with the output of brew --config:
    https://github.com/Homebrew/homebrew/issues

Note that we only track stable, released versions of Xcode."

=> vi /usr/local/Library/Homebrew/os/mac.rb

find the line with

  "5.1.1" => { :clang => "5.1", :clang_build => 503 },

add the following line after that

  "6.0" => { :clang => "6.0", :clang_build => 600 },
  1. use @arsonik way to let brew find the right include folder.

motou commented Jul 8, 2014

I did a little more to overcome the error messages. ;)

  1. "Error: Homebrew doesn't know what compiler versions ship with your version
    of Xcode (6.0). Please brew update and if that doesn't help, file
    an issue with the output of brew --config:
    https://github.com/Homebrew/homebrew/issues

Note that we only track stable, released versions of Xcode."

=> vi /usr/local/Library/Homebrew/os/mac.rb

find the line with

  "5.1.1" => { :clang => "5.1", :clang_build => 503 },

add the following line after that

  "6.0" => { :clang => "6.0", :clang_build => 600 },
  1. use @arsonik way to let brew find the right include folder.
@tangplin

This comment has been minimized.

Show comment
Hide comment
@tangplin

tangplin Jul 15, 2014

#241

Thanks @simonrobb

For future reference of anybody looking for Command Line Tools with Xcode 5, open up a Terminal window and type xcode-select --install. A window will appear informing you command line tools are required. Click Install and you should be good to go.

tangplin commented Jul 15, 2014

#241

Thanks @simonrobb

For future reference of anybody looking for Command Line Tools with Xcode 5, open up a Terminal window and type xcode-select --install. A window will appear informing you command line tools are required. Click Install and you should be good to go.

@pepijnolivier

This comment has been minimized.

Show comment
Hide comment
@pepijnolivier

pepijnolivier Jul 16, 2014

@tangplin - Worked like a charm. I did not have an Apple Developers account so thanks !

pepijnolivier commented Jul 16, 2014

@tangplin - Worked like a charm. I did not have an Apple Developers account so thanks !

@chrisyip

This comment has been minimized.

Show comment
Hide comment
@chrisyip

chrisyip Jul 27, 2014

Thanks to @arsonik and @JJones-Yottaa, my problem solved by running the following command:

sudo ln -s /Applications/Xcode6-Beta4.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include /usr/include

chrisyip commented Jul 27, 2014

Thanks to @arsonik and @JJones-Yottaa, my problem solved by running the following command:

sudo ln -s /Applications/Xcode6-Beta4.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include /usr/include
@Dinduks

This comment has been minimized.

Show comment
Hide comment
@Dinduks

Dinduks Jul 27, 2014

@chrisyip @arsonik: Tried the ln -s tip but it didn't work. The path exists and the symlink creation goes fine, but I still get this error:

==> /usr/local/Cellar/php53/5.3.28/bin/pear config-set php_ini /usr/local/etc/php/5.3/php.ini
/usr/local/Cellar/php53/5.3.28/bin/pear: line 28: /usr/local/Cellar/php53/5.3.28/bin/php: No such file or directory
/usr/local/Cellar/php53/5.3.28/bin/pear: line 28: exec: /usr/local/Cellar/php53/5.3.28/bin/php: cannot execute: No such file or directory

I managed to install PHP 5.6.0RC2 (php56) with no issue though.

Dinduks commented Jul 27, 2014

@chrisyip @arsonik: Tried the ln -s tip but it didn't work. The path exists and the symlink creation goes fine, but I still get this error:

==> /usr/local/Cellar/php53/5.3.28/bin/pear config-set php_ini /usr/local/etc/php/5.3/php.ini
/usr/local/Cellar/php53/5.3.28/bin/pear: line 28: /usr/local/Cellar/php53/5.3.28/bin/php: No such file or directory
/usr/local/Cellar/php53/5.3.28/bin/pear: line 28: exec: /usr/local/Cellar/php53/5.3.28/bin/php: cannot execute: No such file or directory

I managed to install PHP 5.6.0RC2 (php56) with no issue though.

@chrisyip

This comment has been minimized.

Show comment
Hide comment
@chrisyip

chrisyip Jul 28, 2014

@Dinduks try reinstall PHP.

chrisyip commented Jul 28, 2014

@Dinduks try reinstall PHP.

@arsonik

This comment has been minimized.

Show comment
Hide comment
@arsonik

arsonik Jul 31, 2014

check if the symlink exists first

ls -l /usr/include      
lrwxr-xr-x  1 root  wheel  117 Jun  7 16:01 /usr/include -> /Applications/Xcode6-Beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include

Mine was broken after an update of xCode (beta > beta4)

arsonik commented Jul 31, 2014

check if the symlink exists first

ls -l /usr/include      
lrwxr-xr-x  1 root  wheel  117 Jun  7 16:01 /usr/include -> /Applications/Xcode6-Beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include

Mine was broken after an update of xCode (beta > beta4)

@Dinduks

This comment has been minimized.

Show comment
Hide comment
@Dinduks

Dinduks Jul 31, 2014

@arsonik My link exists and is working. I created it after updating Xcode.

Dinduks commented Jul 31, 2014

@arsonik My link exists and is working. I created it after updating Xcode.

@Maskime

This comment has been minimized.

Show comment
Hide comment
@Maskime

Maskime Aug 5, 2014

sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/include /usr/include works also

Maskime commented Aug 5, 2014

sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/include /usr/include works also

@Dinduks

This comment has been minimized.

Show comment
Hide comment
@Dinduks

Dinduks Aug 5, 2014

I’m on Yosemite (10.10) so I’d rather symlink to MacOSX10.10.sdk. :)

On 5 août 2014 at 09:35:15, Maxime Faye (notifications@github.com) wrote:

sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/include /usr/include works also


Reply to this email directly or view it on GitHub:
#1181 (comment)

Dinduks commented Aug 5, 2014

I’m on Yosemite (10.10) so I’d rather symlink to MacOSX10.10.sdk. :)

On 5 août 2014 at 09:35:15, Maxime Faye (notifications@github.com) wrote:

sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/include /usr/include works also


Reply to this email directly or view it on GitHub:
#1181 (comment)

@ablyler

This comment has been minimized.

Show comment
Hide comment
@ablyler

ablyler Aug 10, 2014

Contributor

@Dinduks: php53 was broken w/ OS X 10.10 until last night when I committed a fix.

Contributor

ablyler commented Aug 10, 2014

@Dinduks: php53 was broken w/ OS X 10.10 until last night when I committed a fix.

@MrZaYaC

This comment has been minimized.

Show comment
Hide comment
@MrZaYaC

MrZaYaC Oct 17, 2014

Installing Command Line Tools for OSX10.10 for Xcode 6.1 work for me

MrZaYaC commented Oct 17, 2014

Installing Command Line Tools for OSX10.10 for Xcode 6.1 work for me

@daleyjem

This comment has been minimized.

Show comment
Hide comment
@daleyjem

daleyjem Oct 18, 2014

@tangplin 's method worked for me... use: "xcode-select --install" and you won't have to do all the symlink'ing

daleyjem commented Oct 18, 2014

@tangplin 's method worked for me... use: "xcode-select --install" and you won't have to do all the symlink'ing

@lucasmichot

This comment has been minimized.

Show comment
Hide comment
@lucasmichot

lucasmichot Oct 20, 2014

Contributor

https://github.com/Homebrew/homebrew-php#common-upgrade-issues
https://github.com/Homebrew/homebrew-php#common-issues

I think the README.md is detailed. If one oy you think it is not clear enough, feel free to make a PR

Contributor

lucasmichot commented Oct 20, 2014

https://github.com/Homebrew/homebrew-php#common-upgrade-issues
https://github.com/Homebrew/homebrew-php#common-issues

I think the README.md is detailed. If one oy you think it is not clear enough, feel free to make a PR

@cordoval

This comment has been minimized.

Show comment
Hide comment
@cordoval

cordoval Oct 20, 2014

Contributor

I updated to 6.1 the Xcode and then the CLT i think is included

when i then run xcode-select --install it tells me

~ xcode-select --install Luiss-MacBook-Pro-3 [9:30:42]
xcode-select: error: command line tools are already installed, use "Software Update" to install updates

I am not sure then if i have the CLT, i guess you mean command line tools? That i guess already comes with it right?

screenshot 2014-10-20 09 33 54

Contributor

cordoval commented Oct 20, 2014

I updated to 6.1 the Xcode and then the CLT i think is included

when i then run xcode-select --install it tells me

~ xcode-select --install Luiss-MacBook-Pro-3 [9:30:42]
xcode-select: error: command line tools are already installed, use "Software Update" to install updates

I am not sure then if i have the CLT, i guess you mean command line tools? That i guess already comes with it right?

screenshot 2014-10-20 09 33 54

@cordoval

This comment has been minimized.

Show comment
Hide comment
@cordoval

cordoval Oct 20, 2014

Contributor

ok solved after all the hassle

Contributor

cordoval commented Oct 20, 2014

ok solved after all the hassle

@shrop

This comment has been minimized.

Show comment
Hide comment
@shrop

shrop Oct 20, 2014

Contributor

@lucasmichot, I removed the symlink and followed your instructions. Seems to have worked great. Thanks!

Contributor

shrop commented Oct 20, 2014

@lucasmichot, I removed the symlink and followed your instructions. Seems to have worked great. Thanks!

@robbash

This comment has been minimized.

Show comment
Hide comment
@robbash

robbash Oct 23, 2014

@lucasmichot For me brew link openssl --force worked pretty well.

robbash commented Oct 23, 2014

@lucasmichot For me brew link openssl --force worked pretty well.

@sorenmh

This comment has been minimized.

Show comment
Hide comment
@sorenmh

sorenmh Oct 28, 2014

@lucasmichot Thanks, that worked for me as well: "xcode-select --install".

sorenmh commented Oct 28, 2014

@lucasmichot Thanks, that worked for me as well: "xcode-select --install".

@dragulceo

This comment has been minimized.

Show comment
Hide comment
@dragulceo

dragulceo Oct 28, 2014

@lucasmichot thanks. You posted the working method. I didn't need to mingle with openssl. I'll add the obvious link to the comment to help people that get here later.

dragulceo commented Oct 28, 2014

@lucasmichot thanks. You posted the working method. I didn't need to mingle with openssl. I'll add the obvious link to the comment to help people that get here later.

@corbanb

This comment has been minimized.

Show comment
Hide comment
@corbanb

corbanb commented Nov 4, 2014

@kaz231

This comment has been minimized.

Show comment
Hide comment
@kaz231

kaz231 Nov 7, 2014

"xcode-select --install" works. Thanks

kaz231 commented Nov 7, 2014

"xcode-select --install" works. Thanks

@meezaan

This comment has been minimized.

Show comment
Hide comment
@meezaan

meezaan Nov 10, 2014

It does, thank you!

meezaan commented Nov 10, 2014

It does, thank you!

@paulbhartzog

This comment has been minimized.

Show comment
Hide comment
@paulbhartzog

paulbhartzog Nov 11, 2014

On Yosemite. The symlink with sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include /usr/include worked for me also. Thx.

paulbhartzog commented Nov 11, 2014

On Yosemite. The symlink with sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include /usr/include worked for me also. Thx.

@jfriv

This comment has been minimized.

Show comment
Hide comment
@jfriv

jfriv Nov 12, 2014

+1 for the symlink:
sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/ /usr/include

jfriv commented Nov 12, 2014

+1 for the symlink:
sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/ /usr/include

@llbbl

This comment has been minimized.

Show comment
Hide comment
@llbbl

llbbl Nov 14, 2014

Doing some testing with a Fresh install of Mavericks.
Forcing openssl link did NOT work for me.

brew link openssl --force

However +1 for symlink fixing the error "configure: error: Cannot find OpenSSL's <evp.h>":

sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include /usr/include

BTW doing this using ruby 1.8.7 w/ gcc47 + gcc42 to fix other problems with this package ... But it was still not happy, resulting in a different error:

  "_SSLv2_server_method", referenced from:
      _php_openssl_setup_crypto in xp_ssl.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [sapi/fpm/php-fpm] Error 1

Some detective work made me suspect that it wasn't using the right gcc version. The one in /usr/bin instead of the other ones installed /usr/local/bin. Tried editing PATH to force it to look in /usr/local/bin first, but also tried prefixing gcc version before brew install; neither thing worked.

I was able to get it to compile with Yosemite with slightly less trouble a couple of weeks back. My recommendation if you are on Mavericks and attempting this, upgrade to Yosemite first and work through those batch of issues.

tl:dr; Problem exists on Mavericks also, recommendation to upgrade to Yosemite before attempting homebrew-php.

llbbl commented Nov 14, 2014

Doing some testing with a Fresh install of Mavericks.
Forcing openssl link did NOT work for me.

brew link openssl --force

However +1 for symlink fixing the error "configure: error: Cannot find OpenSSL's <evp.h>":

sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include /usr/include

BTW doing this using ruby 1.8.7 w/ gcc47 + gcc42 to fix other problems with this package ... But it was still not happy, resulting in a different error:

  "_SSLv2_server_method", referenced from:
      _php_openssl_setup_crypto in xp_ssl.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [sapi/fpm/php-fpm] Error 1

Some detective work made me suspect that it wasn't using the right gcc version. The one in /usr/bin instead of the other ones installed /usr/local/bin. Tried editing PATH to force it to look in /usr/local/bin first, but also tried prefixing gcc version before brew install; neither thing worked.

I was able to get it to compile with Yosemite with slightly less trouble a couple of weeks back. My recommendation if you are on Mavericks and attempting this, upgrade to Yosemite first and work through those batch of issues.

tl:dr; Problem exists on Mavericks also, recommendation to upgrade to Yosemite before attempting homebrew-php.

@Oxyaction

This comment has been minimized.

Show comment
Hide comment
@Oxyaction

Oxyaction Nov 20, 2014

sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/ /usr/include
didnt work for me but
sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/include/ /usr/include
did

Oxyaction commented Nov 20, 2014

sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/ /usr/include
didnt work for me but
sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/include/ /usr/include
did

@llbbl

This comment has been minimized.

Show comment
Hide comment
@llbbl

llbbl Nov 20, 2014

@Oxyaction - that is because you had an older version of xcode installed. I think all the 6.x versions are in the 10.10 folder.

llbbl commented Nov 20, 2014

@Oxyaction - that is because you had an older version of xcode installed. I think all the 6.x versions are in the 10.10 folder.

@joshlopes

This comment has been minimized.

Show comment
Hide comment
@joshlopes

joshlopes Nov 21, 2014

Symlink worked for me as well +1.

Xcode install was giving me some weird network issues - it couldnt download dont tell , dont ask

joshlopes commented Nov 21, 2014

Symlink worked for me as well +1.

Xcode install was giving me some weird network issues - it couldnt download dont tell , dont ask

@tkuichooseyou

This comment has been minimized.

Show comment
Hide comment
@tkuichooseyou

tkuichooseyou Nov 22, 2014

xcode-select --install worked for me too!

tkuichooseyou commented Nov 22, 2014

xcode-select --install worked for me too!

@phpguru

This comment has been minimized.

Show comment
Hide comment
@phpguru

phpguru Nov 26, 2014

If you're on Yosemite, update XCode, then...

brew update
sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/ /usr/include  

then try again.

phpguru commented Nov 26, 2014

If you're on Yosemite, update XCode, then...

brew update
sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/ /usr/include  

then try again.

@marcusstenbeck

This comment has been minimized.

Show comment
Hide comment
@marcusstenbeck

marcusstenbeck Dec 10, 2014

+1 xcode-select --install on Yosemite 10.10.1

marcusstenbeck commented Dec 10, 2014

+1 xcode-select --install on Yosemite 10.10.1

@umitakkaya

This comment has been minimized.

Show comment
Hide comment
@umitakkaya

umitakkaya Dec 20, 2014

I faced this problem after i upgraded to Yosemite.
I needed to reinstall command line developer tools to fix it.

umitakkaya commented Dec 20, 2014

I faced this problem after i upgraded to Yosemite.
I needed to reinstall command line developer tools to fix it.

@beaudierman

This comment has been minimized.

Show comment
Hide comment
@beaudierman

beaudierman Dec 21, 2014

I had this issue on Yosemite 10.10.1 too, using xcode-select --install fixed this for me

beaudierman commented Dec 21, 2014

I had this issue on Yosemite 10.10.1 too, using xcode-select --install fixed this for me

@ryz

This comment has been minimized.

Show comment
Hide comment
@ryz

ryz Dec 31, 2014

Can confirm this issue is also fixed for me on Yosemite 10.10.1, after using xcode-select --install to reinstall the command line developer tools

ryz commented Dec 31, 2014

Can confirm this issue is also fixed for me on Yosemite 10.10.1, after using xcode-select --install to reinstall the command line developer tools

@DomT4

This comment has been minimized.

Show comment
Hide comment
@DomT4

DomT4 commented Dec 31, 2014

@DanielPHenry

This comment has been minimized.

Show comment
Hide comment
@DanielPHenry

DanielPHenry Jan 8, 2015

xcode-select --install fixed it for me. I did run xcode and allow it to update itself first but not sure if that was a factor.

DanielPHenry commented Jan 8, 2015

xcode-select --install fixed it for me. I did run xcode and allow it to update itself first but not sure if that was a factor.

@kainjow

This comment has been minimized.

Show comment
Hide comment
@kainjow

kainjow Jan 12, 2015

xcode-select --install did it for me too. I thought I had done that, but apparently didn't, as I was installing Xcode and several other things around the time I started poking around in brew. Maybe doctor should check for this?

kainjow commented Jan 12, 2015

xcode-select --install did it for me too. I thought I had done that, but apparently didn't, as I was installing Xcode and several other things around the time I started poking around in brew. Maybe doctor should check for this?

@josegonzalez

This comment has been minimized.

Show comment
Hide comment
@josegonzalez

josegonzalez Jan 12, 2015

Contributor

If you are having this issue, please ensure you:

  • Reinstalled Xcode
  • Called brew update
  • Ran xcode-select --install

This should be standard procedure after updating your OS X installation. Locking because at this point it's just a bunch of +1s :)

Contributor

josegonzalez commented Jan 12, 2015

If you are having this issue, please ensure you:

  • Reinstalled Xcode
  • Called brew update
  • Ran xcode-select --install

This should be standard procedure after updating your OS X installation. Locking because at this point it's just a bunch of +1s :)

@Homebrew Homebrew locked and limited conversation to collaborators Jan 12, 2015

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.