diff options
32 files changed, 102 insertions, 108 deletions
diff --git a/math/arpack++/Makefile b/math/arpack++/Makefile index 9a684ffa2b83..eb4e2f577b7a 100644 --- a/math/arpack++/Makefile +++ b/math/arpack++/Makefile @@ -41,23 +41,22 @@ USES= gmake DOCS= README doc/arpackpp.ps.gz doc/bugs.txt doc/structure.txt +OPTIONS_DEFINE= DOCS + post-patch: @${FIND} ${WRKSRC}/include -name "*.orig" -delete @${FIND} ${WRKSRC}/examples -name "*.orig" -delete -.if !defined(NOPORTDOCS) @${REINPLACE_CMD} -e "s|%%LOCALBASE%%|${LOCALBASE}|g" \ -e "s|%%PREFIX%%|${PREFIX}|" ${WRKSRC}/Makefile.inc @${FIND} ${WRKSRC}/examples -name Makefile | \ ${XARGS} ${REINPLACE_CMD} -e "s|../../../Makefile.inc|../../Makefile.inc|" \ -e 's|$$(ARPACKPP_DIR)/examples|${EXAMPLESDIR}|' -.endif do-install: @${MKDIR} ${STAGEDIR}${PREFIX}/include/ARPACK++ @for inc in `${LS} ${WRKSRC}/include` ; do \ ${INSTALL_DATA} ${WRKSRC}/include/$$inc ${STAGEDIR}${PREFIX}/include/ARPACK++; \ done -.if !defined(NOPORTDOCS) @${MKDIR} ${STAGEDIR}${DOCSDIR} .for doc in ${DOCS} @${INSTALL_DATA} ${WRKSRC}/${doc} ${STAGEDIR}${DOCSDIR} @@ -68,7 +67,6 @@ do-install: @${INSTALL_DATA} ${WRKSRC}/Makefile.inc ${STAGEDIR}${EXAMPLESDIR} @${CP} -R ${WRKSRC}/examples/* ${STAGEDIR}${EXAMPLESDIR} @${ECHO_MSG} "===> Examples installed in ${EXAMPLESDIR}." -.endif .if defined(MAINTAINER_MODE) test: install diff --git a/math/arpack/Makefile b/math/arpack/Makefile index bba5ee9ecef2..ebb838aaae2c 100644 --- a/math/arpack/Makefile +++ b/math/arpack/Makefile @@ -7,9 +7,6 @@ PORTREVISION= 12 CATEGORIES= math MASTER_SITES= http://www.caam.rice.edu/software/ARPACK/SRC/ DISTFILES= ${PORTNAME}${PORTVERSION}.tar.gz patch.tar.gz -.ifndef NOPORTDOCS -DISTFILES+= ug.ps.gz -.endif DIST_SUBDIR= arpack EXTRACT_ONLY= ${PORTNAME}${PORTVERSION}.tar.gz @@ -70,8 +67,14 @@ SVDTESTS= ssvd dsvd SYMTESTS= ssdrv1 ssdrv2 ssdrv3 ssdrv4 ssdrv5 ssdrv6 \ dsdrv1 dsdrv2 dsdrv3 dsdrv4 dsdrv5 dsdrv6 +OPTIONS_DEFINE= DOCS + .include <bsd.port.pre.mk> +.if ${PORT_OPTIONS:MDOCS} +DISTFILES+= ug.ps.gz +.endif + .if exists(${LOCALBASE}/lib/libatlas.so) WITH_BLAS?= atlas .else @@ -150,7 +153,7 @@ do-install: @${INSTALL_DATA} ${WRKSRC}/libarpack.a ${STAGEDIR}${PREFIX}/lib @${INSTALL_DATA} -s ${WRKSRC}_SHARED/libarpack.so.1 ${STAGEDIR}${PREFIX}/lib @${LN} -sf libarpack.so.1 ${STAGEDIR}${PREFIX}/lib/libarpack.so -.if !defined(NOPORTDOCS) +.if ${PORT_OPTIONS:MDOCS} @${MKDIR} ${STAGEDIR}${DOCSDIR} @${INSTALL_DATA} ${WRKSRC}/DOCUMENTS/ex-*.doc.gz ${STAGEDIR}${DOCSDIR} @${INSTALL_DATA} ${DISTDIR}/${DIST_SUBDIR}/ug.ps.gz ${STAGEDIR}${DOCSDIR} diff --git a/math/bamg/Makefile b/math/bamg/Makefile index bfe50e550054..8744cf2b4e23 100644 --- a/math/bamg/Makefile +++ b/math/bamg/Makefile @@ -28,6 +28,8 @@ INSTALL_TARGET= install-world BINS= bamg bamg-g cvmsh2 drawbdmesh EXDIRS= NACA012 quadloop square test +OPTIONS_DEFINE= DOCS EXAMPLES + .include <bsd.port.pre.mk> .pre-configure: @@ -42,16 +44,12 @@ post-install: .for bin in ${BINS} @${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/${bin} .endfor -.if !defined(NOPORTDOCS) @${MKDIR} ${STAGEDIR}${DOCSDIR} @${INSTALL_DATA} ${DISTDIR}/${PORTNAME}.pdf ${STAGEDIR}${DOCSDIR} -.endif -.if !defined(NOPORTEXAMPLES) .for exdir in ${EXDIRS} @${MKDIR} ${STAGEDIR}${EXAMPLESDIR}/${exdir} @${INSTALL_DATA} ${WRKSRC}/examples/${exdir}/* ${STAGEDIR}${EXAMPLESDIR}/${exdir} .endfor @${FIND} ${STAGEDIR}${EXAMPLESDIR} \( -name "*.pl" -or -name "*.sh" \) -exec ${CHMOD} a+x {} \; -.endif .include <bsd.port.post.mk> diff --git a/math/bargraph/Makefile b/math/bargraph/Makefile index 412f742bc2ef..54c94b29205d 100644 --- a/math/bargraph/Makefile +++ b/math/bargraph/Makefile @@ -22,17 +22,15 @@ NO_WRKSUBDIR= yes NO_BUILD= yes SHEBANG_FILES= bargraph.pl +OPTIONS_DEFINE= DOCS EXAMPLES + do-install: ${INSTALL_SCRIPT} ${WRKSRC}/bargraph.pl ${STAGEDIR}${PREFIX}/bin/bargraph post-install: -.if !defined(NOPORTDOCS) ${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_MAN} ${WRKSRC}/README ${STAGEDIR}${DOCSDIR} -.endif -.if !defined (NOPORTEXAMPLES) ${MKDIR} ${STAGEDIR}${EXAMPLESDIR} ${CP} ${WRKSRC}/samples/*.perf ${WRKSRC}/samples/*.png ${STAGEDIR}${EXAMPLESDIR} -.endif .include <bsd.port.mk> diff --git a/math/eukleides/Makefile b/math/eukleides/Makefile index 19731ba1b763..89edb70b8124 100644 --- a/math/eukleides/Makefile +++ b/math/eukleides/Makefile @@ -18,20 +18,18 @@ RUN_DEPENDS= pstoedit:${PORTSDIR}/graphics/pstoedit USE_TEX= latex USES= bison gettext iconv gmake tar:bzip2 -OPTIONS_DEFINE= DOCS +OPTIONS_DEFINE= DOCS EXAMPLES .include <bsd.port.options.mk> .if ${PORT_OPTIONS:MDOCS} USES+= makeinfo USE_TEX+= pdftex:build -PORTDOCS= de.pdf fr.pdf INFO= eukleides .endif -.ifndef NOPORTEXAMPLES +PORTDOCS= de.pdf fr.pdf PORTEXAMPLES= greenwich.euk sundial.euk vonkoch.euk -.endif post-patch: @${GREP} -lR "#!/bin/bash" ${WRKSRC} | ${XARGS} ${REINPLACE_CMD} -e \ @@ -45,19 +43,17 @@ post-patch: -e "s|%%DOCSDIR%%|${STAGEDIR}${DOCSDIR}|g" @${GREP} -lFR "gcc" ${WRKSRC} |${XARGS} ${REINPLACE_CMD} \ -e "s|gcc|${CC}|g" -.if defined(${PORT_OPTIONS:MDOCS}) +.if ${PORT_OPTIONS:MDOCS} @${REINPLACE_CMD} -e '/^install:/ s/install_doc//g' \ -e '/^all:/ s/doc//g' ${WRKSRC}/Makefile .endif -.ifdef NOPORTEXAMPLES +.if ${PORT_OPTIONS:MEXAMPLES} @${REINPLACE_CMD} -e 's/install_exm$$//g' ${WRKSRC}/Makefile .endif pre-install: -.ifndef NOPORTEXAMPLES ${MKDIR} ${STAGEDIR}${EXAMPLESDIR} -.endif post-install: for i in euktoeps euktopdf euktotex; do \ diff --git a/math/fxt/Makefile b/math/fxt/Makefile index ab821e469cdf..a65a21b141cc 100644 --- a/math/fxt/Makefile +++ b/math/fxt/Makefile @@ -15,7 +15,7 @@ WRKSRC= ${WRKDIR}/${PORTNAME} USES= gmake MAKEFILE= makefile -.include <bsd.port.pre.mk> +OPTIONS_DEFINE= DOCS EXAMPLES post-patch: @${REINPLACE_CMD} -E \ @@ -26,14 +26,10 @@ post-patch: @${REINPLACE_CMD} -e 's|sinl|sin|g' ${WRKSRC}/src/fht/hartleyshift.h post-install: -.if !defined(NOPORTDOCS) ${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${WRKSRC}/00*.txt ${STAGEDIR}${DOCSDIR}/ -.endif -.if !defined(NOPORTEXAMPLES) ${MKDIR} ${STAGEDIR}${EXAMPLESDIR} (cd ${WRKSRC}/demo && ${COPYTREE_SHARE} \* ${STAGEDIR}${EXAMPLESDIR}/) -.endif plist: @truncate -s0 pkg-plist @@ -68,4 +64,4 @@ plist: 's,^${DOCSDIR}(.*),%%PORTDOCS%%@dirrm %%DOCSDIR%%\1,' \ >> pkg-plist -.include <bsd.port.post.mk> +.include <bsd.port.mk> diff --git a/math/gnubc/Makefile b/math/gnubc/Makefile index d40c4e49bc94..c4a647f146de 100644 --- a/math/gnubc/Makefile +++ b/math/gnubc/Makefile @@ -25,12 +25,12 @@ PORTEXAMPLES= ckbook.b \ primes.b \ twins.b +OPTIONS_DEFINE= EXAMPLES + post-install: -.if !defined(NOPORTEXAMPLES) ${MKDIR} ${STAGEDIR}${EXAMPLESDIR} .for f in ${PORTEXAMPLES} ${INSTALL_DATA} ${WRKSRC}/Examples/${f} ${STAGEDIR}${EXAMPLESDIR} .endfor -.endif .include <bsd.port.mk> diff --git a/math/gretl/Makefile b/math/gretl/Makefile index 3b11956cee28..12aee5b6d75e 100644 --- a/math/gretl/Makefile +++ b/math/gretl/Makefile @@ -22,7 +22,7 @@ USES= fortran gmake pathfix pkgconfig WANT_GNOME= yes ALL_TARGET= # empty -CONFIGURE_ARGS = --enable-static --enable-shared --with-gmake \ +CONFIGURE_ARGS= --enable-static --enable-shared --with-gmake \ --disable-xdg-utils CONFIGURE_ENV= ac_cv_lib_dl_dlopen="" CPPFLAGS+= -I${LOCALBASE}/include @@ -31,9 +31,9 @@ CONFIGURE_ENV= LAPACK_LIBS="${LAPACK} ${BLAS}" MAN1= gretl.1 -OPTIONS_DEFINE = ATLAS GUI ODBC OPENMP R UNZIP +OPTIONS_DEFINE= ATLAS GUI ODBC OPENMP R UNZIP -ATLAS_DESC = Use ATLAS for BLAS and LAPACK +ATLAS_DESC= Use ATLAS for BLAS and LAPACK GUI_DESC= Graphical user interface and plugins R_DESC= libR support UNZIP_DESC= UnZip compression support via libgsf diff --git a/math/jama/Makefile b/math/jama/Makefile index c5d803aa779d..76ab1356a244 100644 --- a/math/jama/Makefile +++ b/math/jama/Makefile @@ -6,9 +6,6 @@ PORTVERSION= 1.2.5 CATEGORIES= math devel MASTER_SITES= http://math.nist.gov/tnt/ DISTNAME= ${PORTNAME}${PORTVERSION:S/.//g} -.ifndef NOPORTDOCS -DISTFILES=${DISTNAME}${EXTRACT_SUFX} jama102doc.zip -.endif DIST_SUBDIR= tnt EXTRACT_ONLY= @@ -21,6 +18,14 @@ RUN_DEPENDS= ${LOCALBASE}/include/tnt/tnt.h:${PORTSDIR}/devel/tnt USES= zip NO_BUILD= yes +OPTIONS_DEFINE= DOCS + +.include <bsd.port.options.mk> + +.if ${PORT_OPTIONS:MDOCS} +DISTFILES=${DISTNAME}${EXTRACT_SUFX} jama102doc.zip +.endif + do-install: ${MKDIR} ${STAGEDIR}${PREFIX}/include/tnt ${EXTRACT_CMD} ${EXTRACT_BEFORE_ARGS} ${DISTDIR}/${DIST_SUBDIR}/${DISTNAME}${EXTRACT_SUFX} \ diff --git a/math/lapack++/Makefile b/math/lapack++/Makefile index 14d789c7b22f..a37d1a30d243 100644 --- a/math/lapack++/Makefile +++ b/math/lapack++/Makefile @@ -9,10 +9,6 @@ MASTER_SITES= SF/lapackpp/lapackpp/${PORTVERSION} \ http://math.nist.gov/lapack++/:doc DISTNAME= lapackpp-${PORTVERSION} -.if !defined(NOPORTDOCS) -DISTFILES+= ${DISTNAME}${EXTRACT_SUFX} lapack++.ps.gz:doc lapackpp1_1.ps.gz:doc \ - lapackppman1_1.ps.gz:doc lapack++_install.ps.gz:doc -.endif DIST_SUBDIR= lapackpp EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX} @@ -21,8 +17,15 @@ COMMENT= Linear Algebra PACKage in C++, a wrapper for LAPACK USES= fortran gmake pathfix libtool +OPTIONS_DEFINE= DOCS + .include <bsd.port.pre.mk> +.if ${PORT_OPTIONS:MDOCS} +DISTFILES+= ${DISTNAME}${EXTRACT_SUFX} lapack++.ps.gz:doc lapackpp1_1.ps.gz:doc \ + lapackppman1_1.ps.gz:doc lapack++_install.ps.gz:doc +.endif + .if exists(${LOCALBASE}/lib/libatlas.so) && !defined(WITH_BLAS) WITH_ATLAS= yes .endif @@ -49,12 +52,10 @@ LAPACK_LIB= -L${LOCALBASE}/lib -llapack CONFIGURE_ARGS+= --with-blas="${BLAS_LIB}" --with-lapack="${LAPACK_LIB}" --disable-atlas --enable-static post-install: -.if !defined(NOPORTDOCS) @${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${DISTDIR}/${DIST_SUBDIR}/lapack++.ps.gz ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${DISTDIR}/${DIST_SUBDIR}/lapack++_install.ps.gz ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${DISTDIR}/${DIST_SUBDIR}/lapackpp1_1.ps.gz ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${DISTDIR}/${DIST_SUBDIR}/lapackppman1_1.ps.gz ${STAGEDIR}${DOCSDIR} -.endif .include <bsd.port.post.mk> diff --git a/math/libranlip/Makefile b/math/libranlip/Makefile index 3b083c7a6938..0cc28ccc6749 100644 --- a/math/libranlip/Makefile +++ b/math/libranlip/Makefile @@ -22,19 +22,15 @@ PORTDOCS= ranlip.ps PORTEXAMPLES= makefile ranliptest.cpp ranliptestproc.cpp TESTPROGS= static_example static_example2 static_example3 shared_example -.include <bsd.port.pre.mk> +OPTIONS_DEFINE= DOCS EXAMPLES post-install: -.if !defined(NOPORTDOCS) ${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_MAN} ${WRKSRC}/docs/ranlip.ps ${STAGEDIR}${DOCSDIR} -.endif -.if !defined(NOPORTEXAMPLES) ${MKDIR} ${STAGEDIR}${EXAMPLESDIR} .for _file in ${PORTEXAMPLES} ${INSTALL_DATA} ${WRKSRC}/examples/${_file} ${STAGEDIR}${EXAMPLESDIR} .endfor -.endif test: build @(cd ${WRKSRC}/examples; ${SETENV} ${MAKE_ENV} ${MAKE} ${_MAKE_JOBS} ${MAKE_ARGS} all) @@ -46,4 +42,4 @@ test: build BROKEN= fails to build .endif -.include <bsd.port.post.mk> +.include <bsd.port.mk> diff --git a/math/lll_spect/Makefile b/math/lll_spect/Makefile index 54fcec5ed2f6..961ca8e593a8 100644 --- a/math/lll_spect/Makefile +++ b/math/lll_spect/Makefile @@ -23,6 +23,8 @@ NO_WRKSUBDIR= yes CPPFLAGS+= -I${LOCALBASE}/include LDFLAGS+= -L${LOCALBASE}/lib +OPTIONS_DEFINE= EXAMPLES + post-extract: .for _file in lll_spect lll_search @${CP} ${_DISTDIR}/${_file}.C ${WRKDIR} @@ -38,10 +40,8 @@ do-install: .for _file in lll_spect lll_search ${INSTALL_PROGRAM} ${WRKDIR}/${_file} ${STAGEDIR}${PREFIX}/bin .endfor -.if !defined(NOPORTEXAMPLES) ${MKDIR} ${STAGEDIR}${EXAMPLESDIR} ${INSTALL_DATA} ${_DISTDIR}/examples.txt ${STAGEDIR}${EXAMPLESDIR} -.endif test: build @${WRKSRC}/lll_spect "${WRKSRC}/output_spect" 17 16907 2147483647 diff --git a/math/ltl/Makefile b/math/ltl/Makefile index f7300292b1c1..62286069af05 100644 --- a/math/ltl/Makefile +++ b/math/ltl/Makefile @@ -23,12 +23,12 @@ INSTALL_TARGET= install install-data distdir PORTDOCS= *.html +OPTIONS_DEFINE= DOCS + post-install: -.if !defined(NOPORTDOCS) ${MKDIR} ${STAGEDIR}${DOCSDIR} .for docs in ${PORTDOCS} ${INSTALL_DATA} ${WRKSRC}/doc/html/${docs} ${STAGEDIR}${DOCSDIR} .endfor -.endif .include <bsd.port.mk> diff --git a/math/metis-edf/Makefile b/math/metis-edf/Makefile index 04bb84577d2b..150ea29b02f3 100644 --- a/math/metis-edf/Makefile +++ b/math/metis-edf/Makefile @@ -20,6 +20,8 @@ WRKSRC= ${WRKDIR}/${PORTNAME:C|-edf||}-${PORTVERSION:R} DOCS= CHANGES Doc/manual.ps +OPTIONS_DEFINE= DOCS EXAMPLES + .include <bsd.port.pre.mk> .include "${.CURDIR}/../../french/aster/bsd.aster.mk" @@ -27,17 +29,13 @@ MACHINEARCH= ${ARCH} USE_LDCONFIG= yes post-install: -.if !defined(NOPORTDOCS) ${MKDIR} ${STAGEDIR}${DOCSDIR} . for df in ${DOCS} ${INSTALL_DATA} ${WRKSRC}/${df} ${STAGEDIR}${DOCSDIR} . endfor -.endif -.if !defined(NOPORTEXAMPLES) ${MKDIR} ${STAGEDIR}${EXAMPLESDIR} ${INSTALL_DATA} ${WRKSRC}/Graphs/* ${STAGEDIR}${EXAMPLESDIR} ${INSTALL_PROGRAM} ${WRKSRC}/Graphs/mtest ${STAGEDIR}${EXAMPLESDIR} -.endif regression-test: (cd ${WRKSRC}/Graphs && LD_LIBRARY_PATH=${WRKSRC} ./mtest 4elt.graph || ${TRUE}) diff --git a/math/mtl/Makefile b/math/mtl/Makefile index 7eace15b6409..953d149860d4 100644 --- a/math/mtl/Makefile +++ b/math/mtl/Makefile @@ -22,6 +22,8 @@ USES= perl5 USE_PERL5= build WRKSRC = ${WRKDIR}/${DISTNAME:R} +OPTIONS_DEFINE= EXAMPLES + post-patch: @${REINPLACE_CMD} -e '/gnu\*)/,/;;/{/CXX=/d; /CXX_OPTIMIZE_FLAGS=/d; \ s/CXXFLAGS="/&$$ac_cv_env_CXXFLAGS_value /; }' \ @@ -44,7 +46,6 @@ fulltest: build CXXFLAGS+= -fpermissive .endif -.if !defined(NOPORTEXAMPLES) PORTEXAMPLES= * post-install: diff --git a/math/mumps/Makefile b/math/mumps/Makefile index 5aaed3afc664..221a40afd2c4 100644 --- a/math/mumps/Makefile +++ b/math/mumps/Makefile @@ -51,6 +51,8 @@ MAKE_ENV+= ORDERINGSF=-Dmetis PLIST_SUB+= MUMPSVERSION=${PORTVERSION} +OPTIONS_DEFINE= DOCS EXAMPLES + .include <bsd.port.pre.mk> .if exists(${LOCALBASE}/lib/libatlas.so) && !defined(WITH_BLAS) @@ -120,13 +122,10 @@ do-install: .ifndef WITH_MPI ${INSTALL_DATA} ${WRKSRC}/libseq/libmpiseq.a ${STAGEDIR}${PREFIX}/lib .endif -.ifndef NOPORTDOCS ${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${WRKSRC}/doc/userguide_${PORTVERSION}.pdf ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${WRKSRC}/doc/userguide_${PORTVERSION}.ps ${STAGEDIR}${DOCSDIR} ${GZIP_CMD} ${STAGEDIR}${DOCSDIR}/userguide_${PORTVERSION}.ps -.endif -.ifndef NOPORTEXAMPLES ${MKDIR} ${STAGEDIR}${EXAMPLESDIR} . for ex in Makefile README *.c *.F input_simpletest_* ${INSTALL_DATA} ${WRKSRC}/examples/${ex} ${STAGEDIR}${EXAMPLESDIR} @@ -134,7 +133,6 @@ do-install: . for ex in c_example *simpletest ${INSTALL_PROGRAM} ${WRKSRC}/examples/${ex} ${STAGEDIR}${EXAMPLESDIR} . endfor -.endif regression-test: .if defined (WITH_MPI) && defined(MAINTAINER_MODE) diff --git a/math/naturalmath/Makefile b/math/naturalmath/Makefile index 13f79e7947e7..db8b2d5a9858 100644 --- a/math/naturalmath/Makefile +++ b/math/naturalmath/Makefile @@ -14,6 +14,8 @@ USE_TEX= latex:build dvipsk:build USES= shebangfix perl5 SHEBANG_FILES= naturalmath +OPTIONS_DEFINE= DOCS + do-build: (cd ${WRKSRC}; ./naturalmath tutor.nat; \ ${LOCALBASE}/bin/latex tutor; ${LOCALBASE}/bin/latex tutor; \ @@ -21,7 +23,6 @@ do-build: do-install: ${INSTALL_SCRIPT} ${WRKSRC}/naturalmath ${STAGEDIR}${PREFIX}/bin -.if !defined(NOPORTDOCS) @${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${WRKSRC}/install.html ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${WRKSRC}/tutor.nat ${STAGEDIR}${DOCSDIR} @@ -29,6 +30,5 @@ do-install: ${INSTALL_DATA} ${WRKSRC}/tutor.dvi ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${WRKSRC}/tutor.ps ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${WRKSRC}/naturalmath.cgi ${STAGEDIR}${DOCSDIR} -.endif .include <bsd.port.mk> diff --git a/math/ntl/Makefile b/math/ntl/Makefile index 150f2911d664..93031c860969 100644 --- a/math/ntl/Makefile +++ b/math/ntl/Makefile @@ -30,16 +30,16 @@ CFLAGS+= -fPIC WRKSRC= ${WRKDIR}/${DISTNAME}/src MAKEFILE= makefile +OPTIONS_DEFINE= DOCS + do-install: ${MKDIR} ${STAGEDIR}${PREFIX}/include/NTL ${INSTALL_DATA} ${WRKSRC}/../include/NTL/* ${STAGEDIR}${PREFIX}/include/NTL/ ${INSTALL_DATA} ${WRKSRC}/ntl.a ${STAGEDIR}${PREFIX}/lib/libntl.a post-install: -.if !defined(NOPORTDOCS) ${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${WRKSRC}/../doc/* ${STAGEDIR}${DOCSDIR} -.endif test: build @(cd ${WRKSRC}; ${SETENV} ${MAKE_ENV} ${MAKE} \ diff --git a/math/p5-Math-Currency/Makefile b/math/p5-Math-Currency/Makefile index eb0d73e42180..177e9467c37e 100644 --- a/math/p5-Math-Currency/Makefile +++ b/math/p5-Math-Currency/Makefile @@ -16,13 +16,13 @@ RUN_DEPENDS:= ${BUILD_DEPENDS} USES= perl5 USE_PERL5= modbuild -.if !defined(NOPORTDOCS) +OPTIONS_DEFINE= DOCS + PORTDOCS= Changes post-install: @${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${PORTDOCS:S|^|${WRKSRC}/|} ${STAGEDIR}${DOCSDIR} @${ECHO_MSG} "===> Documentation installed in ${DOCSDIR}." -.endif .include <bsd.port.mk> diff --git a/math/plman/Makefile b/math/plman/Makefile index f004b053cf75..f80ca3b76f15 100644 --- a/math/plman/Makefile +++ b/math/plman/Makefile @@ -27,6 +27,8 @@ WRKSRC= ${WRKDIR}/${PORTNAME} FIND_DATA= lib FIND_DOCS= docs +OPTIONS_DEFINE= DOCS + post-patch: for FILE in ${REPLACE_FILES}; do \ ${REINPLACE_CMD} -e "/%%DATADIR%%/s//${DATADIR:S/\//\\\//g}/g" $${FILE} ;\ @@ -36,9 +38,7 @@ do-install: ${INSTALL_SCRIPT} ${WRKSRC}/bin/${PORTNAME} ${STAGEDIR}${PREFIX}/bin/${PORTNAME} ${MKDIR} ${STAGEDIR}${DATADIR}/${FIND_DATA} cd ${WRKSRC} && ${FIND} ${FIND_DATA} -type f -exec ${INSTALL_DATA} {} ${STAGEDIR}${DATADIR}/{} \; -.if !defined(NOPORTDOCS) ${MKDIR} ${STAGEDIR}${DOCSDIR} cd ${WRKSRC}/${FIND_DOCS} && ${FIND} . -type f -exec ${INSTALL_DATA} {} ${STAGEDIR}${DOCSDIR}/{} \; -.endif .include <bsd.port.mk> diff --git a/math/qhull/Makefile b/math/qhull/Makefile index a3f4fe8542c2..207e7350cecb 100644 --- a/math/qhull/Makefile +++ b/math/qhull/Makefile @@ -17,11 +17,15 @@ WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION} CONFLICTS= qhull-1.0* afni-[0-9]* qhull5-* +OPTIONS_DEFINE= DOCS + post-patch: ${REINPLACE_CMD} -e 's#share/man/man#man/man#g' \ ${WRKSRC}/CMakeLists.txt -.if defined(NOPORTDOCS) +.include <bsd.port.options.mk> + +.if empty(PORT_OPTIONS:MDOCS) EXTRA_PATCHES= ${PATCHDIR}/extra-patch-CMakeLists.txt .endif diff --git a/math/qhull5/Makefile b/math/qhull5/Makefile index d94fe506348a..3e47d4588bd5 100644 --- a/math/qhull5/Makefile +++ b/math/qhull5/Makefile @@ -22,8 +22,12 @@ USES= libtool gmake USE_LDCONFIG= yes GNU_CONFIGURE= yes +OPTIONS_DEFINE= DOCS + +.include <bsd.port.options.mk> + pre-configure: -.if defined(NOPORTDOCS) +.if empty(PORT_OPTIONS:MDOCS) @${REINPLACE_CMD} -e "s|src html eg config|src config|" \ ${WRKSRC}/Makefile.in @${REINPLACE_CMD} -e "s|install-docDATA install-examplesDATA||" \ diff --git a/math/randlib/Makefile b/math/randlib/Makefile index 9e3adefaa10d..ca400f537b27 100644 --- a/math/randlib/Makefile +++ b/math/randlib/Makefile @@ -23,10 +23,10 @@ PLIST_FILES= include/randlib.h \ post-extract: ${CP} ${FILESDIR}/Makefile.lib ${WRKSRC}/Makefile +OPTIONS_DEFINE= DOCS + post-install: -.if !defined(NOPORTDOCS) @${MKDIR} ${STAGEDIR}${DOCSDIR} @${INSTALL_DATA} ${WRKDIR}/source/randlib.c/doc/* ${STAGEDIR}${DOCSDIR} -.endif .include <bsd.port.mk> diff --git a/math/rngstreams/Makefile b/math/rngstreams/Makefile index 89d1d2e4f0ce..6912b404d5a9 100644 --- a/math/rngstreams/Makefile +++ b/math/rngstreams/Makefile @@ -22,19 +22,17 @@ PLIST_FILES= lib/librngstreams.a \ PORTDOCS= rngstreams.txt PORTEXAMPLES= example1.c +OPTIONS_DEFINE= DOCS EXAMPLES + post-install: -.ifndef(NOPORTDOCS) @${MKDIR} ${STAGEDIR}${DOCSDIR} .for DD in ${PORTDOCS} @${INSTALL_DATA} ${WRKSRC}/doc/${DD} ${STAGEDIR}${DOCSDIR} .endfor -.endif -.ifndef(NOPORTEXAMPLES) @${MKDIR} ${STAGEDIR}${EXAMPLESDIR} .for EE in ${PORTEXAMPLES} @${INSTALL_DATA} ${WRKSRC}/examples/${EE} ${STAGEDIR}${EXAMPLESDIR} .endfor -.endif regression-test: build @(cd ${WRKSRC}; ${SETENV} ${MAKE_ENV} ${MAKE} ${MAKE_ARGS} check) diff --git a/math/spooles/Makefile b/math/spooles/Makefile index 65cffea48961..da293a7eebe1 100644 --- a/math/spooles/Makefile +++ b/math/spooles/Makefile @@ -11,11 +11,6 @@ PKGNAMESUFFIX= -mpich .endif DISTNAME= ${PORTNAME}.${PORTVERSION} EXTRACT_SUFX= .tgz -.ifndef NOPORTDOCS -DISTFILES+= ${DISTNAME}${EXTRACT_SUFX} AllInOne.ps.gz Eigen.ps.gz \ - Install.ps.gz LinSol.ps.gz Ordering.ps.gz \ - PP99.ps.gz ReferenceManual.ps.gz -.endif DIST_SUBDIR= spooles EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX} @@ -40,6 +35,12 @@ CONFLICTS= spooles-mpich-2* .include <bsd.port.pre.mk> +.if ${PORT_OPTIONS:MDOCS} +DISTFILES+= ${DISTNAME}${EXTRACT_SUFX} AllInOne.ps.gz Eigen.ps.gz \ + Install.ps.gz LinSol.ps.gz Ordering.ps.gz \ + PP99.ps.gz ReferenceManual.ps.gz +.endif + .if ${ARCH} == "sparc64" PICFLAG?= -fPIC .else @@ -48,6 +49,8 @@ PICFLAG?= -fpic .SILENT: +OPTIONS_DEFINE= DOCS + pre-everything:: .if !defined(WITH_MPI) ${ECHO_MSG} "make WITH_MPI=yes for mpich version" diff --git a/math/testu01/Makefile b/math/testu01/Makefile index b6bfae6aeba0..998beae1180d 100644 --- a/math/testu01/Makefile +++ b/math/testu01/Makefile @@ -26,19 +26,23 @@ CFLAGS+= -fPIC PLIST_SUB= PORTNAME="${PORTNAME}" CONFLICTS= emboss-[0-9]* +OPTIONS_DEFINE= DOCS EXAMPLES + +.include <bsd.port.options.mk> + post-patch: @${REINPLACE_CMD} -e 's|echo aout|echo elf|' ${WRKSRC}/configure @${REINPLACE_CMD} -e 's|return|& (0)|' ${WRKSRC}/testu01/fftc.c -.ifdef(NOPORTDOCS) +.if empty(PORT_OPTIONS:MDOCS) @${REINPLACE_CMD} -e '/^SUBDIRS \=/s/ doc / /' ${WRKSRC}/Makefile.in @${FIND} -X ${WRKSRC} -name 'Makefile.in' | ${XARGS} ${REINPLACE_CMD} \ -e '/^install-data-am\: /s/install-docDATA//' .endif -.ifdef(NOPORTEXAMPLES) +.if empty(PORT_OPTIONS:MEXAMPLES) @${REINPLACE_CMD} -e '/^SUBDIRS \=/s/ examples / /' ${WRKSRC}/Makefile.in .endif -.ifndef(NOPORTDOCS) +.if ${PORT_OPTIONS:MDOCS} post-install: @${MKDIR} ${STAGEDIR}${DOCSDIR} @${INSTALL_DATA} ${DISTDIR}/testu01.pdf ${STAGEDIR}${DOCSDIR} diff --git a/math/trlan/Makefile b/math/trlan/Makefile index 2e32b0f59467..6d78c99e757f 100644 --- a/math/trlan/Makefile +++ b/math/trlan/Makefile @@ -21,15 +21,12 @@ ALL_TARGET= lib PLIST_FILES= lib/libtrlan.a lib/libtrlan.so lib/libtrlan.so.1 +OPTIONS_DEFINE= DOCS EXAMPLES + .include <bsd.port.pre.mk> -.ifndef(NOPORTDOCS) PORTDOCS= trlan-ug.pdf -.endif - -.ifndef(NOPORTEXAMPLES) PORTEXAMPLES= Makefile README dense.f90 simple.f90 simple77.f simplec.c -.endif .if ${ARCH} == sparc64 PICFLAG= -fPIC @@ -66,15 +63,11 @@ do-build: do-install: @${INSTALL_DATA} ${WRKDIR}/libtrlan.* ${STAGEDIR}${PREFIX}/lib @${LN} -sf libtrlan.so.1 ${STAGEDIR}${PREFIX}/lib/libtrlan.so -.ifndef(NOPORTDOCS) @${MKDIR} ${STAGEDIR}${DOCSDIR} @${INSTALL_DATA} ${DISTDIR}/${PORTDOCS} ${STAGEDIR}${DOCSDIR} -.endif -.ifndef(NOPORTEXAMPLES) @${MKDIR} ${STAGEDIR}${EXAMPLESDIR} @cd ${WRKSRC}/examples/SUN && ${INSTALL_DATA} ${PORTEXAMPLES} \ ${STAGEDIR}${EXAMPLESDIR} -.endif .if defined(MAINTAINER_MODE) diff --git a/math/unuran/Makefile b/math/unuran/Makefile index 70f9c158ba5c..775858da23c9 100644 --- a/math/unuran/Makefile +++ b/math/unuran/Makefile @@ -26,17 +26,17 @@ USE_LDCONFIG= yes INFO= unuran PORTDOCS= unuran.pdf unuran.txt +OPTIONS_DEFINE= DOCS + post-patch: ${REINPLACE_CMD} -e '/UNURANFULLCHECK=true make check/s/make/${MAKE_CMD}/' \ ${WRKSRC}/Makefile.in -.ifndef(NOPORTDOCS) post-install: @${MKDIR} ${STAGEDIR}${DOCSDIR} .for DD in ${PORTDOCS} @${INSTALL_DATA} ${WRKSRC}/doc/${DD} ${STAGEDIR}${DOCSDIR} .endfor -.endif .ifdef(MAINTAINER_MODE) CONFIGURE_ARGS+= --enable-check-struct --enable-logging diff --git a/math/x12arima/Makefile b/math/x12arima/Makefile index 8c14d07f1471..ae3f4063b5c0 100644 --- a/math/x12arima/Makefile +++ b/math/x12arima/Makefile @@ -18,13 +18,17 @@ MAKEFILE= makefile.lnx PLIST_FILES= bin/x12a -.ifndef(NOPORTDOCS) || make(makesum) +OPTIONS_DEFINE= DOCS + +.include <bsd.port.options.mk> + +.if ${PORT_OPTIONS:MDOCS} || make(makesum) DISTFILES+= docsv03.tar.gz .endif -.ifndef(NOPORTDOCS) PORTDOCS= ReleaseNotesVersion03.pdf qref03unix.pdf x12adocV03.pdf +.if ${PORT_OPTIONS:MDOCS} post-install: @${MKDIR} ${STAGEDIR}${DOCSDIR} @(cd ${WRKSRC}/docs && ${INSTALL_MAN} ${PORTDOCS} ${STAGEDIR}${DOCSDIR}) diff --git a/math/xblas/Makefile b/math/xblas/Makefile index c67c84334411..f7f663fba1d1 100644 --- a/math/xblas/Makefile +++ b/math/xblas/Makefile @@ -20,7 +20,7 @@ HEADERS= blas_dense_proto.h blas_enum.h blas_extended.h \ blas_extended_private.h blas_extended_proto.h blas_fpu.h \ blas_malloc.h f2c-bridge.h MAKE_ENV= EXTRA_LIBS="-lm" LINKER="${CC}" M4="${M4}" RANLIB="${RANLIB}" -OPTIONS_DEFINE= SHARED STATIC +OPTIONS_DEFINE= SHARED STATIC DOCS OPTIONS_DEFAULT= SHARED SHARED_DESC= Build a shared library and PIC archive STATIC_DESC= Build a non-PIC archive @@ -45,9 +45,7 @@ PICFLAG= -fPIC PICFLAG= -fpic .endif -.ifndef(NOPORTDOCS) PORTDOCS= report.ps -.endif .if ${PORT_OPTIONS:MSHARED} PLIST_FILES+= lib/libxblas_pic.a lib/libxblas.so lib/libxblas.so.${SHLIB_MAJOR} @@ -97,7 +95,7 @@ do-install: .if ${PORT_OPTIONS:MSTATIC} @${INSTALL_DATA} ${WRKSRC}_STATIC/libxblas.a ${STAGEDIR}${PREFIX}/lib .endif -.ifndef(NOPORTDOCS) +.if ${PORT_OPTIONS:MDOCS} @${MKDIR} ${STAGEDIR}${DOCSDIR} @${INSTALL_DATA} ${WRKSRC}/doc/report.ps ${STAGEDIR}${DOCSDIR} .endif diff --git a/math/xgobi/Makefile b/math/xgobi/Makefile index d1a31ace37dd..0fce95fe0fa8 100644 --- a/math/xgobi/Makefile +++ b/math/xgobi/Makefile @@ -25,6 +25,8 @@ USE_XORG= xbitmaps xaw PROGRAMS= xgvis xgobi MANDIR= ${WRKSRC}/manpages +OPTIONS_DEFINE= DOCS + # The distfile is a shar file. It also does not extract cleanly. # 3 files extract to current directory so use post-extract to move # them to proper locations. @@ -46,7 +48,6 @@ do-install: ${INSTALL_MAN} ${MANDIR}/${file}.1 ${STAGEDIR}${PREFIX}/man/man1 .endfor ${INSTALL_DATA} ${WRKSRC}/XGobi.ex ${STAGEDIR}${PREFIX}/lib/X11/app-defaults -.if !defined(NOPORTDOCS) @${MKDIR} ${STAGEDIR}${EXAMPLESDIR} @ cd ${WRKSRC}; \ for dir in data_*; do \ @@ -56,6 +57,5 @@ do-install: ${INSTALL_DATA} $${file} ${STAGEDIR}${EXAMPLESDIR}/$${dir}; \ done \ done -.endif .include <bsd.port.mk> diff --git a/math/xplot/Makefile b/math/xplot/Makefile index ee00cf484d6e..8e031dbb3fcb 100644 --- a/math/xplot/Makefile +++ b/math/xplot/Makefile @@ -26,11 +26,9 @@ post-patch: post-install: ${LN} -sf tcpdump2xplot.pl ${STAGEDIR}${PREFIX}/bin/tcpdump2xplot -.if !defined(NOPORTDOCS) @${MKDIR} ${STAGEDIR}${DOCSDIR} .for doc in ${PORTDOCS} ${INSTALL_DATA} ${WRKSRC}/${doc} ${STAGEDIR}${DOCSDIR} .endfor -.endif .include <bsd.port.mk> |