diff --git a/science/cdf/Makefile b/science/cdf/Makefile index f1b4b8b150c5..6b516cd72448 100644 --- a/science/cdf/Makefile +++ b/science/cdf/Makefile @@ -1,59 +1,69 @@ PORTNAME= cdf3 DISTVERSION= 3.9.1 +PORTREVISION= 1 CATEGORIES= science MASTER_SITES= https://spdf.gsfc.nasa.gov/pub/software/cdf/dist/cdf39_1/ DISTNAME= cdf${VER}-dist-cdf -DIST_SUBDIR= ${PORTNAME}-${PORTVERSION} +DIST_SUBDIR= ${PORTNAME}-${DISTVERSION} MAINTAINER= alven@FreeBSD.org COMMENT= Device independent view of the CDF data model WWW= https://cdf.gsfc.nasa.gov/ LICENSE= NASA-G LICENSE_NAME= NASA/Goddard Space Flight Center LICENSE_FILE= ${WRKSRC}/CDF_copyright.txt LICENSE_PERMS= dist-mirror dist-sell pkg-mirror pkg-sell auto-accept BUILD_DEPENDS= bash:shells/bash -USES= fortran ncurses gmake - +USES= fortran gmake ncurses USE_LDCONFIG= yes + +MAKE_ARGS+= OS=freebsd ENV=gnu all MAKE_FLAGS= INSTALLDIR=${STAGEDIR}${PREFIX} OS=freebsd ENV=gnu \ FORTRAN=yes FC_freebsd=${F77} MAKE_JOBS_UNSAFE= yes -TEST_TARGET= test # XXX: test segfaults +TEST_TARGET= test + +PIE_UNSAFE= yes -WRKSRC= ${WRKDIR}/cdf${VER}-dist SUB_FILES= pkg-message -VER= ${PORTVERSION:S/.//:S/./_/} -DEFS= B C K +WRKSRC= ${WRKDIR}/cdf${VER}-dist +PLIST_SUB= SOVERSION=${DISTVERSION} PORTDOCS= CDF_copyright.txt CHANGES.txt Release.notes Welcome.txt OPTIONS_DEFINE= DOCS EXAMPLES -MAKE_ARGS+= OS=freebsd ENV=gnu all +DEFS= B C K +VER= ${PORTVERSION:S/.//:S/./_/} .include .if ${FORTRAN_DEFAULT} != flang FFLAGS= -std=legacy .endif post-patch: .for def in ${DEFS} @${REINPLACE_CMD} -e 's||${PREFIX}|' \ ${WRKSRC}/src/definitions/definitions.${def} .endfor post-install: + ${SED} -i '' 's,${STAGEDIR},,g' ${STAGEDIR}${PREFIX}/bin/definitions.? + ${RM} -f ${STAGEDIR}${PREFIX}/CDFLeapSeconds.txt + cd ${STAGEDIR}${PREFIX} && \ + ${FIND} bin/* lib/* -executable -exec ${STRIP_CMD} {} \; + +post-install-DOCS-on: ${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${PORTDOCS:S|^|${WRKSRC}/|} ${STAGEDIR}${DOCSDIR} + +post-install-EXAMPLES-on: ${MKDIR} ${STAGEDIR}${EXAMPLESDIR} ${INSTALL_DATA} ${WRKSRC}/samples/* ${STAGEDIR}${EXAMPLESDIR} - ${SED} -i '' 's,${STAGEDIR},,g' ${STAGEDIR}${PREFIX}/bin/definitions.? - ${RM} -f ${STAGEDIR}${PREFIX}/CDFLeapSeconds.txt .include diff --git a/science/cdf/pkg-plist b/science/cdf/pkg-plist index 177ca8658467..24910333ac66 100644 --- a/science/cdf/pkg-plist +++ b/science/cdf/pkg-plist @@ -1,74 +1,74 @@ bin/cdfcompare bin/cdfconvert bin/cdfdir bin/cdfdump bin/cdfedit bin/cdfexport bin/cdfinquire bin/cdfirsdump bin/cdfleapsecondsinfo bin/cdfmerge bin/cdfstats bin/cdfvalidate bin/definitions.B bin/definitions.C bin/definitions.K bin/skeletoncdf bin/skeletontable include/cdf.h include/cdf.inc include/cdfconfig.h include/cdfdist.h include/cdflib.h include/cdflib64.h include/cdftools.h lib/cdf/help/cdf2skt.olh lib/cdf/help/cdf2sktj.olh lib/cdf/help/cdfbrow.ilh lib/cdf/help/cdfcmp.olh lib/cdf/help/cdfcmpj.olh lib/cdf/help/cdfcvt.olh lib/cdf/help/cdfcvtj.olh lib/cdf/help/cdfdirj.olh lib/cdf/help/cdfdump.olh lib/cdf/help/cdfdumpj.olh lib/cdf/help/cdfedit.ilh lib/cdf/help/cdfedit.olh lib/cdf/help/cdfeditj.olh lib/cdf/help/cdfinq.olh lib/cdf/help/cdfinqj.olh lib/cdf/help/cdfirsdump.olh lib/cdf/help/cdfirsdumpj.olh lib/cdf/help/cdfleaptableinfo.olh lib/cdf/help/cdfleaptableinfoj.olh lib/cdf/help/cdfmerge.olh lib/cdf/help/cdfmergej.olh lib/cdf/help/cdfstats.olh lib/cdf/help/cdfstatsj.olh lib/cdf/help/cdfvalidate.olh lib/cdf/help/cdfvalidatej.olh lib/cdf/help/cdfxp.ilh lib/cdf/help/skt2cdf.olh lib/cdf/help/skt2cdfj.olh -lib/libcdf.3.9.1.so lib/libcdf.a lib/libcdf.so +lib/libcdf.%%SOVERSION%%.so %%PORTEXAMPLES%%%%EXAMPLESDIR%%/OperateAttributes.c %%PORTEXAMPLES%%%%EXAMPLESDIR%%/OperateCDF.c %%PORTEXAMPLES%%%%EXAMPLESDIR%%/OperateVariables.c %%PORTEXAMPLES%%%%EXAMPLESDIR%%/cacsst2.cdf %%PORTEXAMPLES%%%%EXAMPLESDIR%%/cacsst2.skt %%PORTEXAMPLES%%%%EXAMPLESDIR%%/cdf.inc %%PORTEXAMPLES%%%%EXAMPLESDIR%%/d103a2x.cdf %%PORTEXAMPLES%%%%EXAMPLESDIR%%/example.dat %%PORTEXAMPLES%%%%EXAMPLESDIR%%/example1.c %%PORTEXAMPLES%%%%EXAMPLESDIR%%/example1.cdf %%PORTEXAMPLES%%%%EXAMPLESDIR%%/example2.cdf %%PORTEXAMPLES%%%%EXAMPLESDIR%%/example2.f %%PORTEXAMPLES%%%%EXAMPLESDIR%%/geocpi0.cdf %%PORTEXAMPLES%%%%EXAMPLESDIR%%/geocpi0.skt %%PORTEXAMPLES%%%%EXAMPLESDIR%%/geocpi1.cdf %%PORTEXAMPLES%%%%EXAMPLESDIR%%/geocpi2.cdf %%PORTEXAMPLES%%%%EXAMPLESDIR%%/ij01r39.cdf %%PORTEXAMPLES%%%%EXAMPLESDIR%%/read_example1.c %%PORTEXAMPLES%%%%EXAMPLESDIR%%/zfia10x.cdf