2013-07-28 09:46:15 +00:00
|
|
|
# Created by: Pedro Giffuni <giffunip@asme.org>
|
2006-03-15 10:36:29 +00:00
|
|
|
# $FreeBSD$
|
|
|
|
|
|
|
|
PORTNAME= fastcap
|
2011-03-31 16:20:14 +00:00
|
|
|
DISTVERSION= 2.0wr-011109
|
2006-03-15 10:36:29 +00:00
|
|
|
CATEGORIES= science cad
|
2011-03-31 16:20:14 +00:00
|
|
|
MASTER_SITES= http://www.wrcad.com/ftp/pub/ LOCAL/bf
|
2006-03-15 10:36:29 +00:00
|
|
|
|
2011-03-31 16:20:14 +00:00
|
|
|
MAINTAINER= bf@FreeBSD.org
|
2013-07-28 09:46:15 +00:00
|
|
|
COMMENT= Three-dimensional capacitance extraction program
|
2006-03-15 10:36:29 +00:00
|
|
|
|
|
|
|
HAS_CONFIGURE= yes
|
|
|
|
CONFIGURE_SCRIPT= config
|
2011-03-31 16:20:14 +00:00
|
|
|
WRKSRC = ${WRKDIR}/fastcap-2.0wr
|
2006-03-15 10:36:29 +00:00
|
|
|
|
|
|
|
BINFILES= busgen capgen cubegen fastcap pipedgen pyragen
|
|
|
|
|
2013-07-28 09:46:15 +00:00
|
|
|
OPTIONS_DEFINE= DOCS EXAMPLES
|
|
|
|
|
|
|
|
.include <bsd.port.options.mk>
|
|
|
|
|
2006-03-15 10:36:29 +00:00
|
|
|
post-patch:
|
|
|
|
@${REINPLACE_CMD} -e 's,TYPE=other,TYPE=4,' \
|
|
|
|
${WRKSRC}/config
|
2011-08-20 11:28:54 +00:00
|
|
|
@${REINPLACE_CMD} -Ee '/CFLAGS =/{s/=/+=/;s/-O[[:digit:]]*//;}' \
|
2006-03-15 10:36:29 +00:00
|
|
|
${WRKSRC}/src/Makefile.4
|
2013-07-28 09:46:15 +00:00
|
|
|
# Minimal changes to fix the Clang build (there should be a more thorough
|
|
|
|
# clean-up, to correct types of functions, remove implicit declarations, fix
|
|
|
|
# formatting, add missing returns, etc.)
|
2011-08-20 11:28:54 +00:00
|
|
|
@${REINPLACE_CMD} -E -e 's,^mul(Up|Down),void &,' \
|
|
|
|
${WRKSRC}/src/mulDo.c
|
|
|
|
@${REINPLACE_CMD} -e 's,^mulMatUp,void &,' \
|
|
|
|
${WRKSRC}/src/mulMats.c
|
|
|
|
@${REINPLACE_CMD} -e 's,^static getnbrs,static void getnbrs,' \
|
|
|
|
${WRKSRC}/src/mulSetup.c
|
2013-07-28 09:46:15 +00:00
|
|
|
# Change "cd foo ; $(MAKE)" into "$(MAKE) -C foo" to unbreak parallel builds
|
|
|
|
@${REINPLACE_CMD} -E 's,cd (.+) ; (\$$\(MAKE\)),\2 -C \1,' \
|
|
|
|
${WRKSRC}/Makefile
|
|
|
|
# Avoid clashing of generated temporary files, crucial for parallel builds
|
|
|
|
@${REINPLACE_CMD} -e 's,temp\.out,$$@.&,' ${WRKSRC}/src/Makefile*
|
2006-03-15 10:36:29 +00:00
|
|
|
|
|
|
|
do-install:
|
2014-02-21 05:29:59 +00:00
|
|
|
${INSTALL_PROGRAM} ${BINFILES:S,^,${WRKSRC}/bin/,} ${STAGEDIR}${PREFIX}/bin
|
|
|
|
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
|
|
|
|
${INSTALL_DATA} ${WRKSRC}/examples/* ${STAGEDIR}${EXAMPLESDIR}
|
|
|
|
@${MKDIR} ${STAGEDIR}${DOCSDIR}
|
|
|
|
${CAT} ${WRKSRC}/README ${WRKSRC}/README.mit > ${STAGEDIR}${DOCSDIR}/readme
|
|
|
|
${INSTALL_DATA} ${WRKSRC}/doc/*.ps ${STAGEDIR}${DOCSDIR}
|
|
|
|
${GZIP_CMD} ${STAGEDIR}${DOCSDIR}/*
|
2006-03-15 10:36:29 +00:00
|
|
|
|
|
|
|
.include <bsd.port.mk>
|