Skip Menu |

This queue is for tickets about the Net-SSH2 CPAN distribution.

Report information
The Basics
Id: 107839
Status: resolved
Priority: 0/
Queue: Net-SSH2

People
Owner: Nobody in particular
Requestors: toshiro.biz [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: module does not install in Mac OS X
Date: Sat, 17 Oct 2015 17:00:29 -0300
To: bug-Net-SSH2 [...] rt.cpan.org
From: Toshiro Viera Stalker <toshiro.biz [...] gmail.com>
I have brew installed and did (following the README): brew install libssh2 When I try to compile I get the following: Skip blib/lib/Net/SSH2/PublicKey.pm (unchanged) Skip blib/lib/Net/SSH2/File.pm (unchanged) Skip blib/lib/Net/SSH2/KnownHosts.pm (unchanged) Skip blib/lib/Net/SSH2/Dir.pm (unchanged) Skip blib/lib/Net/SSH2.pm (unchanged) Skip blib/lib/Net/SSH2/Listener.pm (unchanged) Skip blib/lib/Net/SSH2/SFTP.pm (unchanged) Skip blib/lib/Net/SSH2/Channel.pm (unchanged) cc -c -I/usr/local/include -I. -arch i386 -arch x86_64 -g -pipe -fno-common -DPERL_DARWIN -fno-strict-aliasing -fstack-protector -Wno-deprecated-declarations -Os -DVERSION=\"0.56\" -DXS_VERSION=\"0.56\" "-I/System/Library/Perl/5.18/darwin-thread-multi-2level/CORE" SSH2.c SSH2.xs:30:10: fatal error: 'openssl/crypto.h' file not found #include <openssl/crypto.h> ^ 1 error generated.
On 2015-10-17 13:00:43, toshiro.biz@gmail.com wrote: Show quoted text
> I have brew installed and did (following the README): > > brew install libssh2 >
... Show quoted text
> SSH2.xs:30:10: fatal error: 'openssl/crypto.h' file not found > #include <openssl/crypto.h> > ^ > 1 error generated.
The Makefile.PL needs to specify a dependency on the required header files. (You can use Devel::CheckLib to specify that dependency.) Also, the documentation should mention this, so the OSX packagers can add a dependency for the openssl package. (The user can install this separately via macports or homebrew for now.)
Subject: Re: [rt.cpan.org #107839] module does not install in Mac OS X
Date: Sun, 18 Oct 2015 07:12:57 +0000 (UTC)
To: "bug-Net-SSH2 [...] rt.cpan.org" <bug-Net-SSH2 [...] rt.cpan.org>
From: Salvador Fandino <sfandino [...] yahoo.com>
Show quoted text
----- Original Message -----
> From: Toshiro Viera Stalker via RT <bug-Net-SSH2@rt.cpan.org> > To: > Cc: > Sent: Saturday, October 17, 2015 10:00 PM > Subject: [rt.cpan.org #107839] module does not install in Mac OS X
> I have brew installed and did (following the README): > > brew install libssh2 > > When I try to compile I get the following:
> SSH2.xs:30:10: fatal error: 'openssl/crypto.h' file not found > #include <openssl/crypto.h> > ^ > 1 error generated.
I known nothing about OS X and brew, but you would need to install openssl, including its header files. What it is unexpected is that libssh2 should be also depending on openssl.
Subject: Re: [rt.cpan.org #107839] module does not install in Mac OS X
Date: Sun, 18 Oct 2015 14:42:59 -0300
To: bug-Net-SSH2 [...] rt.cpan.org
From: Toshiro Viera Stalker <toshiro.biz [...] gmail.com>
Show quoted text
> El 18 oct. 2015, a las 03:29, Karen Etheridge via RT <bug-Net-SSH2@rt.cpan.org> escribió: > > <URL: https://rt.cpan.org/Ticket/Display.html?id=107839 > > > On 2015-10-17 13:00:43, toshiro.biz@gmail.com wrote:
>> I have brew installed and did (following the README): >> >> brew install libssh2 >>
> ... >
>> SSH2.xs:30:10: fatal error: 'openssl/crypto.h' file not found >> #include <openssl/crypto.h> >> ^ >> 1 error generated.
> > > The Makefile.PL needs to specify a dependency on the required header files. (You can use Devel::CheckLib to specify that dependency.) Also, the documentation should mention this, > so the OSX packagers can add a dependency for the openssl package. (The user can install this separately via macports or homebrew for now.)
OS X deprecates the usage of openssl in favor of it own libraries, so brew don’t install them very well. I’ve compiled the module with: brew install libgcrypto perl Makefile.PL gcrypto and it works, you should consider documenting this so it will be easier to install in OS X. Thanks
On Sun Oct 18 13:43:16 2015, toshiro.biz@gmail.com wrote: Show quoted text
>
> > El 18 oct. 2015, a las 03:29, Karen Etheridge via RT <bug-Net- > > SSH2@rt.cpan.org> escribió: > > > > <URL: https://rt.cpan.org/Ticket/Display.html?id=107839 > > > > > On 2015-10-17 13:00:43, toshiro.biz@gmail.com wrote:
> >> I have brew installed and did (following the README): > >> > >> brew install libssh2 > >>
> > ... > >
> >> SSH2.xs:30:10: fatal error: 'openssl/crypto.h' file not found > >> #include <openssl/crypto.h> > >> ^ > >> 1 error generated.
> > > > > > The Makefile.PL needs to specify a dependency on the required header > > files. (You can use Devel::CheckLib to specify that dependency.) > > Also, the documentation should mention this, > > so the OSX packagers can add a dependency for the openssl package. > > (The user can install this separately via macports or homebrew for > > now.)
> > > OS X deprecates the usage of openssl in favor of it own libraries, so > brew don’t install them very well. I’ve compiled the module with: > > brew install libgcrypto > > perl Makefile.PL gcrypto
You have to use the same crypto backend as for libssh2 (that in your case is openssl). IIRC, this may seem to work because Net::SSH2 only calls into the crypto backend directly when it is used with threads. In any case, Rafael Kitover has updated the installation procedure to automatically install the module dependencies in OS/X. You can try it installing the latest development version 0.57_01: https://metacpan.org/pod/release/SALVA/Net-SSH2-0.57_01/lib/Net/SSH2.pm Show quoted text
> > > and it works, you should consider documenting this so it will be > easier to install in OS X. Thanks