2000-08-12 20:09:41 +00:00
|
|
|
# New ports collection makefile for: Ruby-Racc
|
|
|
|
# Date created: 7 Aug 2000
|
|
|
|
# Whom: Akinori MUSHA aka knu <knu@idaemons.org>
|
2000-08-07 08:20:31 +00:00
|
|
|
#
|
|
|
|
# $FreeBSD$
|
|
|
|
#
|
|
|
|
|
|
|
|
PORTNAME= racc
|
2001-01-26 06:20:55 +00:00
|
|
|
PORTVERSION= 1.3.6
|
2001-01-27 09:54:30 +00:00
|
|
|
PORTREVISION= 1
|
2000-08-16 12:21:24 +00:00
|
|
|
CATEGORIES= devel ruby
|
2000-08-07 08:20:31 +00:00
|
|
|
MASTER_SITES= http://www1.u-netsurf.ne.jp/~brew/mine/soft/
|
2000-09-07 07:23:43 +00:00
|
|
|
PKGNAMEPREFIX= ${RUBY_PKGNAMEPREFIX}
|
2000-08-08 16:08:31 +00:00
|
|
|
DIST_SUBDIR= ruby
|
2000-08-07 08:20:31 +00:00
|
|
|
|
|
|
|
MAINTAINER= knu@FreeBSD.org
|
|
|
|
|
2000-08-22 06:46:52 +00:00
|
|
|
.if !defined(RUNTIME)
|
2001-01-27 09:54:30 +00:00
|
|
|
RUN_DEPENDS= ${RUBY_SITELIBDIR}/racc/parser.rb:${PORTSDIR}/devel/ruby-racc-runtime \
|
|
|
|
${RUBY_SITELIBDIR}/strscan.rb:${PORTSDIR}/devel/ruby-strscan
|
|
|
|
.endif
|
2000-08-07 08:20:31 +00:00
|
|
|
|
2000-09-07 07:23:43 +00:00
|
|
|
USE_RUBY= yes
|
|
|
|
USE_RUBY_AMSTD= yes
|
|
|
|
USE_RUBY_SETUP= yes
|
2000-08-22 06:46:52 +00:00
|
|
|
|
2000-08-07 08:20:31 +00:00
|
|
|
DOCS_EN= changes.html command.html debug.html grammer.html \
|
2000-12-15 15:10:09 +00:00
|
|
|
index.html parser.html usage.html
|
2000-08-07 08:20:31 +00:00
|
|
|
DOCS_JA= changes.html command.html debug.html grammer.html \
|
|
|
|
index.html parser.html usage.html
|
2000-08-17 07:04:43 +00:00
|
|
|
EXAMPLES= calc-ja.y calc.y conflict.y lalr.y syntax.y yyerr.y
|
2000-08-07 08:20:31 +00:00
|
|
|
|
2000-09-07 07:23:43 +00:00
|
|
|
post-extract:
|
2000-12-21 19:12:40 +00:00
|
|
|
${PERL} -i -ne '/^amstd\b/ || /^strscan\b/ || print' ${WRKSRC}/lib/PATHCONV
|
|
|
|
${RM} -rf ${WRKSRC}/lib/amstd ${WRKSRC}/lib/strscan
|
2000-09-07 07:23:43 +00:00
|
|
|
.if defined(RUNTIME)
|
|
|
|
${PERL} -i -ne '/^racc\b/ || print' ${WRKSRC}/bin/PATHCONV
|
|
|
|
${RM} -rf ${WRKSRC}/bin/racc
|
2000-12-25 02:41:15 +00:00
|
|
|
${PERL} -i -ne '/^strscanso\b/ || print' ${WRKSRC}/ext/PATHCONV
|
|
|
|
${RM} -rf ${WRKSRC}/ext/strscanso
|
2000-09-07 07:23:43 +00:00
|
|
|
${PERL} -i -ne '/^racc\b/ || print' ${WRKSRC}/lib/PATHCONV
|
|
|
|
${RM} -rf ${WRKSRC}/lib/racc
|
|
|
|
.else
|
2000-12-25 02:41:15 +00:00
|
|
|
${RM} -rf ${WRKSRC}/ext
|
2000-09-07 07:23:43 +00:00
|
|
|
${PERL} -i -ne '/^raccrt\b/ || print' ${WRKSRC}/lib/PATHCONV
|
|
|
|
${RM} -rf ${WRKSRC}/lib/raccrt
|
|
|
|
.endif
|
|
|
|
|
2000-08-22 06:46:52 +00:00
|
|
|
.if !defined(RUNTIME)
|
2000-08-12 11:21:26 +00:00
|
|
|
post-patch:
|
|
|
|
${PERL} -i -pe '$$. == 1 && s,^#!\s*\S+,#!${RUBY},' \
|
|
|
|
${WRKSRC}/misc/racc2y \
|
|
|
|
${WRKSRC}/misc/y2racc
|
2000-08-22 06:46:52 +00:00
|
|
|
.endif
|
2000-08-12 11:21:26 +00:00
|
|
|
|
2000-08-07 08:20:31 +00:00
|
|
|
do-install:
|
2000-08-22 06:46:52 +00:00
|
|
|
.if defined(RUNTIME)
|
|
|
|
${MKDIR} ${RUBY_SITELIBDIR}/racc
|
|
|
|
${MKDIR} ${RUBY_SITEARCHLIBDIR}/racc
|
|
|
|
.else
|
2000-08-12 11:21:26 +00:00
|
|
|
${INSTALL_SCRIPT} ${WRKSRC}/bin/racc/racc \
|
|
|
|
${WRKSRC}/misc/racc2y ${WRKSRC}/misc/y2racc ${PREFIX}/bin/
|
2000-08-12 20:09:41 +00:00
|
|
|
.if !defined(NOPORTDOCS)
|
2000-09-07 07:23:43 +00:00
|
|
|
${MKDIR} ${RUBY_EXAMPLESDIR}/racc
|
2000-08-07 08:20:31 +00:00
|
|
|
.for f in ${EXAMPLES}
|
2000-09-07 07:23:43 +00:00
|
|
|
${INSTALL_DATA} ${WRKSRC}/sample/${f} ${RUBY_EXAMPLESDIR}/racc/
|
2000-08-07 08:20:31 +00:00
|
|
|
.endfor
|
2000-09-07 07:23:43 +00:00
|
|
|
${MKDIR} ${RUBY_DOCDIR}/racc/ja
|
2000-08-07 08:20:31 +00:00
|
|
|
.for f in ${DOCS_EN}
|
2000-09-07 07:23:43 +00:00
|
|
|
${INSTALL_DATA} ${WRKSRC}/doc.en/${f} ${RUBY_DOCDIR}/racc/
|
2000-08-07 08:20:31 +00:00
|
|
|
.endfor
|
|
|
|
.for f in ${DOCS_JA}
|
2000-09-07 07:23:43 +00:00
|
|
|
${INSTALL_DATA} ${WRKSRC}/doc.ja/${f} ${RUBY_DOCDIR}/racc/ja/
|
2000-08-07 08:20:31 +00:00
|
|
|
.endfor
|
|
|
|
.endif
|
2000-08-22 06:46:52 +00:00
|
|
|
.endif
|
2000-08-07 08:20:31 +00:00
|
|
|
|
2000-09-26 08:02:17 +00:00
|
|
|
.include <bsd.port.mk>
|