summaryrefslogtreecommitdiff
path: root/www/httrack/Makefile
blob: 69063d7a6dd6127258c7718c76039636de50bc4b (plain)
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
46
47
48
49
50
# New ports collection makefile for:	httrack
# Date created:		Sun Jun 17 10:28:52 CEST 2001
# Whom:			Dirk Froemberg <dirk@FreeBSD.org>
#
# $FreeBSD$
#

PORTNAME=	httrack
PORTVERSION=	3.43.9
PORTREVISION=	1
CATEGORIES=	www
MASTER_SITES=	http://www.httrack.com/ \
		LOCAL/sunpoet
DISTNAME=	${PORTNAME}-${PORTVERSION:C/.([0-9]*)$/-\1/}C

MAINTAINER=	sunpoet@FreeBSD.org
COMMENT=	Easy-to-use offline browser utility and website copier

CONFIGURE_ARGS=	--docdir="${DOCSDIR}"
USE_AUTOTOOLS=	libtool
USE_GMAKE=	yes
USE_LDCONFIG=	${PREFIX}/lib
WRKSRC=		${WRKDIR}/${PORTNAME}-${PORTVERSION}

MAN1=		htsserver.1 httrack.1 proxytrack.1 webhttrack.1

.if !defined(NOPORTDATA)
USE_LDCONFIG+=	${PREFIX}/lib/httrack
.endif

post-patch:
	@${REINPLACE_CMD} -e '/DEFAULT_CFLAGS=/ s|-O -g3 ||g' \
		-e 's|-lpthread|${PTHREAD_LIBS}|g' ${WRKSRC}/configure
	@${REINPLACE_CMD} -e '/ install-data-hook/D' ${WRKSRC}/html/Makefile.in
	@${REINPLACE_CMD} -e 's|/usr/share|${PREFIX}/share|' \
		${WRKSRC}/html/server/div/WebHTTrack.desktop \
		${WRKSRC}/html/server/div/WebHTTrack-Websites.desktop
.if defined(NOPORTDATA)
	@${REINPLACE_CMD} -E '/^SUBDIRS = / s/ (lang|libtest|templates)//g' ${WRKSRC}/Makefile.in
.endif
.if defined(NOPORTDOCS)
	@${REINPLACE_CMD} -e '/^SUBDIRS = / s| html||' ${WRKSRC}/Makefile.in
.endif

post-install:
.if !defined(NOPORTDOCS)
	@${INSTALL_DATA} ${WRKSRC}/html/httrack.css ${DOCSDIR}/html/httrack.css
.endif

.include <bsd.port.mk>