# Created by: Ryan Steinmetz <zi@FreeBSD.org>
# $FreeBSD: head/net/mosh/Makefile 459824 2018-01-24 09:41:04Z ak $

PORTNAME=	mosh
PORTVERSION=	1.3.2
PORTREVISION=	2
CATEGORIES=	net
MASTER_SITES=	http://mosh.mit.edu/ \
		ZI

MAINTAINER=	zi@FreeBSD.org
COMMENT=	Mobile terminal that supports intermittent connectivity

LICENSE=	GPLv3

LIB_DEPENDS=	libprotobuf.so:devel/protobuf

BROKEN_powerpc64=	fails to compile: metadata_lite.h: class 'google::protobuf::internal::InternalMetadataWithArenaLite' does not have any field named 'InternalMetadataWithArenaBase'

USE_PERL5=	run
GNU_CONFIGURE=	yes
CONFIGURE_ARGS=	--with-utempter --without-ncurses
CONFIGURE_ENV+=	CRYPTO_CFLAGS="-I${OPENSSLINC}" CRYPTO_LIBS="-L${OPENSSLLIB} -lssl -lcrypto" \
		TINFO_CFLAGS="-I/usr/include"
INSTALL_TARGET=	install-strip
USES=		autoreconf ncurses perl5 pkgconfig ssl

CONFLICTS_INSTALL=	mosh-0.[2-9].*

PLIST_FILES=	bin/mosh bin/mosh-server bin/mosh-client \
		man/man1/mosh-client.1.gz man/man1/mosh-server.1.gz man/man1/mosh.1.gz

.include <bsd.port.mk>
