1998-11-09 02:26:20 +01:00
|
|
|
# New ports collection makefile for: tidy
|
|
|
|
# Date created: 27 Oct 1998
|
|
|
|
# Whom: Abel Chow <achow@transoft.net>
|
|
|
|
#
|
1999-08-31 04:43:35 +02:00
|
|
|
# $FreeBSD$
|
1998-11-09 02:26:20 +01:00
|
|
|
#
|
|
|
|
|
2003-02-24 08:48:05 +01:00
|
|
|
PORTNAME?= tidy
|
2005-10-27 23:57:50 +02:00
|
|
|
PORTVERSION= 051026
|
1998-11-09 02:26:20 +01:00
|
|
|
CATEGORIES= www
|
2003-02-02 00:24:54 +01:00
|
|
|
MASTER_SITES= http://tidy.sourceforge.net/src/%SUBDIR%/ \
|
2003-07-22 12:04:59 +02:00
|
|
|
http://tidy.sourceforge.net/docs/:docs
|
2003-02-02 00:24:54 +01:00
|
|
|
MASTER_SITE_SUBDIR= . old
|
2003-02-24 08:48:05 +01:00
|
|
|
PKGNAMESUFFIX?= -devel
|
2003-02-02 00:24:54 +01:00
|
|
|
DISTNAME= tidy_src
|
1999-01-06 04:34:34 +01:00
|
|
|
EXTRACT_SUFX= .tgz
|
2003-02-02 00:24:54 +01:00
|
|
|
DISTFILES= ${DISTNAME}_${PORTVERSION}${EXTRACT_SUFX}
|
1998-11-09 02:26:20 +01:00
|
|
|
|
2004-06-05 00:25:15 +02:00
|
|
|
MAINTAINER?= thierry@FreeBSD.org
|
2003-02-24 08:48:05 +01:00
|
|
|
COMMENT?= Utility to clean up and pretty print HTML/XHTML/XML
|
1998-11-09 02:26:20 +01:00
|
|
|
|
2003-02-02 00:24:54 +01:00
|
|
|
WRKSRC= ${WRKDIR}/${PORTNAME}
|
2000-02-16 01:08:36 +01:00
|
|
|
|
2003-02-24 08:48:05 +01:00
|
|
|
.if !defined(WITH_SHLIB)
|
2003-02-02 00:24:54 +01:00
|
|
|
USE_GMAKE= yes
|
2005-04-20 22:58:16 +02:00
|
|
|
PLIST_SUB= SHLIB="@comment " NSHLIB=""
|
2003-02-24 08:48:05 +01:00
|
|
|
.else
|
2005-08-28 16:32:35 +02:00
|
|
|
USE_AUTOTOOLS= automake:15 autoconf:213 libtool:13
|
2003-02-24 08:48:05 +01:00
|
|
|
AUTOMAKE_ARGS+= -a -c --foreign
|
2005-08-28 16:32:35 +02:00
|
|
|
CONFIGURE_TARGET= --target=${MACHINE_ARCH}-portbld-freebsd${OSREL}
|
2003-02-24 08:48:05 +01:00
|
|
|
INSTALLS_SHLIB= yes
|
2005-04-20 22:58:16 +02:00
|
|
|
PLIST_SUB= SHLIB="" NSHLIB="@comment "
|
2003-02-24 08:48:05 +01:00
|
|
|
.endif
|
|
|
|
|
|
|
|
DESCR= ${.CURDIR}/pkg-descr
|
|
|
|
|
|
|
|
BIN2STRIP= tidy tab2space
|
1998-11-09 02:26:20 +01:00
|
|
|
|
2003-03-23 14:46:34 +01:00
|
|
|
.if !defined(WITH_SHLIB)
|
|
|
|
MAN1= tidy.1
|
|
|
|
.endif
|
1998-11-09 02:26:20 +01:00
|
|
|
|
2003-02-02 00:24:54 +01:00
|
|
|
.if !defined(NOPORTDOCS)
|
2005-04-20 22:58:16 +02:00
|
|
|
. if !defined(WITH_SHLIB)
|
|
|
|
BUILD_DEPENDS+= xsltproc:${PORTSDIR}/textproc/libxslt
|
|
|
|
ALL_TARGET= all doc
|
|
|
|
DOCFILES= quickref.html
|
|
|
|
. endif
|
2005-10-21 21:38:00 +02:00
|
|
|
DOCVER= 051020
|
2003-02-24 08:48:05 +01:00
|
|
|
DISTFILES+= tidy_docs_${DOCVER}${EXTRACT_SUFX}:docs
|
2005-04-20 22:58:16 +02:00
|
|
|
DOCFILES+= Overview.html checked_by_tidy.gif faq.html grid.gif pending.html \
|
|
|
|
release-notes.html tidy.css tidy.gif
|
2003-02-02 00:24:54 +01:00
|
|
|
.endif
|
|
|
|
|
2003-02-24 08:48:05 +01:00
|
|
|
post-patch:
|
|
|
|
.if !defined(WITH_SHLIB)
|
|
|
|
@${CP} ${WRKSRC}/build/gmake/Makefile ${WRKSRC}
|
|
|
|
.else
|
|
|
|
@${CP} -R -f ${WRKSRC}/build/gnuauto/* ${WRKSRC}
|
2003-08-18 08:19:18 +02:00
|
|
|
.endif
|
|
|
|
|
2005-11-19 07:02:20 +01:00
|
|
|
patch-autotools::
|
2003-08-18 08:19:18 +02:00
|
|
|
.if defined(WITH_SHLIB)
|
|
|
|
@(cd ${WRKSRC} \
|
|
|
|
&& ${LIBTOOLIZE} --force --copy \
|
|
|
|
&& ${ACLOCAL})
|
|
|
|
@(cd ${PATCH_WRKSRC}; \
|
2004-08-12 21:37:16 +02:00
|
|
|
for ltf in ${LIBTOOLFILES}; do \
|
|
|
|
${CP} $$ltf $$ltf.tmp; \
|
2004-07-01 19:06:41 +02:00
|
|
|
${SED} -e "s^\$$ac_aux_dir/ltconfig^${LTCONFIG}^g" \
|
|
|
|
-e "/^ltmain=/!s^\$$ac_aux_dir/ltmain.sh^${LIBTOOLFLAGS} ${LTMAIN}^g" \
|
2004-08-12 21:37:16 +02:00
|
|
|
$$ltf.tmp > $$ltf; \
|
2003-08-18 08:19:18 +02:00
|
|
|
done);
|
2003-02-24 08:48:05 +01:00
|
|
|
.endif
|
2003-02-19 01:43:41 +01:00
|
|
|
|
2003-02-02 00:24:54 +01:00
|
|
|
pre-install:
|
|
|
|
@if [ -f ${LOCALBASE}/bin/tidy ]; then \
|
|
|
|
${ECHO_MSG} "" ; \
|
2003-02-24 08:48:05 +01:00
|
|
|
${ECHO_MSG} "Conflict: another tidy has been found; please deinstall it." ; \
|
|
|
|
${ECHO_MSG} "(`pkg_info -W ${LOCALBASE}/bin/tidy`)" ; \
|
2003-02-02 00:24:54 +01:00
|
|
|
${ECHO_MSG} "" ; \
|
|
|
|
${FALSE} ; \
|
|
|
|
fi
|
|
|
|
|
|
|
|
post-install:
|
|
|
|
.for pgm in ${BIN2STRIP}
|
|
|
|
@${STRIP_CMD} ${PREFIX}/bin/${pgm}
|
|
|
|
.endfor
|
2003-02-24 08:48:05 +01:00
|
|
|
.if defined(WITH_SHLIB)
|
|
|
|
@${STRIP_CMD} ${PREFIX}/lib/libtidy-0.99.so.0
|
|
|
|
.endif
|
1998-11-09 02:26:20 +01:00
|
|
|
.if !defined(NOPORTDOCS)
|
1999-08-28 00:30:39 +02:00
|
|
|
@${ECHO_MSG} "===> Installing documentation for ${PKGNAME}"
|
2003-02-02 00:24:54 +01:00
|
|
|
@${MKDIR} ${DOCSDIR}/api
|
2004-08-12 21:37:16 +02:00
|
|
|
@${INSTALL_DATA} ${DOCFILES:S|^|${WRKSRC}/htmldoc/|} ${DOCSDIR}
|
|
|
|
@${INSTALL_DATA} ${WRKSRC}/htmldoc/api/* ${DOCSDIR}/api
|
2003-02-02 00:24:54 +01:00
|
|
|
@${ECHO_MSG} "===> Documentation installed in ${DOCSDIR}."
|
1998-11-09 02:26:20 +01:00
|
|
|
.endif
|
|
|
|
|
2005-06-08 18:48:11 +02:00
|
|
|
.include <bsd.port.mk>
|