summaryrefslogtreecommitdiff
path: root/ftp/sftp/Makefile
blob: 6bfeb9da44f09423ec68c07985f8cac9131dd08b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# New ports collection makefile for:	sftp
# Date created:		30 December 1999
# Whom:			Cy Shubert <Cy.Shubert@uumail.gov.bc.ca>
#
# $FreeBSD$
#

PORTNAME=	sftp
PORTVERSION=	0.9.9
CATEGORIES=	ftp security
MASTER_SITES=	ftp://ftp.xbill.org/pub/sftp/old/ \
		http://www.komquats.com/distfiles/

MAINTAINER=	cy@FreeBSD.org

.include <bsd.port.pre.mk>

.if ${OSVERSION} < 400014
RUN_DEPENDS=	ssh:${PORTSDIR}/security/openssh
.endif

GNU_CONFIGURE=	yes

MAN1=		secftp.1

PLIST=		${WRKDIR}/.PLIST

do-install:
	${INSTALL_PROGRAM} ${WRKSRC}/sftp ${PREFIX}/bin/secftp
	${LN} -s ${PREFIX}/bin/secftp ${PREFIX}/bin/rsftp
	${INSTALL_PROGRAM} ${WRKSRC}/sftpserv ${PREFIX}/bin/sftpserv
	${INSTALL_MAN} ${WRKSRC}/sftp.1 ${PREFIX}/man/man1/secftp.1
	${CP} ${PKGDIR}/pkg-plist.in ${PLIST}.unsorted
	@if [ ! -f ${PREFIX}/bin/sftp ]; then \
		${ECHO} "No other sftp found, linking sftp to secftp"; \
		${LN} -s ${PREFIX}/bin/secftp ${PREFIX}/bin/sftp; \
		${LN} -s ${PREFIX}/man/man1/secftp.1.gz ${PREFIX}/man/man1/sftp.1.gz; \
		${ECHO_CMD} bin/sftp >> ${PLIST}.unsorted; \
		${ECHO_CMD} man/man1/sftp.1.gz >> ${PLIST}.unsorted; \
	else \
		${ECHO} "Other sftp found, not linking sftp to secftp"; \
	fi
	@sort -u ${PLIST}.unsorted > ${PLIST}

.include <bsd.port.post.mk>