freebsd-ports/math/gri/Makefile
Muhammad Moinur Rahman 721e5776c9 Mk/**tex.mk: Convert bsd.tex.mk to USES=tex
- Update all the consumers to use USES=tex
- USE_TEX=yes is the old way of writing USES=tex which has been removed
  and replaced in all ports
- Almost all of the USE_TEX features remains unchanged
- Some consumers had the same variables defined both in the mk
  infrastructure and also in the ports which have been removed from the
  ports as those are redundant.

In case any of the consumers are failing to build please make sure that
the nexessary USES=tex is there. Unlike previous USE_TEX=yes will no
longer load the required VARS for tex and related dependencies.

Reviewed by:	portmgr
Approved by:	portmgr (blanket)
2022-12-19 08:44:58 -06:00

74 lines
1.9 KiB
Makefile

PORTNAME= gri
PORTVERSION= 2.12.23
PORTREVISION= 11
CATEGORIES= math
MASTER_SITES= SF
LICENSE= GPLv2
MAINTAINER= ports@FreeBSD.org
COMMENT= Extensible plotting language for producing scientific graphs
WWW= http://gri.sourceforge.net/
LIB_DEPENDS= libnetcdf.so:science/netcdf
USES= cpe gmake readline shebangfix makeinfo tex
SHEBANG_FILES= doc/examples/FEM.pl src/gri_merge src/gri_unpage
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --enable-FreeBSD
CPE_VENDOR= gri_project
CPPFLAGS+= -I${LOCALBASE}/include
LDFLAGS+= -L${LOCALBASE}/lib
INFO= gri
USE_TEX= formats:build dvipsk:build
PORTDOCS= *
PORTEXAMPLES= *
OPTIONS_DEFINE= DOCS EXAMPLES
.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MDOCS} || ${PORT_OPTIONS:MEXAMPLES}
USES+= magick:6,build
.endif
post-patch:
@${REINPLACE_CMD} -e \
'/^SUBDIRS/s|doc||' ${WRKSRC}/Makefile.in
@${REINPLACE_CMD} -e \
'/gzip/s|^|#| ; \
/EXAMPLES_DIR/s|^|#|' ${WRKSRC}/doc/Makefile.in
post-build:
.if ${PORT_OPTIONS:MDOCS} || ${PORT_OPTIONS:MEXAMPLES}
(cd ${WRKSRC}/doc && ${SETENV} ${MAKE_ENV} ${MAKE_CMD} ${MAKE_FLAGS} \
${MAKEFILE} ${MAKE_ARGS} ${ALL_TARGET})
.else
(cd ${WRKSRC}/doc && makeinfo gri.texi)
.endif
post-install:
.if ${PORT_OPTIONS:MDOCS}
(cd ${WRKSRC}/doc && ${SETENV} ${MAKE_ENV} ${MAKE_CMD} ${MAKE_FLAGS} \
${MAKEFILE} ${MAKE_ARGS} ${INSTALL_TARGET})
.else
${INSTALL_MAN} ${WRKSRC}/doc/gri-manpage.1 \
${STAGEDIR}${MANPREFIX}/man/man1/gri.1
${INSTALL_MAN} ${WRKSRC}/doc/gri_merge.1-skel \
${STAGEDIR}${MANPREFIX}/man/man1/gri_merge.1
${INSTALL_MAN} ${WRKSRC}/doc/gri_unpage.1-skel \
${STAGEDIR}${MANPREFIX}/man/man1/gri_unpage.1
${INSTALL_DATA} ${WRKSRC}/doc/gri.info* ${STAGEDIR}${PREFIX}/${INFO_PATH}
.endif
.if ${PORT_OPTIONS:MEXAMPLES}
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
(cd ${WRKSRC}/doc/examples && ${INSTALL_DATA} model* *.dat *.gri e*.ps \
${STAGEDIR}${EXAMPLESDIR})
(cd ${WRKSRC}/doc/examples \
&& ${INSTALL_SCRIPT} FEM.pl ${STAGEDIR}${EXAMPLESDIR})
.endif
.include <bsd.port.mk>