Subject: Re: Building libssh2 for iPhone (almost works)

Re: Building libssh2 for iPhone (almost works)

From: Sachin Garg <schngrg_at_gmail.com>
Date: Fri, 29 Apr 2011 07:00:54 +0530

On Fri, Apr 29, 2011 at 4:53 AM, Dan Fandrich <dan_at_coneharvesters.com> wrote:
>
> On Fri, Apr 29, 2011 at 04:33:47AM +0530, Sachin Garg wrote:
> > I am trying to build libssh2 for use in iphone application, following the
> > guidlines on this page:
> [...]
> > make  all-am
> > /bin/sh ../libtool --tag=CC --mode=link gcc  -DLIBSSH2_DARWIN   -o libssh2.la
> > -rpath /pathToInstall/built/lib -version-info 1:1:0 -no-undefined
> > -export-symbols-regex '^libssh2_.*'  -lssl -lcrypto -lz channel.lo comp.lo
> > crypt.lo hostkey.lo kex.lo mac.lo misc.lo packet.lo publickey.lo scp.lo
> > session.lo sftp.lo userauth.lo transport.lo version.lo knownhost.lo agent.lo
> > openssl.lo libgcrypt.lo pem.lo keepalive.lo global.lo
> > libtool: link: link -dump -symbols  .libs/channel.o .libs/comp.o .libs/crypt.o
> > .libs/hostkey.o .libs/kex.o .libs/mac.o .libs/misc.o .libs/packet.o .libs/
> > publickey.o .libs/scp.o .libs/session.o .libs/sftp.o .libs/userauth.o .libs/
> > transport.o .libs/version.o .libs/knownhost.o .libs/agent.o .libs/openssl.o
> > .libs/libgcrypt.o .libs/pem.o .libs/keepalive.o .libs/global.o   |  | /usr/bin/
> > sed 's/.* //' | sort | uniq > .libs/libssh2.exp
> > ../libtool: eval: line 947: syntax error near unexpected token `|'
> > ../libtool: eval: line 947: `link -dump -symbols  .libs/channel.o .libs/comp.o
> > .libs/crypt.o .libs/hostkey.o .libs/kex.o .libs/mac.o .libs/misc.o .libs/
> > packet.o .libs/publickey.o .libs/scp.o .libs/session.o .libs/sftp.o .libs/
> > userauth.o .libs/transport.o .libs/version.o .libs/knownhost.o .libs/agent.o
> > .libs/openssl.o .libs/libgcrypt.o .libs/pem.o .libs/keepalive.o .libs/global.o
> >   |  | /usr/bin/sed 's/.* //' | sort | uniq > .libs/libssh2.exp'
> > make[2]: *** [libssh2.la] Error 1
> > make[1]: *** [all] Error 2
> > make: *** [all-recursive] Error 1
> >
> > How to fix this problem?
>
> This looks like problem with libtool. Try running ./buildconf before doing the
> configure (or at least "libtoolize --copy --automake --force") to use the
> libtool available on the host system, which has probably been customized for
> OS X and is at the very least a different version from what libssh has been
> packaged with.

I tried both these commands and then I get this error with make, (btw,
libtoolize is called glibtoolize on osx).

Making all in src
make all-am
/bin/sh ../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H
-I../include -I../src -DLIBSSH2_DARWIN -MT channel.lo -MD -MP -MF
.deps/channel.Tpo -c -o channel.lo channel.c
../libtool: line 796: X--tag=CC: command not found
../libtool: line 829: libtool: ignoring unknown tag : command not found
../libtool: line 796: X--mode=compile: command not found
../libtool: line 962: *** Warning: inferring the mode of operation is
deprecated.: command not found
../libtool: line 963: *** Future versions of Libtool will require
--mode=MODE be specified.: command not found
../libtool: line 1106: Xgcc: command not found
../libtool: line 1106: X-DHAVE_CONFIG_H: command not found
../libtool: line 1106: X-I../include: No such file or directory
../libtool: line 1106: X-I../src: No such file or directory
../libtool: line 1106: X-DLIBSSH2_DARWIN: command not found
../libtool: line 1106: X-MT: command not found
../libtool: line 1106: Xchannel.lo: command not found
../libtool: line 1106: X-MD: command not found
../libtool: line 1106: X-MP: command not found
../libtool: line 1106: X-MF: command not found
../libtool: line 1106: X.deps/channel.Tpo: No such file or directory
../libtool: line 1106: X-c: command not found
../libtool: line 1157: Xchannel.lo: command not found
../libtool: line 1162: libtool: compile: cannot determine name of
library object from `': command not found
make[2]: *** [channel.lo] Error 1
make[1]: *** [all] Error 2
make: *** [all-recursive] Error 1

SG

_______________________________________________
libssh2-devel http://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel
Received on 2011-04-29