dsully / perl-crypt-openssl-x509

Perl interface to OpenSSL's X509 module.
Other
25 stars 33 forks source link

Installing on Mac with HomeBrew #57

Closed genio closed 4 years ago

genio commented 7 years ago

Crypt::OpenSSL::X509 refuses to install on Macs where OpenSSL is installed via homebrew.

brew install openssl
export LDFLAGS=-L/usr/local/opt/openssl/lib
export CPPFLAGS=-I/usr/local/opt/openssl/include
export PKG_CONFIG_PATH=/usr/local/opt/openssl/lib/pkgconfig
cpanm IO::Socket::SSL

Is generally the path taken in this circumstance, however, with Crypt::OpenSSL::X509, one must:

cpanm --look Crypt::OpenSSL::X509
vim Makefile.PL
 + inc '-I/usr/local/opt/openssl/include -I/usr/include/openssl -I/usr/local/include/ssl -I/usr/local/ssl/include';
 + libs '-L/usr/local/opt/openssl/lib -L/usr/lib -L/usr/local/lib -L/usr/local/ssl/lib -lcrypto';
perl Makefile.PL
make
make test
make install

Could you please alter the Makefile.PL to use the above ENV variables if they're set?

jonasbn commented 7 years ago

Hello,

This might have been addressed in the latest release 1.8.8, which contains a patch I made, could you please verify?

Have a nice weekend,

jonasbn

eserte commented 4 years ago

On MacOSX Mojave with openssl from homebrew I have to use the following CPAN.pm distroprefs file for successful installation: https://github.com/eserte/srezic-cpan-distroprefs/blob/e0d0843a0e28eb9d75ea762c32773e76a884161e/Crypt-OpenSSL-....yml#L8-L10 The highlighted sections is the args which have to be provided to "perl Makefile.PL".

jonasbn commented 4 years ago

I am closing this issue, since I regard it as fixed and original poster has not responded.