# $Id: Portfile 64737 2010-03-15 13:13:51Z nox@macports.org $

PortSystem 1.0
PortGroup  archcheck 1.0
PortGroup  muniversal 1.0

name		  libssh2
version		  1.2.4
categories	  devel net
platforms	  darwin
maintainers	  pmq openmaintainer

description	  libssh2 is a library implementing the SSH2 protocol
long_description  libssh2 is a library implementing the SSH2 protocol as \
		  defined by Internet Drafts: SECSH-TRANS(22), \
		  SECSH-USERAUTH(25), SECSH-CONNECTION(23), SECSH-ARCH(20), \
		  SECSH-FILEXFER(06), SECSH-DHGEX(04), and SECSH-NUMBERS(10).

license		  BSD

homepage	  http://www.libssh2.org/
master_sites	  ${homepage}download/ sourceforge

checksums     md5     4d65a66d5f232e5bb1d05b311e43d46d \
              sha1    dcc8a0b1352114b10db20bf895ecb9e7272de094 \
              rmd160  1ef203bd7399be1ef0f312cc4317edf766a0dc7f

depends_lib	  port:openssl port:zlib

archcheck.files \
    lib/libcrypto.dylib \
    lib/libz.dylib

configure.env-append	NM="/usr/bin/nm -p"

post-build {
    if {[variant_isset universal]} {
        foreach arch ${universal_archs_to_use} {
            reinplace "s|[muniversal_get_arch_flag ${arch}]||" \
                ${worksrcpath}-${arch}/libssh2.pc
        }
    }
}

livecheck.type  freshmeat
