mirror of
https://git.FreeBSD.org/ports.git
synced 2024-12-18 03:46:03 +00:00
Update to version 4.1r3.
PR: 14717 Submitted by: maintainer
This commit is contained in:
parent
5cc3910e94
commit
b0628da359
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=23083
@ -6,63 +6,32 @@
|
||||
# $FreeBSD$
|
||||
#
|
||||
|
||||
DISTNAME= HDF4.1r2
|
||||
PKGNAME= hdf-4.1r2
|
||||
DISTNAME= HDF4.1r3
|
||||
PKGNAME= hdf-4.1r3
|
||||
CATEGORIES= graphics
|
||||
MASTER_SITES= ftp://ftp.ncsa.uiuc.edu/HDF/HDF4.1r2/tar/
|
||||
MASTER_SITES= ftp://ftp.ncsa.uiuc.edu/HDF/HDF/HDF4.1r3/tar/
|
||||
|
||||
MAINTAINER= mi@aldan.algebra.com
|
||||
|
||||
LIB_DEPENDS= jpeg.9:${PORTSDIR}/graphics/jpeg
|
||||
|
||||
MAN1= hdf.1 hdfunpac.1 ncdump.1 ncgen.1
|
||||
MAN3= gr_chunk.3
|
||||
MANCOMPRESSED= maybe
|
||||
|
||||
GNU_CONFIGURE= yes
|
||||
FC?= f77 # Can also be g77 for the newer one
|
||||
MAKE_FLAGS= CC="$(CC)" FC="${FC}" -f
|
||||
MAKE_ENV= pwrkdir=${WRKDIR}
|
||||
#"wrkdir" doesn't work for some reason in the above
|
||||
MAKE_ARGS= PREFIX="${PREFIX}" -j 2
|
||||
|
||||
# This will create dummy Makefiles and some links in the jpeg and libz
|
||||
# subdirectories. This way, we do not need to hunt all the dependencies
|
||||
# out. Shame on the lib's developers, though, this can not be done through
|
||||
# `configure'. -mi
|
||||
pre-build:
|
||||
${AR} -r ${WRKDIR}/libz.a /dev/null
|
||||
${RANLIB} ${WRKDIR}/libz.a
|
||||
test -d ${WRKSRC}/hdf/jpeg.came-with-HDF || \
|
||||
${MV} -f ${WRKSRC}/hdf/jpeg ${WRKSRC}/hdf/jpeg.came-with-HDF
|
||||
-${MKDIR} ${WRKSRC}/hdf/jpeg
|
||||
${RM} -f ${WRKSRC}/hdf/jpeg/Makefile
|
||||
${ECHO} #Phony makefile > ${WRKSRC}/hdf/jpeg/Makefile
|
||||
${ECHO} >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
${ECHO} libjpeg.a: >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\t@${ECHO} Using the already installed JPEG library\n' \
|
||||
>> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\nclean:\n\ttrue\n' >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\ninstall-lib:\n\ttrue\n' >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\ninstall:\n\ttrue\n' >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
-${LN} -s ${PREFIX}/lib/libjpeg* ${WRKSRC}/hdf/jpeg/
|
||||
-${LN} -s ${PREFIX}/include/j*.h ${WRKSRC}/hdf/jpeg/
|
||||
test -d ${WRKSRC}/hdf/zlib.came-with-HDF || \
|
||||
${MV} -f ${WRKSRC}/hdf/zlib ${WRKSRC}/hdf/zlib.came-with-HDF
|
||||
-${MKDIR} ${WRKSRC}/hdf/zlib
|
||||
${RM} -f ${WRKSRC}/hdf/zlib/Makefile
|
||||
${ECHO} #Phony makefile > ${WRKSRC}/hdf/zlib/Makefile
|
||||
${ECHO} >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
${ECHO} libzlib.a: >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\t@${ECHO} Using the already installed ZLIB library\n' \
|
||||
>> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\nclean:\n\ttrue\n' >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\ninstall-lib:\n\ttrue\n' >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\ninstall:\n\ttrue\n' >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
-${LN} -s /usr/lib/${BINFORMAT}/libz* ${WRKSRC}/hdf/zlib/
|
||||
-${LN} -s /usr/include/zconf.h /usr/include/zlib.h ${WRKSRC}/hdf/zlib/
|
||||
post-patch:
|
||||
${RM} -rf ${WRKSRC}/hdf/jpeg
|
||||
${RM} -rf ${WRKSRC}/hdf/zlib
|
||||
|
||||
post-install:
|
||||
@for binary in `${GREP} ^bin/ ${PLIST}` ; do strip ${PREFIX}/$$binary; done
|
||||
do-configure:
|
||||
${CP} -rp ${FILESDIR}/Makefile ${FILESDIR}/hdf \
|
||||
${FILESDIR}/mfhdf ${FILESDIR}/man ${WRKSRC}
|
||||
${LN} -s config/netcdf-fbsd.h ${WRKSRC}/mfhdf/libsrc/netcdf.h
|
||||
${LN} -s netcdf-fbsd.inc ${WRKSRC}/mfhdf/fortran/config/netcdf.inc
|
||||
|
||||
test:
|
||||
cd ${WRKSRC}; make ${MAKE_FLAGS} ${MAKEFILE} test
|
||||
test: build
|
||||
cd ${WRKSRC}; ${MAKE} test
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
@ -1 +1 @@
|
||||
MD5 (HDF4.1r2.tar.gz) = 52814865529791e3a39637fd851a7143
|
||||
MD5 (HDF4.1r3.tar.gz) = 975f84ad8c5910841995c9d339fbd8bb
|
||||
|
16
graphics/hdf/files/Makefile
Normal file
16
graphics/hdf/files/Makefile
Normal file
@ -0,0 +1,16 @@
|
||||
# $FreeBSD$
|
||||
|
||||
SUBDIR = hdf mfhdf man
|
||||
#PREFIX ?= /usr/local
|
||||
LIBDIR ?= ${PREFIX}/lib
|
||||
BINDIR ?= ${PREFIX}/bin
|
||||
|
||||
.MAKEFLAGS: PREFIX=${PREFIX} LIBDIR=${LIBDIR} BINDIR=${BINDIR}
|
||||
|
||||
test: all
|
||||
# testing in hdf
|
||||
@cd hdf && ${MAKE} hdf-test
|
||||
# testing in mfhdf
|
||||
@cd mfhdf && ${MAKE} test
|
||||
|
||||
.include <bsd.subdir.mk>
|
9
graphics/hdf/files/hdf/Makefile
Normal file
9
graphics/hdf/files/hdf/Makefile
Normal file
@ -0,0 +1,9 @@
|
||||
# $FreeBSD$
|
||||
|
||||
SUBDIR = src util test
|
||||
|
||||
hdf-test: all
|
||||
cd util && ${MAKE} test
|
||||
cd test && ${MAKE} test
|
||||
|
||||
.include <bsd.subdir.mk>
|
54
graphics/hdf/files/hdf/src/Makefile
Normal file
54
graphics/hdf/files/hdf/src/Makefile
Normal file
@ -0,0 +1,54 @@
|
||||
# $FreeBSD$
|
||||
|
||||
LIB=df
|
||||
|
||||
# uncomment the line below to avoid building static libraries
|
||||
#INTERNALLIB=YES
|
||||
LIBDIR=${PREFIX}/lib
|
||||
|
||||
SHLIB_MAJOR=1
|
||||
SHLIB_MINOR=0
|
||||
|
||||
SRCS=atom.c bitvect.c cdeflate.c cnbit.c cnone.c crle.c cskphuff.c \
|
||||
df24.c df24f.c dfan.c dfanf.c dfcomp.c dfconv.c dff.c dfgr.c \
|
||||
dfgroup.c dfimcomp.c dfjpeg.c dfkconv.c dfkcray.c dfkfuji.c \
|
||||
dfknat.c dfkswap.c dfkvms.c dfp.c dfpf.c dfr8.c dfr8f.c dfrle.c \
|
||||
dfsd.c dfsdf.c dfstubs.c dfufp2i.c dfunjpeg.c dfutil.c dfutilf.c \
|
||||
dir_mac.c dynarray.c glist.c hbitio.c hblocks.c hbuffer.c \
|
||||
hchunks.c hcomp.c hcompri.c hdfalloc.c herr.c herrf.c hextelt.c \
|
||||
hfile.c hfiledd.c hfilef.c hkit.c linklist.c mcache.c \
|
||||
mfan.c mfanf.c mfgr.c mfgrf.c mstdio.c tbbt.c vattr.c vattrf.c \
|
||||
vconv.c vg.c vgf.c vgp.c vhi.c vio.c vparse.c vrw.c vsfld.c \
|
||||
df24ff.f dfanff.f dfff.f dfpff.f dfr8ff.f dfsdff.f dfufp2if.f \
|
||||
hfileff.f mfgrff.f vattrff.f vgff.f
|
||||
|
||||
CFLAGS += -I${PREFIX}/include
|
||||
FFLAGS += ${CFLAGS}
|
||||
|
||||
.if !defined(OSVERSION)
|
||||
.if exists(/sbin/sysctl)
|
||||
OSVERSION!= /sbin/sysctl -n kern.osreldate
|
||||
.else
|
||||
OSVERSION!= /usr/sbin/sysctl -n kern.osreldate
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if ${OSVERSION} >= 400004
|
||||
LDADD += -L${PREFIX}/lib -ljpeg -lg2c -lz -lm
|
||||
.else
|
||||
LDADD += -L${PREFIX}/lib -ljpeg -lf2c -lz
|
||||
.endif
|
||||
|
||||
afterinstall:
|
||||
install -c -o root -g wheel -m 444 \
|
||||
atom.h bitvect.h cdeflate.h cnbit.h cnone.h crle.h \
|
||||
cskphuff.h df.h dfan.h dfconvrt.h dfgr.h dfi.h dfivms.h \
|
||||
dfrig.h dfsd.h dfstubs.h dfufp2i.h dir_mac.h dynarray.h \
|
||||
glist.h hbitio.h hchunks.h hcomp.h hcompi.h hconv.h \
|
||||
hdf.h hdfi.h herr.h hfile.h hkit.h hlimits.h hntdefs.h \
|
||||
hproto.h hqueue.h htags.h linklist.h maldebug.h mcache.h \
|
||||
mfan.h mfgr.h mstdio.h patchlevel.h sys_dir_mac.h tbbt.h \
|
||||
trace.h vattr.h vg.h vgint.h hdf.inc dffunc.inc \
|
||||
${PREFIX}/include
|
||||
|
||||
.include <bsd.lib.mk>
|
68
graphics/hdf/files/hdf/test/Makefile
Normal file
68
graphics/hdf/files/hdf/test/Makefile
Normal file
@ -0,0 +1,68 @@
|
||||
# $FreeBSD$
|
||||
|
||||
CSRCS= rig.c sdstr.c blocks.c an.c anfile.c extelt.c file.c file1.c vers.c \
|
||||
sdmms.c sdnmms.c slab.c litend.c tvset.c comp.c bitio.c tree.c macros.c \
|
||||
conv.c nbit.c man.c mgr.c testhdf.c tbv.c tvsfpack.c chunks.c tvattr.c \
|
||||
buffer.c
|
||||
|
||||
COBJS= ${CSRCS:S/.c/.o/g}
|
||||
|
||||
FSRCS= fortest.c fortestF.f forsupff.f forsupf.c \
|
||||
manf.f mgrf.f slabwf.f t24f.f tanf.f tanfilef.f tpf.f tr8f.f \
|
||||
tsdmmsf.f tsdnmmsf.f tsdnntf.f tsdntf.f tsdstrf.f tstubsf.f \
|
||||
tvsetf.f, tvattrf.f
|
||||
|
||||
FOBJS = fortestF.o forsupff.o forsupf.o \
|
||||
manf.o mgrf.o slabwf.o t24f.o tanf.o tanfilef.o tpf.o tr8f.o \
|
||||
tsdmmsf.o tsdnmmsf.o tsdnntf.o tsdntf.o tsdstrf.o tstubsf.o \
|
||||
tvsetf.o tvattrf.o
|
||||
|
||||
#CFORSUPSRCS = forsupf.c
|
||||
|
||||
HDFLIB = ${.CURDIR}/../src
|
||||
CFLAGS += -I${HDFLIB}
|
||||
FFLAGS += ${CFLAGS} -Nn802 -Nx400
|
||||
|
||||
FTESTS = fortest fortestF
|
||||
|
||||
all: testhdf $(FTESTS) gentest
|
||||
|
||||
#CFORSUPOBJS = forsupf.o
|
||||
|
||||
TESTF = fortest.o
|
||||
|
||||
# directory used by extelt test.
|
||||
TESTDIR = testdir
|
||||
|
||||
$(FOBJS): fortest.inc
|
||||
|
||||
test: atest-hdf
|
||||
|
||||
atest-hdf: testhdf $(FTESTS)
|
||||
-rm -f *.hdf
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../src ./testhdf
|
||||
-rm -f *.hdf
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../src ./fortest
|
||||
|
||||
testhdf: $(COBJS) $(HDFLIB)/libdf.so
|
||||
$(CC) -o testhdf $(COBJS) $(HDFLIB)/libdf.so -lm
|
||||
test -d $(TESTDIR) || mkdir $(TESTDIR)
|
||||
|
||||
fortestF: $(FOBJS) $(HDFLIB)/libdf.so
|
||||
$(FC) $(FFLAGS) -o $@ $(FOBJS) $(HDFLIB)/libdf.so -lm
|
||||
|
||||
fortest: $(HDFLIB)/libdf.so fortest.c $(CHDRS)
|
||||
$(CC) $(CFLAGS) -o fortest fortest.c $(HDFLIB)/libdf.so -lm
|
||||
|
||||
gentest: gentest.c $(HDFLIB)/libdf.so
|
||||
$(CC) $(CFLAGS) gentest.c -o gentest $(HDFLIB)/libdf.so -lm
|
||||
|
||||
clean:
|
||||
-rm -f $(COBJS) testhdf $(FOBJS) $(FTESTS) \
|
||||
core *.hdf ptesthdf qtesthdf gentest *.o fortest.arg $(TESTDIR)/* \
|
||||
.depend
|
||||
|
||||
depend:
|
||||
mkdep ${CFLAGS} ${CSRCS}
|
||||
|
||||
install:
|
30
graphics/hdf/files/hdf/util/Makefile
Normal file
30
graphics/hdf/files/hdf/util/Makefile
Normal file
@ -0,0 +1,30 @@
|
||||
# $FreeBSD$
|
||||
|
||||
UTILS = hdf24to8 hdfcomp hdfls hdfpack hdftopal hdftor8 paltohdf \
|
||||
r8tohdf ristosds vmake vshow hdf8to24 hdf2jpeg jpeg2hdf fp2hdf \
|
||||
hdfunpac vcompat
|
||||
|
||||
all: ${UTILS} hdfed
|
||||
|
||||
HEOBJ = he_main.o he_cntrl.o he_disp.o he_file.o
|
||||
|
||||
#CFLAGS += -I${PREFIX}/include -I${.CURDIR}/../src/
|
||||
CFLAGS += -I${.CURDIR}/../src/
|
||||
#LDFLAGS += -L${PREFIX}/lib -ljpeg -L${.CURDIR}/../src/ -ldf -lz
|
||||
LDFLAGS += -L${.CURDIR}/../src/ -ldf
|
||||
|
||||
hdfed: he.h he_proto.h $(HEOBJ)
|
||||
$(CC) $(HEOBJ) $(LDFLAGS) -o hdfed
|
||||
|
||||
test: all fptest
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../src ./testutil.sh
|
||||
|
||||
clean:
|
||||
-rm -f *.o $(UTILS) hdfed fptest
|
||||
-rm -f o* ctx* cb* fptestf .depend
|
||||
|
||||
depend:
|
||||
mkdep ${CFLAGS} ${UTILS:S/$/.c/g} ${HEOBJ:S/.o/.c/g}
|
||||
|
||||
install: all
|
||||
install -c -s -o root -g wheel -m 555 ${UTILS} hdfed ${BINDIR}
|
17
graphics/hdf/files/man/Makefile
Normal file
17
graphics/hdf/files/man/Makefile
Normal file
@ -0,0 +1,17 @@
|
||||
# $FreeBSD$
|
||||
|
||||
MANDIR = ${PREFIX}/man/man
|
||||
|
||||
MAN1 = hdf.1 hdfunpac.1
|
||||
MAN3 = gr_chunk.3
|
||||
|
||||
.include <bsd.man.mk>
|
||||
|
||||
install: all-man maninstall
|
||||
|
||||
clean:
|
||||
-rm -f *.gz
|
||||
|
||||
all: all-man
|
||||
|
||||
depend:
|
13
graphics/hdf/files/mfhdf/Makefile
Normal file
13
graphics/hdf/files/mfhdf/Makefile
Normal file
@ -0,0 +1,13 @@
|
||||
# $FreeBSD$
|
||||
|
||||
SUBDIR = fortran libsrc ncgen ncdump nctest dumper
|
||||
|
||||
.include <bsd.subdir.mk>
|
||||
|
||||
test: all
|
||||
@for d in ${SUBDIR} ; do \
|
||||
echo "===> testing in $$d"; \
|
||||
cd $$d; \
|
||||
${MAKE} test; \
|
||||
cd ..; \
|
||||
done
|
13
graphics/hdf/files/mfhdf/dumper/Makefile
Normal file
13
graphics/hdf/files/mfhdf/dumper/Makefile
Normal file
@ -0,0 +1,13 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = hdp
|
||||
NOMAN = 1
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
CFLAGS += -I${.CURDIR}/../libsrc -I${.CURDIR}/../../hdf/src
|
||||
|
||||
SRCS = hdp.c hdp_list.c hdp_sds.c hdp_util.c hdp_vd.c hdp_vg.c hdp_rig.c show.c hdp_dump.c hdp_gr.c
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
test: ${PROG}
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src sh testhdp.sh
|
42
graphics/hdf/files/mfhdf/fortran/Makefile
Normal file
42
graphics/hdf/files/mfhdf/fortran/Makefile
Normal file
@ -0,0 +1,42 @@
|
||||
# $FreeBSD$
|
||||
|
||||
.PATH: ${.CURDIR} ${.CURDIR}/config
|
||||
|
||||
all:
|
||||
|
||||
NOMAN = 1
|
||||
|
||||
FFLAGS += ${CFLAGS} -DNDEBUG -Nn802 -Nx400
|
||||
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
|
||||
afterinstall:
|
||||
install -c -o root -g wheel -m 444 config/netcdf-fbsd.inc \
|
||||
${PREFIX}/include/netcdf.inc
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
ENVIR = env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src
|
||||
|
||||
CLEANFILES+= hdftest hdftest.o ftest ftest-fbsd.o
|
||||
|
||||
config/netcdf.inc:
|
||||
ln -s netcdf-fbsd.inc config/netcdf.inc
|
||||
|
||||
ftest: ftest-fbsd.f config/netcdf.inc
|
||||
${MAKE} PROG=$@ SRCS=ftest-fbsd.f $@
|
||||
|
||||
hdftest: hdftest.f
|
||||
${MAKE} PROG=$@ SRCS=hdftest.f $@
|
||||
|
||||
test: ftest hdftest
|
||||
mkdir -p testdir
|
||||
# ================================
|
||||
# netCDF Fortran interface tests
|
||||
# ================================
|
||||
${ENVIR} ./ftest
|
||||
${ENVIR} ./hdftest > hdfout.new
|
||||
@diff -Bb hdfout.new hdftst.sav && \
|
||||
echo "*** HDF-SD Fortran interface tests passed ***" || \
|
||||
(echo "*** HDF-SD Fortran interface tests failed ***"; \
|
||||
echo "The above differences are OK if small")
|
43
graphics/hdf/files/mfhdf/libsrc/Makefile
Normal file
43
graphics/hdf/files/mfhdf/libsrc/Makefile
Normal file
@ -0,0 +1,43 @@
|
||||
# $FreeBSD$
|
||||
|
||||
.PATH: ${.CURDIR} ${.CURDIR}/../fortran/config ${.CURDIR}/../fortran
|
||||
|
||||
SRCS = array.c attr.c cdf.c dim.c file.c iarray.c error.c \
|
||||
globdef.c putget.c putgetg.c sharray.c string.c var.c \
|
||||
hdfsds.c mfsd.c nssdc.c xdrposix.c \
|
||||
jackets-fbsd.c mfsdf.c mfsdff.f
|
||||
|
||||
LIB = mfhdf
|
||||
SHLIB_MAJOR = 2
|
||||
SHLIB_MINOR = 3
|
||||
|
||||
LIBDIR = ${PREFIX}/lib
|
||||
|
||||
# uncomment the line below to avoid building static libraries
|
||||
#INTERNALLIB = Yes
|
||||
|
||||
CFLAGS += -DNDEBUG -DHDF -I${.CURDIR}/../../hdf/src -I${.CURDIR}
|
||||
.if ${MACHINE_ARCH} == "i386"
|
||||
CFLAGS += -DSWAP
|
||||
.endif
|
||||
|
||||
LDADD += -L${.CURDIR}/../../hdf/src -ldf
|
||||
LDFLAGS += -L. -l${LIB} ${LDADD}
|
||||
|
||||
afterinstall:
|
||||
install -c -o root -g wheel -m 444 hdf2netcdf.h local_nc.h \
|
||||
mfhdf.h netcdf.h ${PREFIX}/include
|
||||
|
||||
.include <bsd.lib.mk>
|
||||
|
||||
test: ${SHLIB_NAME} cdftest hdftest
|
||||
env LD_LIBRARY_PATH=${.CURDIR}:${.CURDIR}/../../hdf/src ./cdftest > cdfout.new
|
||||
@diff cdfout.new testout.sav && \
|
||||
echo "*** netCDF passes formatted test ***" || \
|
||||
(echo "*** netCDF fails formatted test ***" ; \
|
||||
echo "The above differences are OK if small")
|
||||
env LD_LIBRARY_PATH=${.CURDIR}:${.CURDIR}/../../hdf/src ./hdftest > hdfout.new
|
||||
@diff hdfout.new hdfout.sav && \
|
||||
echo "*** HDF passes formatted test ***" || \
|
||||
(echo "*** HDF fails formatted test ***" ; \
|
||||
echo "The above differences are OK if small")
|
22
graphics/hdf/files/mfhdf/ncdump/Makefile
Normal file
22
graphics/hdf/files/mfhdf/ncdump/Makefile
Normal file
@ -0,0 +1,22 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = ncdump
|
||||
MANDIR = ${PREFIX}/man/man
|
||||
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
CFLAGS += -I${.CURDIR}/../libsrc
|
||||
SRCS = ncdump.c vardata.c dumplib.c
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
ENVIR = env LD_LIBRARY_PATH=${.CURDIR}/../../hdf/src:${.CURDIR}/../libsrc
|
||||
NCGEN = ${.CURDIR}/../ncgen/ncgen
|
||||
|
||||
test: $(PROG) test0.cdl
|
||||
${ENVIR} $(NCGEN) -o test0.nc -n test0.cdl
|
||||
${ENVIR} ./$(PROG) test0.nc > test1.cdl
|
||||
${ENVIR} $(NCGEN) -o test1.nc -n test1.cdl
|
||||
${ENVIR} ./$(PROG) -n test0 test1.nc > test2.cdl
|
||||
@cmp test1.cdl test2.cdl && \
|
||||
echo "*** $(PROGRAM) test successful ***" ; \
|
||||
rm test1.cdl test1.nc test2.cdl
|
72
graphics/hdf/files/mfhdf/ncgen/Makefile
Normal file
72
graphics/hdf/files/mfhdf/ncgen/Makefile
Normal file
@ -0,0 +1,72 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = ncgen
|
||||
MANDIR = ${PREFIX}/man/man
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
CFLAGS += -I${.CURDIR}/../libsrc -I${.CURDIR}/../../hdf/src -DNDEBUG
|
||||
SRCS = main.c generate.c load.c ncgentab.c escapes.c \
|
||||
getfill.c init.c close.c genlib.c
|
||||
|
||||
ENVIR = env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src
|
||||
NCDUMP = ${.CURDIR}/../ncdump/ncdump
|
||||
|
||||
test: $(PROG) test0.cdl btest ctest ftest
|
||||
|
||||
ncgenyy.c: ncgen.l
|
||||
${LEX} ${LFLAGS} ncgen.l
|
||||
mv lex.yy.c ncgenyy.c
|
||||
|
||||
ncgentab.c: ncgenyy.c ncgen.y
|
||||
${YACC} ${YFLAGS} ncgen.y
|
||||
mv y.tab.c ncgentab.c
|
||||
mv y.tab.h ncgentab.h
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
#
|
||||
# test "-b" option of ncgen
|
||||
#
|
||||
btest: $(PROG) test0.cdl test1.cdl
|
||||
${ENVIR} ./$(PROG) -b test1.cdl
|
||||
${ENVIR} $(NCDUMP) test1.nc > test2.cdl
|
||||
@diff test1.cdl test2.cdl && \
|
||||
echo "*** $(PROG) -b test successful ***"
|
||||
|
||||
#
|
||||
# test "-c" option of ncgen
|
||||
#
|
||||
ctest: test1.cdl ctest0
|
||||
${ENVIR} ./ctest0 # tests `-c' option, creates ctest0.nc
|
||||
${ENVIR} $(NCDUMP) -n test1 ctest0.nc > ctest1.cdl
|
||||
@diff test1.cdl ctest1.cdl && \
|
||||
echo "*** $(PROG) -c test successful ***"
|
||||
|
||||
ctest0: ncgen test0.cdl
|
||||
${ENVIR} ./$(PROG) -c -o ctest0.nc test0.cdl > test0.c
|
||||
$(CC) $(CFLAGS) -o $@ test0.c ${LDFLAGS}
|
||||
|
||||
#
|
||||
# test "-f" option of ncgen
|
||||
#
|
||||
ftest: test1.cdl ftest0
|
||||
${ENVIR} ./ftest0
|
||||
${ENVIR} $(NCDUMP) -n test1 ftest0.nc > ftest1.cdl
|
||||
@if diff test1.cdl ftest1.cdl; then \
|
||||
echo "*** ncgen -f test successful ***"; \
|
||||
else \
|
||||
echo "*** ncgen -f test failed " \
|
||||
"(but roundoff differences are OK) ***"; \
|
||||
fi
|
||||
|
||||
ftest0: $(PROG) test0.cdl netcdf.inc
|
||||
${ENVIR} ./$(PROG) -f -o ftest0.nc test0.cdl > test0.f; \
|
||||
$(FC) $(FFLAGS) ${CFLAGS} -o $@ test0.f ${LDFLAGS}
|
||||
|
||||
test1.cdl: test0.nc
|
||||
${ENVIR} $(NCDUMP) -n test1 test0.nc > $@
|
||||
|
||||
test0.nc: $(PROG) test0.cdl
|
||||
${ENVIR} ./$(PROG) -b -o test0.nc test0.cdl
|
||||
|
||||
netcdf.inc:
|
||||
ln -s ../fortran/config/netcdf-fbsd.inc $@
|
19
graphics/hdf/files/mfhdf/nctest/Makefile
Normal file
19
graphics/hdf/files/mfhdf/nctest/Makefile
Normal file
@ -0,0 +1,19 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = nctest
|
||||
NOMAN = 1
|
||||
CFLAGS += -I${.CURDIR}/../libsrc
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
SRCS = varget.c vargetg.c varput.c varputg.c vardef.c vartests.c \
|
||||
vputget.c vputgetg.c driver.c cdftests.c dimtests.c rec.c \
|
||||
atttests.c misctest.c add.c error.c emalloc.c val.c slabs.c
|
||||
|
||||
install:
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
test: $(PROG)
|
||||
@ echo "==========================="
|
||||
@ echo "netCDF C interface tests"
|
||||
@ echo "==========================="
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src ./$(PROG)
|
@ -20,7 +20,11 @@ bin/vcompat
|
||||
bin/vmake
|
||||
bin/vshow
|
||||
lib/libmfhdf.a
|
||||
lib/libmfhdf.so.2
|
||||
lib/libmfhdf.so
|
||||
lib/libdf.a
|
||||
lib/libdf.so
|
||||
lib/libdf.so.1
|
||||
include/atom.h
|
||||
include/bitvect.h
|
||||
include/cdeflate.h
|
||||
@ -30,7 +34,6 @@ include/crle.h
|
||||
include/cskphuff.h
|
||||
include/df.h
|
||||
include/dfan.h
|
||||
include/dffunc.f90
|
||||
include/dffunc.inc
|
||||
include/dfgr.h
|
||||
include/dfi.h
|
||||
@ -45,7 +48,6 @@ include/hcomp.h
|
||||
include/hcompi.h
|
||||
include/hconv.h
|
||||
include/hdf.h
|
||||
include/hdf.f90
|
||||
include/hdf.inc
|
||||
include/hdf2netcdf.h
|
||||
include/hdfi.h
|
||||
@ -63,7 +65,6 @@ include/mfgr.h
|
||||
include/mfhdf.h
|
||||
include/mstdio.h
|
||||
include/netcdf.h
|
||||
include/netcdf.f90
|
||||
include/netcdf.inc
|
||||
include/tbbt.h
|
||||
include/vattr.h
|
||||
|
@ -6,63 +6,32 @@
|
||||
# $FreeBSD$
|
||||
#
|
||||
|
||||
DISTNAME= HDF4.1r2
|
||||
PKGNAME= hdf-4.1r2
|
||||
DISTNAME= HDF4.1r3
|
||||
PKGNAME= hdf-4.1r3
|
||||
CATEGORIES= graphics
|
||||
MASTER_SITES= ftp://ftp.ncsa.uiuc.edu/HDF/HDF4.1r2/tar/
|
||||
MASTER_SITES= ftp://ftp.ncsa.uiuc.edu/HDF/HDF/HDF4.1r3/tar/
|
||||
|
||||
MAINTAINER= mi@aldan.algebra.com
|
||||
|
||||
LIB_DEPENDS= jpeg.9:${PORTSDIR}/graphics/jpeg
|
||||
|
||||
MAN1= hdf.1 hdfunpac.1 ncdump.1 ncgen.1
|
||||
MAN3= gr_chunk.3
|
||||
MANCOMPRESSED= maybe
|
||||
|
||||
GNU_CONFIGURE= yes
|
||||
FC?= f77 # Can also be g77 for the newer one
|
||||
MAKE_FLAGS= CC="$(CC)" FC="${FC}" -f
|
||||
MAKE_ENV= pwrkdir=${WRKDIR}
|
||||
#"wrkdir" doesn't work for some reason in the above
|
||||
MAKE_ARGS= PREFIX="${PREFIX}" -j 2
|
||||
|
||||
# This will create dummy Makefiles and some links in the jpeg and libz
|
||||
# subdirectories. This way, we do not need to hunt all the dependencies
|
||||
# out. Shame on the lib's developers, though, this can not be done through
|
||||
# `configure'. -mi
|
||||
pre-build:
|
||||
${AR} -r ${WRKDIR}/libz.a /dev/null
|
||||
${RANLIB} ${WRKDIR}/libz.a
|
||||
test -d ${WRKSRC}/hdf/jpeg.came-with-HDF || \
|
||||
${MV} -f ${WRKSRC}/hdf/jpeg ${WRKSRC}/hdf/jpeg.came-with-HDF
|
||||
-${MKDIR} ${WRKSRC}/hdf/jpeg
|
||||
${RM} -f ${WRKSRC}/hdf/jpeg/Makefile
|
||||
${ECHO} #Phony makefile > ${WRKSRC}/hdf/jpeg/Makefile
|
||||
${ECHO} >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
${ECHO} libjpeg.a: >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\t@${ECHO} Using the already installed JPEG library\n' \
|
||||
>> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\nclean:\n\ttrue\n' >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\ninstall-lib:\n\ttrue\n' >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\ninstall:\n\ttrue\n' >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
-${LN} -s ${PREFIX}/lib/libjpeg* ${WRKSRC}/hdf/jpeg/
|
||||
-${LN} -s ${PREFIX}/include/j*.h ${WRKSRC}/hdf/jpeg/
|
||||
test -d ${WRKSRC}/hdf/zlib.came-with-HDF || \
|
||||
${MV} -f ${WRKSRC}/hdf/zlib ${WRKSRC}/hdf/zlib.came-with-HDF
|
||||
-${MKDIR} ${WRKSRC}/hdf/zlib
|
||||
${RM} -f ${WRKSRC}/hdf/zlib/Makefile
|
||||
${ECHO} #Phony makefile > ${WRKSRC}/hdf/zlib/Makefile
|
||||
${ECHO} >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
${ECHO} libzlib.a: >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\t@${ECHO} Using the already installed ZLIB library\n' \
|
||||
>> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\nclean:\n\ttrue\n' >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\ninstall-lib:\n\ttrue\n' >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\ninstall:\n\ttrue\n' >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
-${LN} -s /usr/lib/${BINFORMAT}/libz* ${WRKSRC}/hdf/zlib/
|
||||
-${LN} -s /usr/include/zconf.h /usr/include/zlib.h ${WRKSRC}/hdf/zlib/
|
||||
post-patch:
|
||||
${RM} -rf ${WRKSRC}/hdf/jpeg
|
||||
${RM} -rf ${WRKSRC}/hdf/zlib
|
||||
|
||||
post-install:
|
||||
@for binary in `${GREP} ^bin/ ${PLIST}` ; do strip ${PREFIX}/$$binary; done
|
||||
do-configure:
|
||||
${CP} -rp ${FILESDIR}/Makefile ${FILESDIR}/hdf \
|
||||
${FILESDIR}/mfhdf ${FILESDIR}/man ${WRKSRC}
|
||||
${LN} -s config/netcdf-fbsd.h ${WRKSRC}/mfhdf/libsrc/netcdf.h
|
||||
${LN} -s netcdf-fbsd.inc ${WRKSRC}/mfhdf/fortran/config/netcdf.inc
|
||||
|
||||
test:
|
||||
cd ${WRKSRC}; make ${MAKE_FLAGS} ${MAKEFILE} test
|
||||
test: build
|
||||
cd ${WRKSRC}; ${MAKE} test
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
@ -1 +1 @@
|
||||
MD5 (HDF4.1r2.tar.gz) = 52814865529791e3a39637fd851a7143
|
||||
MD5 (HDF4.1r3.tar.gz) = 975f84ad8c5910841995c9d339fbd8bb
|
||||
|
16
graphics/hdf5/files/Makefile
Normal file
16
graphics/hdf5/files/Makefile
Normal file
@ -0,0 +1,16 @@
|
||||
# $FreeBSD$
|
||||
|
||||
SUBDIR = hdf mfhdf man
|
||||
#PREFIX ?= /usr/local
|
||||
LIBDIR ?= ${PREFIX}/lib
|
||||
BINDIR ?= ${PREFIX}/bin
|
||||
|
||||
.MAKEFLAGS: PREFIX=${PREFIX} LIBDIR=${LIBDIR} BINDIR=${BINDIR}
|
||||
|
||||
test: all
|
||||
# testing in hdf
|
||||
@cd hdf && ${MAKE} hdf-test
|
||||
# testing in mfhdf
|
||||
@cd mfhdf && ${MAKE} test
|
||||
|
||||
.include <bsd.subdir.mk>
|
9
graphics/hdf5/files/hdf/Makefile
Normal file
9
graphics/hdf5/files/hdf/Makefile
Normal file
@ -0,0 +1,9 @@
|
||||
# $FreeBSD$
|
||||
|
||||
SUBDIR = src util test
|
||||
|
||||
hdf-test: all
|
||||
cd util && ${MAKE} test
|
||||
cd test && ${MAKE} test
|
||||
|
||||
.include <bsd.subdir.mk>
|
54
graphics/hdf5/files/hdf/src/Makefile
Normal file
54
graphics/hdf5/files/hdf/src/Makefile
Normal file
@ -0,0 +1,54 @@
|
||||
# $FreeBSD$
|
||||
|
||||
LIB=df
|
||||
|
||||
# uncomment the line below to avoid building static libraries
|
||||
#INTERNALLIB=YES
|
||||
LIBDIR=${PREFIX}/lib
|
||||
|
||||
SHLIB_MAJOR=1
|
||||
SHLIB_MINOR=0
|
||||
|
||||
SRCS=atom.c bitvect.c cdeflate.c cnbit.c cnone.c crle.c cskphuff.c \
|
||||
df24.c df24f.c dfan.c dfanf.c dfcomp.c dfconv.c dff.c dfgr.c \
|
||||
dfgroup.c dfimcomp.c dfjpeg.c dfkconv.c dfkcray.c dfkfuji.c \
|
||||
dfknat.c dfkswap.c dfkvms.c dfp.c dfpf.c dfr8.c dfr8f.c dfrle.c \
|
||||
dfsd.c dfsdf.c dfstubs.c dfufp2i.c dfunjpeg.c dfutil.c dfutilf.c \
|
||||
dir_mac.c dynarray.c glist.c hbitio.c hblocks.c hbuffer.c \
|
||||
hchunks.c hcomp.c hcompri.c hdfalloc.c herr.c herrf.c hextelt.c \
|
||||
hfile.c hfiledd.c hfilef.c hkit.c linklist.c mcache.c \
|
||||
mfan.c mfanf.c mfgr.c mfgrf.c mstdio.c tbbt.c vattr.c vattrf.c \
|
||||
vconv.c vg.c vgf.c vgp.c vhi.c vio.c vparse.c vrw.c vsfld.c \
|
||||
df24ff.f dfanff.f dfff.f dfpff.f dfr8ff.f dfsdff.f dfufp2if.f \
|
||||
hfileff.f mfgrff.f vattrff.f vgff.f
|
||||
|
||||
CFLAGS += -I${PREFIX}/include
|
||||
FFLAGS += ${CFLAGS}
|
||||
|
||||
.if !defined(OSVERSION)
|
||||
.if exists(/sbin/sysctl)
|
||||
OSVERSION!= /sbin/sysctl -n kern.osreldate
|
||||
.else
|
||||
OSVERSION!= /usr/sbin/sysctl -n kern.osreldate
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if ${OSVERSION} >= 400004
|
||||
LDADD += -L${PREFIX}/lib -ljpeg -lg2c -lz -lm
|
||||
.else
|
||||
LDADD += -L${PREFIX}/lib -ljpeg -lf2c -lz
|
||||
.endif
|
||||
|
||||
afterinstall:
|
||||
install -c -o root -g wheel -m 444 \
|
||||
atom.h bitvect.h cdeflate.h cnbit.h cnone.h crle.h \
|
||||
cskphuff.h df.h dfan.h dfconvrt.h dfgr.h dfi.h dfivms.h \
|
||||
dfrig.h dfsd.h dfstubs.h dfufp2i.h dir_mac.h dynarray.h \
|
||||
glist.h hbitio.h hchunks.h hcomp.h hcompi.h hconv.h \
|
||||
hdf.h hdfi.h herr.h hfile.h hkit.h hlimits.h hntdefs.h \
|
||||
hproto.h hqueue.h htags.h linklist.h maldebug.h mcache.h \
|
||||
mfan.h mfgr.h mstdio.h patchlevel.h sys_dir_mac.h tbbt.h \
|
||||
trace.h vattr.h vg.h vgint.h hdf.inc dffunc.inc \
|
||||
${PREFIX}/include
|
||||
|
||||
.include <bsd.lib.mk>
|
68
graphics/hdf5/files/hdf/test/Makefile
Normal file
68
graphics/hdf5/files/hdf/test/Makefile
Normal file
@ -0,0 +1,68 @@
|
||||
# $FreeBSD$
|
||||
|
||||
CSRCS= rig.c sdstr.c blocks.c an.c anfile.c extelt.c file.c file1.c vers.c \
|
||||
sdmms.c sdnmms.c slab.c litend.c tvset.c comp.c bitio.c tree.c macros.c \
|
||||
conv.c nbit.c man.c mgr.c testhdf.c tbv.c tvsfpack.c chunks.c tvattr.c \
|
||||
buffer.c
|
||||
|
||||
COBJS= ${CSRCS:S/.c/.o/g}
|
||||
|
||||
FSRCS= fortest.c fortestF.f forsupff.f forsupf.c \
|
||||
manf.f mgrf.f slabwf.f t24f.f tanf.f tanfilef.f tpf.f tr8f.f \
|
||||
tsdmmsf.f tsdnmmsf.f tsdnntf.f tsdntf.f tsdstrf.f tstubsf.f \
|
||||
tvsetf.f, tvattrf.f
|
||||
|
||||
FOBJS = fortestF.o forsupff.o forsupf.o \
|
||||
manf.o mgrf.o slabwf.o t24f.o tanf.o tanfilef.o tpf.o tr8f.o \
|
||||
tsdmmsf.o tsdnmmsf.o tsdnntf.o tsdntf.o tsdstrf.o tstubsf.o \
|
||||
tvsetf.o tvattrf.o
|
||||
|
||||
#CFORSUPSRCS = forsupf.c
|
||||
|
||||
HDFLIB = ${.CURDIR}/../src
|
||||
CFLAGS += -I${HDFLIB}
|
||||
FFLAGS += ${CFLAGS} -Nn802 -Nx400
|
||||
|
||||
FTESTS = fortest fortestF
|
||||
|
||||
all: testhdf $(FTESTS) gentest
|
||||
|
||||
#CFORSUPOBJS = forsupf.o
|
||||
|
||||
TESTF = fortest.o
|
||||
|
||||
# directory used by extelt test.
|
||||
TESTDIR = testdir
|
||||
|
||||
$(FOBJS): fortest.inc
|
||||
|
||||
test: atest-hdf
|
||||
|
||||
atest-hdf: testhdf $(FTESTS)
|
||||
-rm -f *.hdf
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../src ./testhdf
|
||||
-rm -f *.hdf
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../src ./fortest
|
||||
|
||||
testhdf: $(COBJS) $(HDFLIB)/libdf.so
|
||||
$(CC) -o testhdf $(COBJS) $(HDFLIB)/libdf.so -lm
|
||||
test -d $(TESTDIR) || mkdir $(TESTDIR)
|
||||
|
||||
fortestF: $(FOBJS) $(HDFLIB)/libdf.so
|
||||
$(FC) $(FFLAGS) -o $@ $(FOBJS) $(HDFLIB)/libdf.so -lm
|
||||
|
||||
fortest: $(HDFLIB)/libdf.so fortest.c $(CHDRS)
|
||||
$(CC) $(CFLAGS) -o fortest fortest.c $(HDFLIB)/libdf.so -lm
|
||||
|
||||
gentest: gentest.c $(HDFLIB)/libdf.so
|
||||
$(CC) $(CFLAGS) gentest.c -o gentest $(HDFLIB)/libdf.so -lm
|
||||
|
||||
clean:
|
||||
-rm -f $(COBJS) testhdf $(FOBJS) $(FTESTS) \
|
||||
core *.hdf ptesthdf qtesthdf gentest *.o fortest.arg $(TESTDIR)/* \
|
||||
.depend
|
||||
|
||||
depend:
|
||||
mkdep ${CFLAGS} ${CSRCS}
|
||||
|
||||
install:
|
30
graphics/hdf5/files/hdf/util/Makefile
Normal file
30
graphics/hdf5/files/hdf/util/Makefile
Normal file
@ -0,0 +1,30 @@
|
||||
# $FreeBSD$
|
||||
|
||||
UTILS = hdf24to8 hdfcomp hdfls hdfpack hdftopal hdftor8 paltohdf \
|
||||
r8tohdf ristosds vmake vshow hdf8to24 hdf2jpeg jpeg2hdf fp2hdf \
|
||||
hdfunpac vcompat
|
||||
|
||||
all: ${UTILS} hdfed
|
||||
|
||||
HEOBJ = he_main.o he_cntrl.o he_disp.o he_file.o
|
||||
|
||||
#CFLAGS += -I${PREFIX}/include -I${.CURDIR}/../src/
|
||||
CFLAGS += -I${.CURDIR}/../src/
|
||||
#LDFLAGS += -L${PREFIX}/lib -ljpeg -L${.CURDIR}/../src/ -ldf -lz
|
||||
LDFLAGS += -L${.CURDIR}/../src/ -ldf
|
||||
|
||||
hdfed: he.h he_proto.h $(HEOBJ)
|
||||
$(CC) $(HEOBJ) $(LDFLAGS) -o hdfed
|
||||
|
||||
test: all fptest
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../src ./testutil.sh
|
||||
|
||||
clean:
|
||||
-rm -f *.o $(UTILS) hdfed fptest
|
||||
-rm -f o* ctx* cb* fptestf .depend
|
||||
|
||||
depend:
|
||||
mkdep ${CFLAGS} ${UTILS:S/$/.c/g} ${HEOBJ:S/.o/.c/g}
|
||||
|
||||
install: all
|
||||
install -c -s -o root -g wheel -m 555 ${UTILS} hdfed ${BINDIR}
|
17
graphics/hdf5/files/man/Makefile
Normal file
17
graphics/hdf5/files/man/Makefile
Normal file
@ -0,0 +1,17 @@
|
||||
# $FreeBSD$
|
||||
|
||||
MANDIR = ${PREFIX}/man/man
|
||||
|
||||
MAN1 = hdf.1 hdfunpac.1
|
||||
MAN3 = gr_chunk.3
|
||||
|
||||
.include <bsd.man.mk>
|
||||
|
||||
install: all-man maninstall
|
||||
|
||||
clean:
|
||||
-rm -f *.gz
|
||||
|
||||
all: all-man
|
||||
|
||||
depend:
|
13
graphics/hdf5/files/mfhdf/Makefile
Normal file
13
graphics/hdf5/files/mfhdf/Makefile
Normal file
@ -0,0 +1,13 @@
|
||||
# $FreeBSD$
|
||||
|
||||
SUBDIR = fortran libsrc ncgen ncdump nctest dumper
|
||||
|
||||
.include <bsd.subdir.mk>
|
||||
|
||||
test: all
|
||||
@for d in ${SUBDIR} ; do \
|
||||
echo "===> testing in $$d"; \
|
||||
cd $$d; \
|
||||
${MAKE} test; \
|
||||
cd ..; \
|
||||
done
|
13
graphics/hdf5/files/mfhdf/dumper/Makefile
Normal file
13
graphics/hdf5/files/mfhdf/dumper/Makefile
Normal file
@ -0,0 +1,13 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = hdp
|
||||
NOMAN = 1
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
CFLAGS += -I${.CURDIR}/../libsrc -I${.CURDIR}/../../hdf/src
|
||||
|
||||
SRCS = hdp.c hdp_list.c hdp_sds.c hdp_util.c hdp_vd.c hdp_vg.c hdp_rig.c show.c hdp_dump.c hdp_gr.c
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
test: ${PROG}
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src sh testhdp.sh
|
42
graphics/hdf5/files/mfhdf/fortran/Makefile
Normal file
42
graphics/hdf5/files/mfhdf/fortran/Makefile
Normal file
@ -0,0 +1,42 @@
|
||||
# $FreeBSD$
|
||||
|
||||
.PATH: ${.CURDIR} ${.CURDIR}/config
|
||||
|
||||
all:
|
||||
|
||||
NOMAN = 1
|
||||
|
||||
FFLAGS += ${CFLAGS} -DNDEBUG -Nn802 -Nx400
|
||||
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
|
||||
afterinstall:
|
||||
install -c -o root -g wheel -m 444 config/netcdf-fbsd.inc \
|
||||
${PREFIX}/include/netcdf.inc
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
ENVIR = env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src
|
||||
|
||||
CLEANFILES+= hdftest hdftest.o ftest ftest-fbsd.o
|
||||
|
||||
config/netcdf.inc:
|
||||
ln -s netcdf-fbsd.inc config/netcdf.inc
|
||||
|
||||
ftest: ftest-fbsd.f config/netcdf.inc
|
||||
${MAKE} PROG=$@ SRCS=ftest-fbsd.f $@
|
||||
|
||||
hdftest: hdftest.f
|
||||
${MAKE} PROG=$@ SRCS=hdftest.f $@
|
||||
|
||||
test: ftest hdftest
|
||||
mkdir -p testdir
|
||||
# ================================
|
||||
# netCDF Fortran interface tests
|
||||
# ================================
|
||||
${ENVIR} ./ftest
|
||||
${ENVIR} ./hdftest > hdfout.new
|
||||
@diff -Bb hdfout.new hdftst.sav && \
|
||||
echo "*** HDF-SD Fortran interface tests passed ***" || \
|
||||
(echo "*** HDF-SD Fortran interface tests failed ***"; \
|
||||
echo "The above differences are OK if small")
|
43
graphics/hdf5/files/mfhdf/libsrc/Makefile
Normal file
43
graphics/hdf5/files/mfhdf/libsrc/Makefile
Normal file
@ -0,0 +1,43 @@
|
||||
# $FreeBSD$
|
||||
|
||||
.PATH: ${.CURDIR} ${.CURDIR}/../fortran/config ${.CURDIR}/../fortran
|
||||
|
||||
SRCS = array.c attr.c cdf.c dim.c file.c iarray.c error.c \
|
||||
globdef.c putget.c putgetg.c sharray.c string.c var.c \
|
||||
hdfsds.c mfsd.c nssdc.c xdrposix.c \
|
||||
jackets-fbsd.c mfsdf.c mfsdff.f
|
||||
|
||||
LIB = mfhdf
|
||||
SHLIB_MAJOR = 2
|
||||
SHLIB_MINOR = 3
|
||||
|
||||
LIBDIR = ${PREFIX}/lib
|
||||
|
||||
# uncomment the line below to avoid building static libraries
|
||||
#INTERNALLIB = Yes
|
||||
|
||||
CFLAGS += -DNDEBUG -DHDF -I${.CURDIR}/../../hdf/src -I${.CURDIR}
|
||||
.if ${MACHINE_ARCH} == "i386"
|
||||
CFLAGS += -DSWAP
|
||||
.endif
|
||||
|
||||
LDADD += -L${.CURDIR}/../../hdf/src -ldf
|
||||
LDFLAGS += -L. -l${LIB} ${LDADD}
|
||||
|
||||
afterinstall:
|
||||
install -c -o root -g wheel -m 444 hdf2netcdf.h local_nc.h \
|
||||
mfhdf.h netcdf.h ${PREFIX}/include
|
||||
|
||||
.include <bsd.lib.mk>
|
||||
|
||||
test: ${SHLIB_NAME} cdftest hdftest
|
||||
env LD_LIBRARY_PATH=${.CURDIR}:${.CURDIR}/../../hdf/src ./cdftest > cdfout.new
|
||||
@diff cdfout.new testout.sav && \
|
||||
echo "*** netCDF passes formatted test ***" || \
|
||||
(echo "*** netCDF fails formatted test ***" ; \
|
||||
echo "The above differences are OK if small")
|
||||
env LD_LIBRARY_PATH=${.CURDIR}:${.CURDIR}/../../hdf/src ./hdftest > hdfout.new
|
||||
@diff hdfout.new hdfout.sav && \
|
||||
echo "*** HDF passes formatted test ***" || \
|
||||
(echo "*** HDF fails formatted test ***" ; \
|
||||
echo "The above differences are OK if small")
|
22
graphics/hdf5/files/mfhdf/ncdump/Makefile
Normal file
22
graphics/hdf5/files/mfhdf/ncdump/Makefile
Normal file
@ -0,0 +1,22 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = ncdump
|
||||
MANDIR = ${PREFIX}/man/man
|
||||
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
CFLAGS += -I${.CURDIR}/../libsrc
|
||||
SRCS = ncdump.c vardata.c dumplib.c
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
ENVIR = env LD_LIBRARY_PATH=${.CURDIR}/../../hdf/src:${.CURDIR}/../libsrc
|
||||
NCGEN = ${.CURDIR}/../ncgen/ncgen
|
||||
|
||||
test: $(PROG) test0.cdl
|
||||
${ENVIR} $(NCGEN) -o test0.nc -n test0.cdl
|
||||
${ENVIR} ./$(PROG) test0.nc > test1.cdl
|
||||
${ENVIR} $(NCGEN) -o test1.nc -n test1.cdl
|
||||
${ENVIR} ./$(PROG) -n test0 test1.nc > test2.cdl
|
||||
@cmp test1.cdl test2.cdl && \
|
||||
echo "*** $(PROGRAM) test successful ***" ; \
|
||||
rm test1.cdl test1.nc test2.cdl
|
72
graphics/hdf5/files/mfhdf/ncgen/Makefile
Normal file
72
graphics/hdf5/files/mfhdf/ncgen/Makefile
Normal file
@ -0,0 +1,72 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = ncgen
|
||||
MANDIR = ${PREFIX}/man/man
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
CFLAGS += -I${.CURDIR}/../libsrc -I${.CURDIR}/../../hdf/src -DNDEBUG
|
||||
SRCS = main.c generate.c load.c ncgentab.c escapes.c \
|
||||
getfill.c init.c close.c genlib.c
|
||||
|
||||
ENVIR = env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src
|
||||
NCDUMP = ${.CURDIR}/../ncdump/ncdump
|
||||
|
||||
test: $(PROG) test0.cdl btest ctest ftest
|
||||
|
||||
ncgenyy.c: ncgen.l
|
||||
${LEX} ${LFLAGS} ncgen.l
|
||||
mv lex.yy.c ncgenyy.c
|
||||
|
||||
ncgentab.c: ncgenyy.c ncgen.y
|
||||
${YACC} ${YFLAGS} ncgen.y
|
||||
mv y.tab.c ncgentab.c
|
||||
mv y.tab.h ncgentab.h
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
#
|
||||
# test "-b" option of ncgen
|
||||
#
|
||||
btest: $(PROG) test0.cdl test1.cdl
|
||||
${ENVIR} ./$(PROG) -b test1.cdl
|
||||
${ENVIR} $(NCDUMP) test1.nc > test2.cdl
|
||||
@diff test1.cdl test2.cdl && \
|
||||
echo "*** $(PROG) -b test successful ***"
|
||||
|
||||
#
|
||||
# test "-c" option of ncgen
|
||||
#
|
||||
ctest: test1.cdl ctest0
|
||||
${ENVIR} ./ctest0 # tests `-c' option, creates ctest0.nc
|
||||
${ENVIR} $(NCDUMP) -n test1 ctest0.nc > ctest1.cdl
|
||||
@diff test1.cdl ctest1.cdl && \
|
||||
echo "*** $(PROG) -c test successful ***"
|
||||
|
||||
ctest0: ncgen test0.cdl
|
||||
${ENVIR} ./$(PROG) -c -o ctest0.nc test0.cdl > test0.c
|
||||
$(CC) $(CFLAGS) -o $@ test0.c ${LDFLAGS}
|
||||
|
||||
#
|
||||
# test "-f" option of ncgen
|
||||
#
|
||||
ftest: test1.cdl ftest0
|
||||
${ENVIR} ./ftest0
|
||||
${ENVIR} $(NCDUMP) -n test1 ftest0.nc > ftest1.cdl
|
||||
@if diff test1.cdl ftest1.cdl; then \
|
||||
echo "*** ncgen -f test successful ***"; \
|
||||
else \
|
||||
echo "*** ncgen -f test failed " \
|
||||
"(but roundoff differences are OK) ***"; \
|
||||
fi
|
||||
|
||||
ftest0: $(PROG) test0.cdl netcdf.inc
|
||||
${ENVIR} ./$(PROG) -f -o ftest0.nc test0.cdl > test0.f; \
|
||||
$(FC) $(FFLAGS) ${CFLAGS} -o $@ test0.f ${LDFLAGS}
|
||||
|
||||
test1.cdl: test0.nc
|
||||
${ENVIR} $(NCDUMP) -n test1 test0.nc > $@
|
||||
|
||||
test0.nc: $(PROG) test0.cdl
|
||||
${ENVIR} ./$(PROG) -b -o test0.nc test0.cdl
|
||||
|
||||
netcdf.inc:
|
||||
ln -s ../fortran/config/netcdf-fbsd.inc $@
|
19
graphics/hdf5/files/mfhdf/nctest/Makefile
Normal file
19
graphics/hdf5/files/mfhdf/nctest/Makefile
Normal file
@ -0,0 +1,19 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = nctest
|
||||
NOMAN = 1
|
||||
CFLAGS += -I${.CURDIR}/../libsrc
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
SRCS = varget.c vargetg.c varput.c varputg.c vardef.c vartests.c \
|
||||
vputget.c vputgetg.c driver.c cdftests.c dimtests.c rec.c \
|
||||
atttests.c misctest.c add.c error.c emalloc.c val.c slabs.c
|
||||
|
||||
install:
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
test: $(PROG)
|
||||
@ echo "==========================="
|
||||
@ echo "netCDF C interface tests"
|
||||
@ echo "==========================="
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src ./$(PROG)
|
@ -20,7 +20,11 @@ bin/vcompat
|
||||
bin/vmake
|
||||
bin/vshow
|
||||
lib/libmfhdf.a
|
||||
lib/libmfhdf.so.2
|
||||
lib/libmfhdf.so
|
||||
lib/libdf.a
|
||||
lib/libdf.so
|
||||
lib/libdf.so.1
|
||||
include/atom.h
|
||||
include/bitvect.h
|
||||
include/cdeflate.h
|
||||
@ -30,7 +34,6 @@ include/crle.h
|
||||
include/cskphuff.h
|
||||
include/df.h
|
||||
include/dfan.h
|
||||
include/dffunc.f90
|
||||
include/dffunc.inc
|
||||
include/dfgr.h
|
||||
include/dfi.h
|
||||
@ -45,7 +48,6 @@ include/hcomp.h
|
||||
include/hcompi.h
|
||||
include/hconv.h
|
||||
include/hdf.h
|
||||
include/hdf.f90
|
||||
include/hdf.inc
|
||||
include/hdf2netcdf.h
|
||||
include/hdfi.h
|
||||
@ -63,7 +65,6 @@ include/mfgr.h
|
||||
include/mfhdf.h
|
||||
include/mstdio.h
|
||||
include/netcdf.h
|
||||
include/netcdf.f90
|
||||
include/netcdf.inc
|
||||
include/tbbt.h
|
||||
include/vattr.h
|
||||
|
@ -6,63 +6,32 @@
|
||||
# $FreeBSD$
|
||||
#
|
||||
|
||||
DISTNAME= HDF4.1r2
|
||||
PKGNAME= hdf-4.1r2
|
||||
DISTNAME= HDF4.1r3
|
||||
PKGNAME= hdf-4.1r3
|
||||
CATEGORIES= graphics
|
||||
MASTER_SITES= ftp://ftp.ncsa.uiuc.edu/HDF/HDF4.1r2/tar/
|
||||
MASTER_SITES= ftp://ftp.ncsa.uiuc.edu/HDF/HDF/HDF4.1r3/tar/
|
||||
|
||||
MAINTAINER= mi@aldan.algebra.com
|
||||
|
||||
LIB_DEPENDS= jpeg.9:${PORTSDIR}/graphics/jpeg
|
||||
|
||||
MAN1= hdf.1 hdfunpac.1 ncdump.1 ncgen.1
|
||||
MAN3= gr_chunk.3
|
||||
MANCOMPRESSED= maybe
|
||||
|
||||
GNU_CONFIGURE= yes
|
||||
FC?= f77 # Can also be g77 for the newer one
|
||||
MAKE_FLAGS= CC="$(CC)" FC="${FC}" -f
|
||||
MAKE_ENV= pwrkdir=${WRKDIR}
|
||||
#"wrkdir" doesn't work for some reason in the above
|
||||
MAKE_ARGS= PREFIX="${PREFIX}" -j 2
|
||||
|
||||
# This will create dummy Makefiles and some links in the jpeg and libz
|
||||
# subdirectories. This way, we do not need to hunt all the dependencies
|
||||
# out. Shame on the lib's developers, though, this can not be done through
|
||||
# `configure'. -mi
|
||||
pre-build:
|
||||
${AR} -r ${WRKDIR}/libz.a /dev/null
|
||||
${RANLIB} ${WRKDIR}/libz.a
|
||||
test -d ${WRKSRC}/hdf/jpeg.came-with-HDF || \
|
||||
${MV} -f ${WRKSRC}/hdf/jpeg ${WRKSRC}/hdf/jpeg.came-with-HDF
|
||||
-${MKDIR} ${WRKSRC}/hdf/jpeg
|
||||
${RM} -f ${WRKSRC}/hdf/jpeg/Makefile
|
||||
${ECHO} #Phony makefile > ${WRKSRC}/hdf/jpeg/Makefile
|
||||
${ECHO} >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
${ECHO} libjpeg.a: >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\t@${ECHO} Using the already installed JPEG library\n' \
|
||||
>> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\nclean:\n\ttrue\n' >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\ninstall-lib:\n\ttrue\n' >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\ninstall:\n\ttrue\n' >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
-${LN} -s ${PREFIX}/lib/libjpeg* ${WRKSRC}/hdf/jpeg/
|
||||
-${LN} -s ${PREFIX}/include/j*.h ${WRKSRC}/hdf/jpeg/
|
||||
test -d ${WRKSRC}/hdf/zlib.came-with-HDF || \
|
||||
${MV} -f ${WRKSRC}/hdf/zlib ${WRKSRC}/hdf/zlib.came-with-HDF
|
||||
-${MKDIR} ${WRKSRC}/hdf/zlib
|
||||
${RM} -f ${WRKSRC}/hdf/zlib/Makefile
|
||||
${ECHO} #Phony makefile > ${WRKSRC}/hdf/zlib/Makefile
|
||||
${ECHO} >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
${ECHO} libzlib.a: >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\t@${ECHO} Using the already installed ZLIB library\n' \
|
||||
>> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\nclean:\n\ttrue\n' >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\ninstall-lib:\n\ttrue\n' >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\ninstall:\n\ttrue\n' >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
-${LN} -s /usr/lib/${BINFORMAT}/libz* ${WRKSRC}/hdf/zlib/
|
||||
-${LN} -s /usr/include/zconf.h /usr/include/zlib.h ${WRKSRC}/hdf/zlib/
|
||||
post-patch:
|
||||
${RM} -rf ${WRKSRC}/hdf/jpeg
|
||||
${RM} -rf ${WRKSRC}/hdf/zlib
|
||||
|
||||
post-install:
|
||||
@for binary in `${GREP} ^bin/ ${PLIST}` ; do strip ${PREFIX}/$$binary; done
|
||||
do-configure:
|
||||
${CP} -rp ${FILESDIR}/Makefile ${FILESDIR}/hdf \
|
||||
${FILESDIR}/mfhdf ${FILESDIR}/man ${WRKSRC}
|
||||
${LN} -s config/netcdf-fbsd.h ${WRKSRC}/mfhdf/libsrc/netcdf.h
|
||||
${LN} -s netcdf-fbsd.inc ${WRKSRC}/mfhdf/fortran/config/netcdf.inc
|
||||
|
||||
test:
|
||||
cd ${WRKSRC}; make ${MAKE_FLAGS} ${MAKEFILE} test
|
||||
test: build
|
||||
cd ${WRKSRC}; ${MAKE} test
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
@ -1 +1 @@
|
||||
MD5 (HDF4.1r2.tar.gz) = 52814865529791e3a39637fd851a7143
|
||||
MD5 (HDF4.1r3.tar.gz) = 975f84ad8c5910841995c9d339fbd8bb
|
||||
|
16
science/hdf/files/Makefile
Normal file
16
science/hdf/files/Makefile
Normal file
@ -0,0 +1,16 @@
|
||||
# $FreeBSD$
|
||||
|
||||
SUBDIR = hdf mfhdf man
|
||||
#PREFIX ?= /usr/local
|
||||
LIBDIR ?= ${PREFIX}/lib
|
||||
BINDIR ?= ${PREFIX}/bin
|
||||
|
||||
.MAKEFLAGS: PREFIX=${PREFIX} LIBDIR=${LIBDIR} BINDIR=${BINDIR}
|
||||
|
||||
test: all
|
||||
# testing in hdf
|
||||
@cd hdf && ${MAKE} hdf-test
|
||||
# testing in mfhdf
|
||||
@cd mfhdf && ${MAKE} test
|
||||
|
||||
.include <bsd.subdir.mk>
|
9
science/hdf/files/hdf/Makefile
Normal file
9
science/hdf/files/hdf/Makefile
Normal file
@ -0,0 +1,9 @@
|
||||
# $FreeBSD$
|
||||
|
||||
SUBDIR = src util test
|
||||
|
||||
hdf-test: all
|
||||
cd util && ${MAKE} test
|
||||
cd test && ${MAKE} test
|
||||
|
||||
.include <bsd.subdir.mk>
|
54
science/hdf/files/hdf/src/Makefile
Normal file
54
science/hdf/files/hdf/src/Makefile
Normal file
@ -0,0 +1,54 @@
|
||||
# $FreeBSD$
|
||||
|
||||
LIB=df
|
||||
|
||||
# uncomment the line below to avoid building static libraries
|
||||
#INTERNALLIB=YES
|
||||
LIBDIR=${PREFIX}/lib
|
||||
|
||||
SHLIB_MAJOR=1
|
||||
SHLIB_MINOR=0
|
||||
|
||||
SRCS=atom.c bitvect.c cdeflate.c cnbit.c cnone.c crle.c cskphuff.c \
|
||||
df24.c df24f.c dfan.c dfanf.c dfcomp.c dfconv.c dff.c dfgr.c \
|
||||
dfgroup.c dfimcomp.c dfjpeg.c dfkconv.c dfkcray.c dfkfuji.c \
|
||||
dfknat.c dfkswap.c dfkvms.c dfp.c dfpf.c dfr8.c dfr8f.c dfrle.c \
|
||||
dfsd.c dfsdf.c dfstubs.c dfufp2i.c dfunjpeg.c dfutil.c dfutilf.c \
|
||||
dir_mac.c dynarray.c glist.c hbitio.c hblocks.c hbuffer.c \
|
||||
hchunks.c hcomp.c hcompri.c hdfalloc.c herr.c herrf.c hextelt.c \
|
||||
hfile.c hfiledd.c hfilef.c hkit.c linklist.c mcache.c \
|
||||
mfan.c mfanf.c mfgr.c mfgrf.c mstdio.c tbbt.c vattr.c vattrf.c \
|
||||
vconv.c vg.c vgf.c vgp.c vhi.c vio.c vparse.c vrw.c vsfld.c \
|
||||
df24ff.f dfanff.f dfff.f dfpff.f dfr8ff.f dfsdff.f dfufp2if.f \
|
||||
hfileff.f mfgrff.f vattrff.f vgff.f
|
||||
|
||||
CFLAGS += -I${PREFIX}/include
|
||||
FFLAGS += ${CFLAGS}
|
||||
|
||||
.if !defined(OSVERSION)
|
||||
.if exists(/sbin/sysctl)
|
||||
OSVERSION!= /sbin/sysctl -n kern.osreldate
|
||||
.else
|
||||
OSVERSION!= /usr/sbin/sysctl -n kern.osreldate
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if ${OSVERSION} >= 400004
|
||||
LDADD += -L${PREFIX}/lib -ljpeg -lg2c -lz -lm
|
||||
.else
|
||||
LDADD += -L${PREFIX}/lib -ljpeg -lf2c -lz
|
||||
.endif
|
||||
|
||||
afterinstall:
|
||||
install -c -o root -g wheel -m 444 \
|
||||
atom.h bitvect.h cdeflate.h cnbit.h cnone.h crle.h \
|
||||
cskphuff.h df.h dfan.h dfconvrt.h dfgr.h dfi.h dfivms.h \
|
||||
dfrig.h dfsd.h dfstubs.h dfufp2i.h dir_mac.h dynarray.h \
|
||||
glist.h hbitio.h hchunks.h hcomp.h hcompi.h hconv.h \
|
||||
hdf.h hdfi.h herr.h hfile.h hkit.h hlimits.h hntdefs.h \
|
||||
hproto.h hqueue.h htags.h linklist.h maldebug.h mcache.h \
|
||||
mfan.h mfgr.h mstdio.h patchlevel.h sys_dir_mac.h tbbt.h \
|
||||
trace.h vattr.h vg.h vgint.h hdf.inc dffunc.inc \
|
||||
${PREFIX}/include
|
||||
|
||||
.include <bsd.lib.mk>
|
68
science/hdf/files/hdf/test/Makefile
Normal file
68
science/hdf/files/hdf/test/Makefile
Normal file
@ -0,0 +1,68 @@
|
||||
# $FreeBSD$
|
||||
|
||||
CSRCS= rig.c sdstr.c blocks.c an.c anfile.c extelt.c file.c file1.c vers.c \
|
||||
sdmms.c sdnmms.c slab.c litend.c tvset.c comp.c bitio.c tree.c macros.c \
|
||||
conv.c nbit.c man.c mgr.c testhdf.c tbv.c tvsfpack.c chunks.c tvattr.c \
|
||||
buffer.c
|
||||
|
||||
COBJS= ${CSRCS:S/.c/.o/g}
|
||||
|
||||
FSRCS= fortest.c fortestF.f forsupff.f forsupf.c \
|
||||
manf.f mgrf.f slabwf.f t24f.f tanf.f tanfilef.f tpf.f tr8f.f \
|
||||
tsdmmsf.f tsdnmmsf.f tsdnntf.f tsdntf.f tsdstrf.f tstubsf.f \
|
||||
tvsetf.f, tvattrf.f
|
||||
|
||||
FOBJS = fortestF.o forsupff.o forsupf.o \
|
||||
manf.o mgrf.o slabwf.o t24f.o tanf.o tanfilef.o tpf.o tr8f.o \
|
||||
tsdmmsf.o tsdnmmsf.o tsdnntf.o tsdntf.o tsdstrf.o tstubsf.o \
|
||||
tvsetf.o tvattrf.o
|
||||
|
||||
#CFORSUPSRCS = forsupf.c
|
||||
|
||||
HDFLIB = ${.CURDIR}/../src
|
||||
CFLAGS += -I${HDFLIB}
|
||||
FFLAGS += ${CFLAGS} -Nn802 -Nx400
|
||||
|
||||
FTESTS = fortest fortestF
|
||||
|
||||
all: testhdf $(FTESTS) gentest
|
||||
|
||||
#CFORSUPOBJS = forsupf.o
|
||||
|
||||
TESTF = fortest.o
|
||||
|
||||
# directory used by extelt test.
|
||||
TESTDIR = testdir
|
||||
|
||||
$(FOBJS): fortest.inc
|
||||
|
||||
test: atest-hdf
|
||||
|
||||
atest-hdf: testhdf $(FTESTS)
|
||||
-rm -f *.hdf
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../src ./testhdf
|
||||
-rm -f *.hdf
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../src ./fortest
|
||||
|
||||
testhdf: $(COBJS) $(HDFLIB)/libdf.so
|
||||
$(CC) -o testhdf $(COBJS) $(HDFLIB)/libdf.so -lm
|
||||
test -d $(TESTDIR) || mkdir $(TESTDIR)
|
||||
|
||||
fortestF: $(FOBJS) $(HDFLIB)/libdf.so
|
||||
$(FC) $(FFLAGS) -o $@ $(FOBJS) $(HDFLIB)/libdf.so -lm
|
||||
|
||||
fortest: $(HDFLIB)/libdf.so fortest.c $(CHDRS)
|
||||
$(CC) $(CFLAGS) -o fortest fortest.c $(HDFLIB)/libdf.so -lm
|
||||
|
||||
gentest: gentest.c $(HDFLIB)/libdf.so
|
||||
$(CC) $(CFLAGS) gentest.c -o gentest $(HDFLIB)/libdf.so -lm
|
||||
|
||||
clean:
|
||||
-rm -f $(COBJS) testhdf $(FOBJS) $(FTESTS) \
|
||||
core *.hdf ptesthdf qtesthdf gentest *.o fortest.arg $(TESTDIR)/* \
|
||||
.depend
|
||||
|
||||
depend:
|
||||
mkdep ${CFLAGS} ${CSRCS}
|
||||
|
||||
install:
|
30
science/hdf/files/hdf/util/Makefile
Normal file
30
science/hdf/files/hdf/util/Makefile
Normal file
@ -0,0 +1,30 @@
|
||||
# $FreeBSD$
|
||||
|
||||
UTILS = hdf24to8 hdfcomp hdfls hdfpack hdftopal hdftor8 paltohdf \
|
||||
r8tohdf ristosds vmake vshow hdf8to24 hdf2jpeg jpeg2hdf fp2hdf \
|
||||
hdfunpac vcompat
|
||||
|
||||
all: ${UTILS} hdfed
|
||||
|
||||
HEOBJ = he_main.o he_cntrl.o he_disp.o he_file.o
|
||||
|
||||
#CFLAGS += -I${PREFIX}/include -I${.CURDIR}/../src/
|
||||
CFLAGS += -I${.CURDIR}/../src/
|
||||
#LDFLAGS += -L${PREFIX}/lib -ljpeg -L${.CURDIR}/../src/ -ldf -lz
|
||||
LDFLAGS += -L${.CURDIR}/../src/ -ldf
|
||||
|
||||
hdfed: he.h he_proto.h $(HEOBJ)
|
||||
$(CC) $(HEOBJ) $(LDFLAGS) -o hdfed
|
||||
|
||||
test: all fptest
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../src ./testutil.sh
|
||||
|
||||
clean:
|
||||
-rm -f *.o $(UTILS) hdfed fptest
|
||||
-rm -f o* ctx* cb* fptestf .depend
|
||||
|
||||
depend:
|
||||
mkdep ${CFLAGS} ${UTILS:S/$/.c/g} ${HEOBJ:S/.o/.c/g}
|
||||
|
||||
install: all
|
||||
install -c -s -o root -g wheel -m 555 ${UTILS} hdfed ${BINDIR}
|
17
science/hdf/files/man/Makefile
Normal file
17
science/hdf/files/man/Makefile
Normal file
@ -0,0 +1,17 @@
|
||||
# $FreeBSD$
|
||||
|
||||
MANDIR = ${PREFIX}/man/man
|
||||
|
||||
MAN1 = hdf.1 hdfunpac.1
|
||||
MAN3 = gr_chunk.3
|
||||
|
||||
.include <bsd.man.mk>
|
||||
|
||||
install: all-man maninstall
|
||||
|
||||
clean:
|
||||
-rm -f *.gz
|
||||
|
||||
all: all-man
|
||||
|
||||
depend:
|
13
science/hdf/files/mfhdf/Makefile
Normal file
13
science/hdf/files/mfhdf/Makefile
Normal file
@ -0,0 +1,13 @@
|
||||
# $FreeBSD$
|
||||
|
||||
SUBDIR = fortran libsrc ncgen ncdump nctest dumper
|
||||
|
||||
.include <bsd.subdir.mk>
|
||||
|
||||
test: all
|
||||
@for d in ${SUBDIR} ; do \
|
||||
echo "===> testing in $$d"; \
|
||||
cd $$d; \
|
||||
${MAKE} test; \
|
||||
cd ..; \
|
||||
done
|
13
science/hdf/files/mfhdf/dumper/Makefile
Normal file
13
science/hdf/files/mfhdf/dumper/Makefile
Normal file
@ -0,0 +1,13 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = hdp
|
||||
NOMAN = 1
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
CFLAGS += -I${.CURDIR}/../libsrc -I${.CURDIR}/../../hdf/src
|
||||
|
||||
SRCS = hdp.c hdp_list.c hdp_sds.c hdp_util.c hdp_vd.c hdp_vg.c hdp_rig.c show.c hdp_dump.c hdp_gr.c
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
test: ${PROG}
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src sh testhdp.sh
|
42
science/hdf/files/mfhdf/fortran/Makefile
Normal file
42
science/hdf/files/mfhdf/fortran/Makefile
Normal file
@ -0,0 +1,42 @@
|
||||
# $FreeBSD$
|
||||
|
||||
.PATH: ${.CURDIR} ${.CURDIR}/config
|
||||
|
||||
all:
|
||||
|
||||
NOMAN = 1
|
||||
|
||||
FFLAGS += ${CFLAGS} -DNDEBUG -Nn802 -Nx400
|
||||
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
|
||||
afterinstall:
|
||||
install -c -o root -g wheel -m 444 config/netcdf-fbsd.inc \
|
||||
${PREFIX}/include/netcdf.inc
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
ENVIR = env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src
|
||||
|
||||
CLEANFILES+= hdftest hdftest.o ftest ftest-fbsd.o
|
||||
|
||||
config/netcdf.inc:
|
||||
ln -s netcdf-fbsd.inc config/netcdf.inc
|
||||
|
||||
ftest: ftest-fbsd.f config/netcdf.inc
|
||||
${MAKE} PROG=$@ SRCS=ftest-fbsd.f $@
|
||||
|
||||
hdftest: hdftest.f
|
||||
${MAKE} PROG=$@ SRCS=hdftest.f $@
|
||||
|
||||
test: ftest hdftest
|
||||
mkdir -p testdir
|
||||
# ================================
|
||||
# netCDF Fortran interface tests
|
||||
# ================================
|
||||
${ENVIR} ./ftest
|
||||
${ENVIR} ./hdftest > hdfout.new
|
||||
@diff -Bb hdfout.new hdftst.sav && \
|
||||
echo "*** HDF-SD Fortran interface tests passed ***" || \
|
||||
(echo "*** HDF-SD Fortran interface tests failed ***"; \
|
||||
echo "The above differences are OK if small")
|
43
science/hdf/files/mfhdf/libsrc/Makefile
Normal file
43
science/hdf/files/mfhdf/libsrc/Makefile
Normal file
@ -0,0 +1,43 @@
|
||||
# $FreeBSD$
|
||||
|
||||
.PATH: ${.CURDIR} ${.CURDIR}/../fortran/config ${.CURDIR}/../fortran
|
||||
|
||||
SRCS = array.c attr.c cdf.c dim.c file.c iarray.c error.c \
|
||||
globdef.c putget.c putgetg.c sharray.c string.c var.c \
|
||||
hdfsds.c mfsd.c nssdc.c xdrposix.c \
|
||||
jackets-fbsd.c mfsdf.c mfsdff.f
|
||||
|
||||
LIB = mfhdf
|
||||
SHLIB_MAJOR = 2
|
||||
SHLIB_MINOR = 3
|
||||
|
||||
LIBDIR = ${PREFIX}/lib
|
||||
|
||||
# uncomment the line below to avoid building static libraries
|
||||
#INTERNALLIB = Yes
|
||||
|
||||
CFLAGS += -DNDEBUG -DHDF -I${.CURDIR}/../../hdf/src -I${.CURDIR}
|
||||
.if ${MACHINE_ARCH} == "i386"
|
||||
CFLAGS += -DSWAP
|
||||
.endif
|
||||
|
||||
LDADD += -L${.CURDIR}/../../hdf/src -ldf
|
||||
LDFLAGS += -L. -l${LIB} ${LDADD}
|
||||
|
||||
afterinstall:
|
||||
install -c -o root -g wheel -m 444 hdf2netcdf.h local_nc.h \
|
||||
mfhdf.h netcdf.h ${PREFIX}/include
|
||||
|
||||
.include <bsd.lib.mk>
|
||||
|
||||
test: ${SHLIB_NAME} cdftest hdftest
|
||||
env LD_LIBRARY_PATH=${.CURDIR}:${.CURDIR}/../../hdf/src ./cdftest > cdfout.new
|
||||
@diff cdfout.new testout.sav && \
|
||||
echo "*** netCDF passes formatted test ***" || \
|
||||
(echo "*** netCDF fails formatted test ***" ; \
|
||||
echo "The above differences are OK if small")
|
||||
env LD_LIBRARY_PATH=${.CURDIR}:${.CURDIR}/../../hdf/src ./hdftest > hdfout.new
|
||||
@diff hdfout.new hdfout.sav && \
|
||||
echo "*** HDF passes formatted test ***" || \
|
||||
(echo "*** HDF fails formatted test ***" ; \
|
||||
echo "The above differences are OK if small")
|
22
science/hdf/files/mfhdf/ncdump/Makefile
Normal file
22
science/hdf/files/mfhdf/ncdump/Makefile
Normal file
@ -0,0 +1,22 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = ncdump
|
||||
MANDIR = ${PREFIX}/man/man
|
||||
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
CFLAGS += -I${.CURDIR}/../libsrc
|
||||
SRCS = ncdump.c vardata.c dumplib.c
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
ENVIR = env LD_LIBRARY_PATH=${.CURDIR}/../../hdf/src:${.CURDIR}/../libsrc
|
||||
NCGEN = ${.CURDIR}/../ncgen/ncgen
|
||||
|
||||
test: $(PROG) test0.cdl
|
||||
${ENVIR} $(NCGEN) -o test0.nc -n test0.cdl
|
||||
${ENVIR} ./$(PROG) test0.nc > test1.cdl
|
||||
${ENVIR} $(NCGEN) -o test1.nc -n test1.cdl
|
||||
${ENVIR} ./$(PROG) -n test0 test1.nc > test2.cdl
|
||||
@cmp test1.cdl test2.cdl && \
|
||||
echo "*** $(PROGRAM) test successful ***" ; \
|
||||
rm test1.cdl test1.nc test2.cdl
|
72
science/hdf/files/mfhdf/ncgen/Makefile
Normal file
72
science/hdf/files/mfhdf/ncgen/Makefile
Normal file
@ -0,0 +1,72 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = ncgen
|
||||
MANDIR = ${PREFIX}/man/man
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
CFLAGS += -I${.CURDIR}/../libsrc -I${.CURDIR}/../../hdf/src -DNDEBUG
|
||||
SRCS = main.c generate.c load.c ncgentab.c escapes.c \
|
||||
getfill.c init.c close.c genlib.c
|
||||
|
||||
ENVIR = env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src
|
||||
NCDUMP = ${.CURDIR}/../ncdump/ncdump
|
||||
|
||||
test: $(PROG) test0.cdl btest ctest ftest
|
||||
|
||||
ncgenyy.c: ncgen.l
|
||||
${LEX} ${LFLAGS} ncgen.l
|
||||
mv lex.yy.c ncgenyy.c
|
||||
|
||||
ncgentab.c: ncgenyy.c ncgen.y
|
||||
${YACC} ${YFLAGS} ncgen.y
|
||||
mv y.tab.c ncgentab.c
|
||||
mv y.tab.h ncgentab.h
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
#
|
||||
# test "-b" option of ncgen
|
||||
#
|
||||
btest: $(PROG) test0.cdl test1.cdl
|
||||
${ENVIR} ./$(PROG) -b test1.cdl
|
||||
${ENVIR} $(NCDUMP) test1.nc > test2.cdl
|
||||
@diff test1.cdl test2.cdl && \
|
||||
echo "*** $(PROG) -b test successful ***"
|
||||
|
||||
#
|
||||
# test "-c" option of ncgen
|
||||
#
|
||||
ctest: test1.cdl ctest0
|
||||
${ENVIR} ./ctest0 # tests `-c' option, creates ctest0.nc
|
||||
${ENVIR} $(NCDUMP) -n test1 ctest0.nc > ctest1.cdl
|
||||
@diff test1.cdl ctest1.cdl && \
|
||||
echo "*** $(PROG) -c test successful ***"
|
||||
|
||||
ctest0: ncgen test0.cdl
|
||||
${ENVIR} ./$(PROG) -c -o ctest0.nc test0.cdl > test0.c
|
||||
$(CC) $(CFLAGS) -o $@ test0.c ${LDFLAGS}
|
||||
|
||||
#
|
||||
# test "-f" option of ncgen
|
||||
#
|
||||
ftest: test1.cdl ftest0
|
||||
${ENVIR} ./ftest0
|
||||
${ENVIR} $(NCDUMP) -n test1 ftest0.nc > ftest1.cdl
|
||||
@if diff test1.cdl ftest1.cdl; then \
|
||||
echo "*** ncgen -f test successful ***"; \
|
||||
else \
|
||||
echo "*** ncgen -f test failed " \
|
||||
"(but roundoff differences are OK) ***"; \
|
||||
fi
|
||||
|
||||
ftest0: $(PROG) test0.cdl netcdf.inc
|
||||
${ENVIR} ./$(PROG) -f -o ftest0.nc test0.cdl > test0.f; \
|
||||
$(FC) $(FFLAGS) ${CFLAGS} -o $@ test0.f ${LDFLAGS}
|
||||
|
||||
test1.cdl: test0.nc
|
||||
${ENVIR} $(NCDUMP) -n test1 test0.nc > $@
|
||||
|
||||
test0.nc: $(PROG) test0.cdl
|
||||
${ENVIR} ./$(PROG) -b -o test0.nc test0.cdl
|
||||
|
||||
netcdf.inc:
|
||||
ln -s ../fortran/config/netcdf-fbsd.inc $@
|
19
science/hdf/files/mfhdf/nctest/Makefile
Normal file
19
science/hdf/files/mfhdf/nctest/Makefile
Normal file
@ -0,0 +1,19 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = nctest
|
||||
NOMAN = 1
|
||||
CFLAGS += -I${.CURDIR}/../libsrc
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
SRCS = varget.c vargetg.c varput.c varputg.c vardef.c vartests.c \
|
||||
vputget.c vputgetg.c driver.c cdftests.c dimtests.c rec.c \
|
||||
atttests.c misctest.c add.c error.c emalloc.c val.c slabs.c
|
||||
|
||||
install:
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
test: $(PROG)
|
||||
@ echo "==========================="
|
||||
@ echo "netCDF C interface tests"
|
||||
@ echo "==========================="
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src ./$(PROG)
|
@ -20,7 +20,11 @@ bin/vcompat
|
||||
bin/vmake
|
||||
bin/vshow
|
||||
lib/libmfhdf.a
|
||||
lib/libmfhdf.so.2
|
||||
lib/libmfhdf.so
|
||||
lib/libdf.a
|
||||
lib/libdf.so
|
||||
lib/libdf.so.1
|
||||
include/atom.h
|
||||
include/bitvect.h
|
||||
include/cdeflate.h
|
||||
@ -30,7 +34,6 @@ include/crle.h
|
||||
include/cskphuff.h
|
||||
include/df.h
|
||||
include/dfan.h
|
||||
include/dffunc.f90
|
||||
include/dffunc.inc
|
||||
include/dfgr.h
|
||||
include/dfi.h
|
||||
@ -45,7 +48,6 @@ include/hcomp.h
|
||||
include/hcompi.h
|
||||
include/hconv.h
|
||||
include/hdf.h
|
||||
include/hdf.f90
|
||||
include/hdf.inc
|
||||
include/hdf2netcdf.h
|
||||
include/hdfi.h
|
||||
@ -63,7 +65,6 @@ include/mfgr.h
|
||||
include/mfhdf.h
|
||||
include/mstdio.h
|
||||
include/netcdf.h
|
||||
include/netcdf.f90
|
||||
include/netcdf.inc
|
||||
include/tbbt.h
|
||||
include/vattr.h
|
||||
|
@ -6,63 +6,32 @@
|
||||
# $FreeBSD$
|
||||
#
|
||||
|
||||
DISTNAME= HDF4.1r2
|
||||
PKGNAME= hdf-4.1r2
|
||||
DISTNAME= HDF4.1r3
|
||||
PKGNAME= hdf-4.1r3
|
||||
CATEGORIES= graphics
|
||||
MASTER_SITES= ftp://ftp.ncsa.uiuc.edu/HDF/HDF4.1r2/tar/
|
||||
MASTER_SITES= ftp://ftp.ncsa.uiuc.edu/HDF/HDF/HDF4.1r3/tar/
|
||||
|
||||
MAINTAINER= mi@aldan.algebra.com
|
||||
|
||||
LIB_DEPENDS= jpeg.9:${PORTSDIR}/graphics/jpeg
|
||||
|
||||
MAN1= hdf.1 hdfunpac.1 ncdump.1 ncgen.1
|
||||
MAN3= gr_chunk.3
|
||||
MANCOMPRESSED= maybe
|
||||
|
||||
GNU_CONFIGURE= yes
|
||||
FC?= f77 # Can also be g77 for the newer one
|
||||
MAKE_FLAGS= CC="$(CC)" FC="${FC}" -f
|
||||
MAKE_ENV= pwrkdir=${WRKDIR}
|
||||
#"wrkdir" doesn't work for some reason in the above
|
||||
MAKE_ARGS= PREFIX="${PREFIX}" -j 2
|
||||
|
||||
# This will create dummy Makefiles and some links in the jpeg and libz
|
||||
# subdirectories. This way, we do not need to hunt all the dependencies
|
||||
# out. Shame on the lib's developers, though, this can not be done through
|
||||
# `configure'. -mi
|
||||
pre-build:
|
||||
${AR} -r ${WRKDIR}/libz.a /dev/null
|
||||
${RANLIB} ${WRKDIR}/libz.a
|
||||
test -d ${WRKSRC}/hdf/jpeg.came-with-HDF || \
|
||||
${MV} -f ${WRKSRC}/hdf/jpeg ${WRKSRC}/hdf/jpeg.came-with-HDF
|
||||
-${MKDIR} ${WRKSRC}/hdf/jpeg
|
||||
${RM} -f ${WRKSRC}/hdf/jpeg/Makefile
|
||||
${ECHO} #Phony makefile > ${WRKSRC}/hdf/jpeg/Makefile
|
||||
${ECHO} >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
${ECHO} libjpeg.a: >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\t@${ECHO} Using the already installed JPEG library\n' \
|
||||
>> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\nclean:\n\ttrue\n' >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\ninstall-lib:\n\ttrue\n' >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\ninstall:\n\ttrue\n' >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
-${LN} -s ${PREFIX}/lib/libjpeg* ${WRKSRC}/hdf/jpeg/
|
||||
-${LN} -s ${PREFIX}/include/j*.h ${WRKSRC}/hdf/jpeg/
|
||||
test -d ${WRKSRC}/hdf/zlib.came-with-HDF || \
|
||||
${MV} -f ${WRKSRC}/hdf/zlib ${WRKSRC}/hdf/zlib.came-with-HDF
|
||||
-${MKDIR} ${WRKSRC}/hdf/zlib
|
||||
${RM} -f ${WRKSRC}/hdf/zlib/Makefile
|
||||
${ECHO} #Phony makefile > ${WRKSRC}/hdf/zlib/Makefile
|
||||
${ECHO} >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
${ECHO} libzlib.a: >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\t@${ECHO} Using the already installed ZLIB library\n' \
|
||||
>> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\nclean:\n\ttrue\n' >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\ninstall-lib:\n\ttrue\n' >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\ninstall:\n\ttrue\n' >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
-${LN} -s /usr/lib/${BINFORMAT}/libz* ${WRKSRC}/hdf/zlib/
|
||||
-${LN} -s /usr/include/zconf.h /usr/include/zlib.h ${WRKSRC}/hdf/zlib/
|
||||
post-patch:
|
||||
${RM} -rf ${WRKSRC}/hdf/jpeg
|
||||
${RM} -rf ${WRKSRC}/hdf/zlib
|
||||
|
||||
post-install:
|
||||
@for binary in `${GREP} ^bin/ ${PLIST}` ; do strip ${PREFIX}/$$binary; done
|
||||
do-configure:
|
||||
${CP} -rp ${FILESDIR}/Makefile ${FILESDIR}/hdf \
|
||||
${FILESDIR}/mfhdf ${FILESDIR}/man ${WRKSRC}
|
||||
${LN} -s config/netcdf-fbsd.h ${WRKSRC}/mfhdf/libsrc/netcdf.h
|
||||
${LN} -s netcdf-fbsd.inc ${WRKSRC}/mfhdf/fortran/config/netcdf.inc
|
||||
|
||||
test:
|
||||
cd ${WRKSRC}; make ${MAKE_FLAGS} ${MAKEFILE} test
|
||||
test: build
|
||||
cd ${WRKSRC}; ${MAKE} test
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
@ -1 +1 @@
|
||||
MD5 (HDF4.1r2.tar.gz) = 52814865529791e3a39637fd851a7143
|
||||
MD5 (HDF4.1r3.tar.gz) = 975f84ad8c5910841995c9d339fbd8bb
|
||||
|
16
science/hdf5-18/files/Makefile
Normal file
16
science/hdf5-18/files/Makefile
Normal file
@ -0,0 +1,16 @@
|
||||
# $FreeBSD$
|
||||
|
||||
SUBDIR = hdf mfhdf man
|
||||
#PREFIX ?= /usr/local
|
||||
LIBDIR ?= ${PREFIX}/lib
|
||||
BINDIR ?= ${PREFIX}/bin
|
||||
|
||||
.MAKEFLAGS: PREFIX=${PREFIX} LIBDIR=${LIBDIR} BINDIR=${BINDIR}
|
||||
|
||||
test: all
|
||||
# testing in hdf
|
||||
@cd hdf && ${MAKE} hdf-test
|
||||
# testing in mfhdf
|
||||
@cd mfhdf && ${MAKE} test
|
||||
|
||||
.include <bsd.subdir.mk>
|
9
science/hdf5-18/files/hdf/Makefile
Normal file
9
science/hdf5-18/files/hdf/Makefile
Normal file
@ -0,0 +1,9 @@
|
||||
# $FreeBSD$
|
||||
|
||||
SUBDIR = src util test
|
||||
|
||||
hdf-test: all
|
||||
cd util && ${MAKE} test
|
||||
cd test && ${MAKE} test
|
||||
|
||||
.include <bsd.subdir.mk>
|
54
science/hdf5-18/files/hdf/src/Makefile
Normal file
54
science/hdf5-18/files/hdf/src/Makefile
Normal file
@ -0,0 +1,54 @@
|
||||
# $FreeBSD$
|
||||
|
||||
LIB=df
|
||||
|
||||
# uncomment the line below to avoid building static libraries
|
||||
#INTERNALLIB=YES
|
||||
LIBDIR=${PREFIX}/lib
|
||||
|
||||
SHLIB_MAJOR=1
|
||||
SHLIB_MINOR=0
|
||||
|
||||
SRCS=atom.c bitvect.c cdeflate.c cnbit.c cnone.c crle.c cskphuff.c \
|
||||
df24.c df24f.c dfan.c dfanf.c dfcomp.c dfconv.c dff.c dfgr.c \
|
||||
dfgroup.c dfimcomp.c dfjpeg.c dfkconv.c dfkcray.c dfkfuji.c \
|
||||
dfknat.c dfkswap.c dfkvms.c dfp.c dfpf.c dfr8.c dfr8f.c dfrle.c \
|
||||
dfsd.c dfsdf.c dfstubs.c dfufp2i.c dfunjpeg.c dfutil.c dfutilf.c \
|
||||
dir_mac.c dynarray.c glist.c hbitio.c hblocks.c hbuffer.c \
|
||||
hchunks.c hcomp.c hcompri.c hdfalloc.c herr.c herrf.c hextelt.c \
|
||||
hfile.c hfiledd.c hfilef.c hkit.c linklist.c mcache.c \
|
||||
mfan.c mfanf.c mfgr.c mfgrf.c mstdio.c tbbt.c vattr.c vattrf.c \
|
||||
vconv.c vg.c vgf.c vgp.c vhi.c vio.c vparse.c vrw.c vsfld.c \
|
||||
df24ff.f dfanff.f dfff.f dfpff.f dfr8ff.f dfsdff.f dfufp2if.f \
|
||||
hfileff.f mfgrff.f vattrff.f vgff.f
|
||||
|
||||
CFLAGS += -I${PREFIX}/include
|
||||
FFLAGS += ${CFLAGS}
|
||||
|
||||
.if !defined(OSVERSION)
|
||||
.if exists(/sbin/sysctl)
|
||||
OSVERSION!= /sbin/sysctl -n kern.osreldate
|
||||
.else
|
||||
OSVERSION!= /usr/sbin/sysctl -n kern.osreldate
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if ${OSVERSION} >= 400004
|
||||
LDADD += -L${PREFIX}/lib -ljpeg -lg2c -lz -lm
|
||||
.else
|
||||
LDADD += -L${PREFIX}/lib -ljpeg -lf2c -lz
|
||||
.endif
|
||||
|
||||
afterinstall:
|
||||
install -c -o root -g wheel -m 444 \
|
||||
atom.h bitvect.h cdeflate.h cnbit.h cnone.h crle.h \
|
||||
cskphuff.h df.h dfan.h dfconvrt.h dfgr.h dfi.h dfivms.h \
|
||||
dfrig.h dfsd.h dfstubs.h dfufp2i.h dir_mac.h dynarray.h \
|
||||
glist.h hbitio.h hchunks.h hcomp.h hcompi.h hconv.h \
|
||||
hdf.h hdfi.h herr.h hfile.h hkit.h hlimits.h hntdefs.h \
|
||||
hproto.h hqueue.h htags.h linklist.h maldebug.h mcache.h \
|
||||
mfan.h mfgr.h mstdio.h patchlevel.h sys_dir_mac.h tbbt.h \
|
||||
trace.h vattr.h vg.h vgint.h hdf.inc dffunc.inc \
|
||||
${PREFIX}/include
|
||||
|
||||
.include <bsd.lib.mk>
|
68
science/hdf5-18/files/hdf/test/Makefile
Normal file
68
science/hdf5-18/files/hdf/test/Makefile
Normal file
@ -0,0 +1,68 @@
|
||||
# $FreeBSD$
|
||||
|
||||
CSRCS= rig.c sdstr.c blocks.c an.c anfile.c extelt.c file.c file1.c vers.c \
|
||||
sdmms.c sdnmms.c slab.c litend.c tvset.c comp.c bitio.c tree.c macros.c \
|
||||
conv.c nbit.c man.c mgr.c testhdf.c tbv.c tvsfpack.c chunks.c tvattr.c \
|
||||
buffer.c
|
||||
|
||||
COBJS= ${CSRCS:S/.c/.o/g}
|
||||
|
||||
FSRCS= fortest.c fortestF.f forsupff.f forsupf.c \
|
||||
manf.f mgrf.f slabwf.f t24f.f tanf.f tanfilef.f tpf.f tr8f.f \
|
||||
tsdmmsf.f tsdnmmsf.f tsdnntf.f tsdntf.f tsdstrf.f tstubsf.f \
|
||||
tvsetf.f, tvattrf.f
|
||||
|
||||
FOBJS = fortestF.o forsupff.o forsupf.o \
|
||||
manf.o mgrf.o slabwf.o t24f.o tanf.o tanfilef.o tpf.o tr8f.o \
|
||||
tsdmmsf.o tsdnmmsf.o tsdnntf.o tsdntf.o tsdstrf.o tstubsf.o \
|
||||
tvsetf.o tvattrf.o
|
||||
|
||||
#CFORSUPSRCS = forsupf.c
|
||||
|
||||
HDFLIB = ${.CURDIR}/../src
|
||||
CFLAGS += -I${HDFLIB}
|
||||
FFLAGS += ${CFLAGS} -Nn802 -Nx400
|
||||
|
||||
FTESTS = fortest fortestF
|
||||
|
||||
all: testhdf $(FTESTS) gentest
|
||||
|
||||
#CFORSUPOBJS = forsupf.o
|
||||
|
||||
TESTF = fortest.o
|
||||
|
||||
# directory used by extelt test.
|
||||
TESTDIR = testdir
|
||||
|
||||
$(FOBJS): fortest.inc
|
||||
|
||||
test: atest-hdf
|
||||
|
||||
atest-hdf: testhdf $(FTESTS)
|
||||
-rm -f *.hdf
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../src ./testhdf
|
||||
-rm -f *.hdf
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../src ./fortest
|
||||
|
||||
testhdf: $(COBJS) $(HDFLIB)/libdf.so
|
||||
$(CC) -o testhdf $(COBJS) $(HDFLIB)/libdf.so -lm
|
||||
test -d $(TESTDIR) || mkdir $(TESTDIR)
|
||||
|
||||
fortestF: $(FOBJS) $(HDFLIB)/libdf.so
|
||||
$(FC) $(FFLAGS) -o $@ $(FOBJS) $(HDFLIB)/libdf.so -lm
|
||||
|
||||
fortest: $(HDFLIB)/libdf.so fortest.c $(CHDRS)
|
||||
$(CC) $(CFLAGS) -o fortest fortest.c $(HDFLIB)/libdf.so -lm
|
||||
|
||||
gentest: gentest.c $(HDFLIB)/libdf.so
|
||||
$(CC) $(CFLAGS) gentest.c -o gentest $(HDFLIB)/libdf.so -lm
|
||||
|
||||
clean:
|
||||
-rm -f $(COBJS) testhdf $(FOBJS) $(FTESTS) \
|
||||
core *.hdf ptesthdf qtesthdf gentest *.o fortest.arg $(TESTDIR)/* \
|
||||
.depend
|
||||
|
||||
depend:
|
||||
mkdep ${CFLAGS} ${CSRCS}
|
||||
|
||||
install:
|
30
science/hdf5-18/files/hdf/util/Makefile
Normal file
30
science/hdf5-18/files/hdf/util/Makefile
Normal file
@ -0,0 +1,30 @@
|
||||
# $FreeBSD$
|
||||
|
||||
UTILS = hdf24to8 hdfcomp hdfls hdfpack hdftopal hdftor8 paltohdf \
|
||||
r8tohdf ristosds vmake vshow hdf8to24 hdf2jpeg jpeg2hdf fp2hdf \
|
||||
hdfunpac vcompat
|
||||
|
||||
all: ${UTILS} hdfed
|
||||
|
||||
HEOBJ = he_main.o he_cntrl.o he_disp.o he_file.o
|
||||
|
||||
#CFLAGS += -I${PREFIX}/include -I${.CURDIR}/../src/
|
||||
CFLAGS += -I${.CURDIR}/../src/
|
||||
#LDFLAGS += -L${PREFIX}/lib -ljpeg -L${.CURDIR}/../src/ -ldf -lz
|
||||
LDFLAGS += -L${.CURDIR}/../src/ -ldf
|
||||
|
||||
hdfed: he.h he_proto.h $(HEOBJ)
|
||||
$(CC) $(HEOBJ) $(LDFLAGS) -o hdfed
|
||||
|
||||
test: all fptest
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../src ./testutil.sh
|
||||
|
||||
clean:
|
||||
-rm -f *.o $(UTILS) hdfed fptest
|
||||
-rm -f o* ctx* cb* fptestf .depend
|
||||
|
||||
depend:
|
||||
mkdep ${CFLAGS} ${UTILS:S/$/.c/g} ${HEOBJ:S/.o/.c/g}
|
||||
|
||||
install: all
|
||||
install -c -s -o root -g wheel -m 555 ${UTILS} hdfed ${BINDIR}
|
17
science/hdf5-18/files/man/Makefile
Normal file
17
science/hdf5-18/files/man/Makefile
Normal file
@ -0,0 +1,17 @@
|
||||
# $FreeBSD$
|
||||
|
||||
MANDIR = ${PREFIX}/man/man
|
||||
|
||||
MAN1 = hdf.1 hdfunpac.1
|
||||
MAN3 = gr_chunk.3
|
||||
|
||||
.include <bsd.man.mk>
|
||||
|
||||
install: all-man maninstall
|
||||
|
||||
clean:
|
||||
-rm -f *.gz
|
||||
|
||||
all: all-man
|
||||
|
||||
depend:
|
13
science/hdf5-18/files/mfhdf/Makefile
Normal file
13
science/hdf5-18/files/mfhdf/Makefile
Normal file
@ -0,0 +1,13 @@
|
||||
# $FreeBSD$
|
||||
|
||||
SUBDIR = fortran libsrc ncgen ncdump nctest dumper
|
||||
|
||||
.include <bsd.subdir.mk>
|
||||
|
||||
test: all
|
||||
@for d in ${SUBDIR} ; do \
|
||||
echo "===> testing in $$d"; \
|
||||
cd $$d; \
|
||||
${MAKE} test; \
|
||||
cd ..; \
|
||||
done
|
13
science/hdf5-18/files/mfhdf/dumper/Makefile
Normal file
13
science/hdf5-18/files/mfhdf/dumper/Makefile
Normal file
@ -0,0 +1,13 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = hdp
|
||||
NOMAN = 1
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
CFLAGS += -I${.CURDIR}/../libsrc -I${.CURDIR}/../../hdf/src
|
||||
|
||||
SRCS = hdp.c hdp_list.c hdp_sds.c hdp_util.c hdp_vd.c hdp_vg.c hdp_rig.c show.c hdp_dump.c hdp_gr.c
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
test: ${PROG}
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src sh testhdp.sh
|
42
science/hdf5-18/files/mfhdf/fortran/Makefile
Normal file
42
science/hdf5-18/files/mfhdf/fortran/Makefile
Normal file
@ -0,0 +1,42 @@
|
||||
# $FreeBSD$
|
||||
|
||||
.PATH: ${.CURDIR} ${.CURDIR}/config
|
||||
|
||||
all:
|
||||
|
||||
NOMAN = 1
|
||||
|
||||
FFLAGS += ${CFLAGS} -DNDEBUG -Nn802 -Nx400
|
||||
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
|
||||
afterinstall:
|
||||
install -c -o root -g wheel -m 444 config/netcdf-fbsd.inc \
|
||||
${PREFIX}/include/netcdf.inc
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
ENVIR = env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src
|
||||
|
||||
CLEANFILES+= hdftest hdftest.o ftest ftest-fbsd.o
|
||||
|
||||
config/netcdf.inc:
|
||||
ln -s netcdf-fbsd.inc config/netcdf.inc
|
||||
|
||||
ftest: ftest-fbsd.f config/netcdf.inc
|
||||
${MAKE} PROG=$@ SRCS=ftest-fbsd.f $@
|
||||
|
||||
hdftest: hdftest.f
|
||||
${MAKE} PROG=$@ SRCS=hdftest.f $@
|
||||
|
||||
test: ftest hdftest
|
||||
mkdir -p testdir
|
||||
# ================================
|
||||
# netCDF Fortran interface tests
|
||||
# ================================
|
||||
${ENVIR} ./ftest
|
||||
${ENVIR} ./hdftest > hdfout.new
|
||||
@diff -Bb hdfout.new hdftst.sav && \
|
||||
echo "*** HDF-SD Fortran interface tests passed ***" || \
|
||||
(echo "*** HDF-SD Fortran interface tests failed ***"; \
|
||||
echo "The above differences are OK if small")
|
43
science/hdf5-18/files/mfhdf/libsrc/Makefile
Normal file
43
science/hdf5-18/files/mfhdf/libsrc/Makefile
Normal file
@ -0,0 +1,43 @@
|
||||
# $FreeBSD$
|
||||
|
||||
.PATH: ${.CURDIR} ${.CURDIR}/../fortran/config ${.CURDIR}/../fortran
|
||||
|
||||
SRCS = array.c attr.c cdf.c dim.c file.c iarray.c error.c \
|
||||
globdef.c putget.c putgetg.c sharray.c string.c var.c \
|
||||
hdfsds.c mfsd.c nssdc.c xdrposix.c \
|
||||
jackets-fbsd.c mfsdf.c mfsdff.f
|
||||
|
||||
LIB = mfhdf
|
||||
SHLIB_MAJOR = 2
|
||||
SHLIB_MINOR = 3
|
||||
|
||||
LIBDIR = ${PREFIX}/lib
|
||||
|
||||
# uncomment the line below to avoid building static libraries
|
||||
#INTERNALLIB = Yes
|
||||
|
||||
CFLAGS += -DNDEBUG -DHDF -I${.CURDIR}/../../hdf/src -I${.CURDIR}
|
||||
.if ${MACHINE_ARCH} == "i386"
|
||||
CFLAGS += -DSWAP
|
||||
.endif
|
||||
|
||||
LDADD += -L${.CURDIR}/../../hdf/src -ldf
|
||||
LDFLAGS += -L. -l${LIB} ${LDADD}
|
||||
|
||||
afterinstall:
|
||||
install -c -o root -g wheel -m 444 hdf2netcdf.h local_nc.h \
|
||||
mfhdf.h netcdf.h ${PREFIX}/include
|
||||
|
||||
.include <bsd.lib.mk>
|
||||
|
||||
test: ${SHLIB_NAME} cdftest hdftest
|
||||
env LD_LIBRARY_PATH=${.CURDIR}:${.CURDIR}/../../hdf/src ./cdftest > cdfout.new
|
||||
@diff cdfout.new testout.sav && \
|
||||
echo "*** netCDF passes formatted test ***" || \
|
||||
(echo "*** netCDF fails formatted test ***" ; \
|
||||
echo "The above differences are OK if small")
|
||||
env LD_LIBRARY_PATH=${.CURDIR}:${.CURDIR}/../../hdf/src ./hdftest > hdfout.new
|
||||
@diff hdfout.new hdfout.sav && \
|
||||
echo "*** HDF passes formatted test ***" || \
|
||||
(echo "*** HDF fails formatted test ***" ; \
|
||||
echo "The above differences are OK if small")
|
22
science/hdf5-18/files/mfhdf/ncdump/Makefile
Normal file
22
science/hdf5-18/files/mfhdf/ncdump/Makefile
Normal file
@ -0,0 +1,22 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = ncdump
|
||||
MANDIR = ${PREFIX}/man/man
|
||||
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
CFLAGS += -I${.CURDIR}/../libsrc
|
||||
SRCS = ncdump.c vardata.c dumplib.c
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
ENVIR = env LD_LIBRARY_PATH=${.CURDIR}/../../hdf/src:${.CURDIR}/../libsrc
|
||||
NCGEN = ${.CURDIR}/../ncgen/ncgen
|
||||
|
||||
test: $(PROG) test0.cdl
|
||||
${ENVIR} $(NCGEN) -o test0.nc -n test0.cdl
|
||||
${ENVIR} ./$(PROG) test0.nc > test1.cdl
|
||||
${ENVIR} $(NCGEN) -o test1.nc -n test1.cdl
|
||||
${ENVIR} ./$(PROG) -n test0 test1.nc > test2.cdl
|
||||
@cmp test1.cdl test2.cdl && \
|
||||
echo "*** $(PROGRAM) test successful ***" ; \
|
||||
rm test1.cdl test1.nc test2.cdl
|
72
science/hdf5-18/files/mfhdf/ncgen/Makefile
Normal file
72
science/hdf5-18/files/mfhdf/ncgen/Makefile
Normal file
@ -0,0 +1,72 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = ncgen
|
||||
MANDIR = ${PREFIX}/man/man
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
CFLAGS += -I${.CURDIR}/../libsrc -I${.CURDIR}/../../hdf/src -DNDEBUG
|
||||
SRCS = main.c generate.c load.c ncgentab.c escapes.c \
|
||||
getfill.c init.c close.c genlib.c
|
||||
|
||||
ENVIR = env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src
|
||||
NCDUMP = ${.CURDIR}/../ncdump/ncdump
|
||||
|
||||
test: $(PROG) test0.cdl btest ctest ftest
|
||||
|
||||
ncgenyy.c: ncgen.l
|
||||
${LEX} ${LFLAGS} ncgen.l
|
||||
mv lex.yy.c ncgenyy.c
|
||||
|
||||
ncgentab.c: ncgenyy.c ncgen.y
|
||||
${YACC} ${YFLAGS} ncgen.y
|
||||
mv y.tab.c ncgentab.c
|
||||
mv y.tab.h ncgentab.h
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
#
|
||||
# test "-b" option of ncgen
|
||||
#
|
||||
btest: $(PROG) test0.cdl test1.cdl
|
||||
${ENVIR} ./$(PROG) -b test1.cdl
|
||||
${ENVIR} $(NCDUMP) test1.nc > test2.cdl
|
||||
@diff test1.cdl test2.cdl && \
|
||||
echo "*** $(PROG) -b test successful ***"
|
||||
|
||||
#
|
||||
# test "-c" option of ncgen
|
||||
#
|
||||
ctest: test1.cdl ctest0
|
||||
${ENVIR} ./ctest0 # tests `-c' option, creates ctest0.nc
|
||||
${ENVIR} $(NCDUMP) -n test1 ctest0.nc > ctest1.cdl
|
||||
@diff test1.cdl ctest1.cdl && \
|
||||
echo "*** $(PROG) -c test successful ***"
|
||||
|
||||
ctest0: ncgen test0.cdl
|
||||
${ENVIR} ./$(PROG) -c -o ctest0.nc test0.cdl > test0.c
|
||||
$(CC) $(CFLAGS) -o $@ test0.c ${LDFLAGS}
|
||||
|
||||
#
|
||||
# test "-f" option of ncgen
|
||||
#
|
||||
ftest: test1.cdl ftest0
|
||||
${ENVIR} ./ftest0
|
||||
${ENVIR} $(NCDUMP) -n test1 ftest0.nc > ftest1.cdl
|
||||
@if diff test1.cdl ftest1.cdl; then \
|
||||
echo "*** ncgen -f test successful ***"; \
|
||||
else \
|
||||
echo "*** ncgen -f test failed " \
|
||||
"(but roundoff differences are OK) ***"; \
|
||||
fi
|
||||
|
||||
ftest0: $(PROG) test0.cdl netcdf.inc
|
||||
${ENVIR} ./$(PROG) -f -o ftest0.nc test0.cdl > test0.f; \
|
||||
$(FC) $(FFLAGS) ${CFLAGS} -o $@ test0.f ${LDFLAGS}
|
||||
|
||||
test1.cdl: test0.nc
|
||||
${ENVIR} $(NCDUMP) -n test1 test0.nc > $@
|
||||
|
||||
test0.nc: $(PROG) test0.cdl
|
||||
${ENVIR} ./$(PROG) -b -o test0.nc test0.cdl
|
||||
|
||||
netcdf.inc:
|
||||
ln -s ../fortran/config/netcdf-fbsd.inc $@
|
19
science/hdf5-18/files/mfhdf/nctest/Makefile
Normal file
19
science/hdf5-18/files/mfhdf/nctest/Makefile
Normal file
@ -0,0 +1,19 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = nctest
|
||||
NOMAN = 1
|
||||
CFLAGS += -I${.CURDIR}/../libsrc
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
SRCS = varget.c vargetg.c varput.c varputg.c vardef.c vartests.c \
|
||||
vputget.c vputgetg.c driver.c cdftests.c dimtests.c rec.c \
|
||||
atttests.c misctest.c add.c error.c emalloc.c val.c slabs.c
|
||||
|
||||
install:
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
test: $(PROG)
|
||||
@ echo "==========================="
|
||||
@ echo "netCDF C interface tests"
|
||||
@ echo "==========================="
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src ./$(PROG)
|
@ -20,7 +20,11 @@ bin/vcompat
|
||||
bin/vmake
|
||||
bin/vshow
|
||||
lib/libmfhdf.a
|
||||
lib/libmfhdf.so.2
|
||||
lib/libmfhdf.so
|
||||
lib/libdf.a
|
||||
lib/libdf.so
|
||||
lib/libdf.so.1
|
||||
include/atom.h
|
||||
include/bitvect.h
|
||||
include/cdeflate.h
|
||||
@ -30,7 +34,6 @@ include/crle.h
|
||||
include/cskphuff.h
|
||||
include/df.h
|
||||
include/dfan.h
|
||||
include/dffunc.f90
|
||||
include/dffunc.inc
|
||||
include/dfgr.h
|
||||
include/dfi.h
|
||||
@ -45,7 +48,6 @@ include/hcomp.h
|
||||
include/hcompi.h
|
||||
include/hconv.h
|
||||
include/hdf.h
|
||||
include/hdf.f90
|
||||
include/hdf.inc
|
||||
include/hdf2netcdf.h
|
||||
include/hdfi.h
|
||||
@ -63,7 +65,6 @@ include/mfgr.h
|
||||
include/mfhdf.h
|
||||
include/mstdio.h
|
||||
include/netcdf.h
|
||||
include/netcdf.f90
|
||||
include/netcdf.inc
|
||||
include/tbbt.h
|
||||
include/vattr.h
|
||||
|
@ -6,63 +6,32 @@
|
||||
# $FreeBSD$
|
||||
#
|
||||
|
||||
DISTNAME= HDF4.1r2
|
||||
PKGNAME= hdf-4.1r2
|
||||
DISTNAME= HDF4.1r3
|
||||
PKGNAME= hdf-4.1r3
|
||||
CATEGORIES= graphics
|
||||
MASTER_SITES= ftp://ftp.ncsa.uiuc.edu/HDF/HDF4.1r2/tar/
|
||||
MASTER_SITES= ftp://ftp.ncsa.uiuc.edu/HDF/HDF/HDF4.1r3/tar/
|
||||
|
||||
MAINTAINER= mi@aldan.algebra.com
|
||||
|
||||
LIB_DEPENDS= jpeg.9:${PORTSDIR}/graphics/jpeg
|
||||
|
||||
MAN1= hdf.1 hdfunpac.1 ncdump.1 ncgen.1
|
||||
MAN3= gr_chunk.3
|
||||
MANCOMPRESSED= maybe
|
||||
|
||||
GNU_CONFIGURE= yes
|
||||
FC?= f77 # Can also be g77 for the newer one
|
||||
MAKE_FLAGS= CC="$(CC)" FC="${FC}" -f
|
||||
MAKE_ENV= pwrkdir=${WRKDIR}
|
||||
#"wrkdir" doesn't work for some reason in the above
|
||||
MAKE_ARGS= PREFIX="${PREFIX}" -j 2
|
||||
|
||||
# This will create dummy Makefiles and some links in the jpeg and libz
|
||||
# subdirectories. This way, we do not need to hunt all the dependencies
|
||||
# out. Shame on the lib's developers, though, this can not be done through
|
||||
# `configure'. -mi
|
||||
pre-build:
|
||||
${AR} -r ${WRKDIR}/libz.a /dev/null
|
||||
${RANLIB} ${WRKDIR}/libz.a
|
||||
test -d ${WRKSRC}/hdf/jpeg.came-with-HDF || \
|
||||
${MV} -f ${WRKSRC}/hdf/jpeg ${WRKSRC}/hdf/jpeg.came-with-HDF
|
||||
-${MKDIR} ${WRKSRC}/hdf/jpeg
|
||||
${RM} -f ${WRKSRC}/hdf/jpeg/Makefile
|
||||
${ECHO} #Phony makefile > ${WRKSRC}/hdf/jpeg/Makefile
|
||||
${ECHO} >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
${ECHO} libjpeg.a: >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\t@${ECHO} Using the already installed JPEG library\n' \
|
||||
>> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\nclean:\n\ttrue\n' >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\ninstall-lib:\n\ttrue\n' >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
printf '\ninstall:\n\ttrue\n' >> ${WRKSRC}/hdf/jpeg/Makefile
|
||||
-${LN} -s ${PREFIX}/lib/libjpeg* ${WRKSRC}/hdf/jpeg/
|
||||
-${LN} -s ${PREFIX}/include/j*.h ${WRKSRC}/hdf/jpeg/
|
||||
test -d ${WRKSRC}/hdf/zlib.came-with-HDF || \
|
||||
${MV} -f ${WRKSRC}/hdf/zlib ${WRKSRC}/hdf/zlib.came-with-HDF
|
||||
-${MKDIR} ${WRKSRC}/hdf/zlib
|
||||
${RM} -f ${WRKSRC}/hdf/zlib/Makefile
|
||||
${ECHO} #Phony makefile > ${WRKSRC}/hdf/zlib/Makefile
|
||||
${ECHO} >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
${ECHO} libzlib.a: >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\t@${ECHO} Using the already installed ZLIB library\n' \
|
||||
>> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\nclean:\n\ttrue\n' >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\ninstall-lib:\n\ttrue\n' >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
printf '\ninstall:\n\ttrue\n' >> ${WRKSRC}/hdf/zlib/Makefile
|
||||
-${LN} -s /usr/lib/${BINFORMAT}/libz* ${WRKSRC}/hdf/zlib/
|
||||
-${LN} -s /usr/include/zconf.h /usr/include/zlib.h ${WRKSRC}/hdf/zlib/
|
||||
post-patch:
|
||||
${RM} -rf ${WRKSRC}/hdf/jpeg
|
||||
${RM} -rf ${WRKSRC}/hdf/zlib
|
||||
|
||||
post-install:
|
||||
@for binary in `${GREP} ^bin/ ${PLIST}` ; do strip ${PREFIX}/$$binary; done
|
||||
do-configure:
|
||||
${CP} -rp ${FILESDIR}/Makefile ${FILESDIR}/hdf \
|
||||
${FILESDIR}/mfhdf ${FILESDIR}/man ${WRKSRC}
|
||||
${LN} -s config/netcdf-fbsd.h ${WRKSRC}/mfhdf/libsrc/netcdf.h
|
||||
${LN} -s netcdf-fbsd.inc ${WRKSRC}/mfhdf/fortran/config/netcdf.inc
|
||||
|
||||
test:
|
||||
cd ${WRKSRC}; make ${MAKE_FLAGS} ${MAKEFILE} test
|
||||
test: build
|
||||
cd ${WRKSRC}; ${MAKE} test
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
@ -1 +1 @@
|
||||
MD5 (HDF4.1r2.tar.gz) = 52814865529791e3a39637fd851a7143
|
||||
MD5 (HDF4.1r3.tar.gz) = 975f84ad8c5910841995c9d339fbd8bb
|
||||
|
16
science/hdf5/files/Makefile
Normal file
16
science/hdf5/files/Makefile
Normal file
@ -0,0 +1,16 @@
|
||||
# $FreeBSD$
|
||||
|
||||
SUBDIR = hdf mfhdf man
|
||||
#PREFIX ?= /usr/local
|
||||
LIBDIR ?= ${PREFIX}/lib
|
||||
BINDIR ?= ${PREFIX}/bin
|
||||
|
||||
.MAKEFLAGS: PREFIX=${PREFIX} LIBDIR=${LIBDIR} BINDIR=${BINDIR}
|
||||
|
||||
test: all
|
||||
# testing in hdf
|
||||
@cd hdf && ${MAKE} hdf-test
|
||||
# testing in mfhdf
|
||||
@cd mfhdf && ${MAKE} test
|
||||
|
||||
.include <bsd.subdir.mk>
|
9
science/hdf5/files/hdf/Makefile
Normal file
9
science/hdf5/files/hdf/Makefile
Normal file
@ -0,0 +1,9 @@
|
||||
# $FreeBSD$
|
||||
|
||||
SUBDIR = src util test
|
||||
|
||||
hdf-test: all
|
||||
cd util && ${MAKE} test
|
||||
cd test && ${MAKE} test
|
||||
|
||||
.include <bsd.subdir.mk>
|
54
science/hdf5/files/hdf/src/Makefile
Normal file
54
science/hdf5/files/hdf/src/Makefile
Normal file
@ -0,0 +1,54 @@
|
||||
# $FreeBSD$
|
||||
|
||||
LIB=df
|
||||
|
||||
# uncomment the line below to avoid building static libraries
|
||||
#INTERNALLIB=YES
|
||||
LIBDIR=${PREFIX}/lib
|
||||
|
||||
SHLIB_MAJOR=1
|
||||
SHLIB_MINOR=0
|
||||
|
||||
SRCS=atom.c bitvect.c cdeflate.c cnbit.c cnone.c crle.c cskphuff.c \
|
||||
df24.c df24f.c dfan.c dfanf.c dfcomp.c dfconv.c dff.c dfgr.c \
|
||||
dfgroup.c dfimcomp.c dfjpeg.c dfkconv.c dfkcray.c dfkfuji.c \
|
||||
dfknat.c dfkswap.c dfkvms.c dfp.c dfpf.c dfr8.c dfr8f.c dfrle.c \
|
||||
dfsd.c dfsdf.c dfstubs.c dfufp2i.c dfunjpeg.c dfutil.c dfutilf.c \
|
||||
dir_mac.c dynarray.c glist.c hbitio.c hblocks.c hbuffer.c \
|
||||
hchunks.c hcomp.c hcompri.c hdfalloc.c herr.c herrf.c hextelt.c \
|
||||
hfile.c hfiledd.c hfilef.c hkit.c linklist.c mcache.c \
|
||||
mfan.c mfanf.c mfgr.c mfgrf.c mstdio.c tbbt.c vattr.c vattrf.c \
|
||||
vconv.c vg.c vgf.c vgp.c vhi.c vio.c vparse.c vrw.c vsfld.c \
|
||||
df24ff.f dfanff.f dfff.f dfpff.f dfr8ff.f dfsdff.f dfufp2if.f \
|
||||
hfileff.f mfgrff.f vattrff.f vgff.f
|
||||
|
||||
CFLAGS += -I${PREFIX}/include
|
||||
FFLAGS += ${CFLAGS}
|
||||
|
||||
.if !defined(OSVERSION)
|
||||
.if exists(/sbin/sysctl)
|
||||
OSVERSION!= /sbin/sysctl -n kern.osreldate
|
||||
.else
|
||||
OSVERSION!= /usr/sbin/sysctl -n kern.osreldate
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if ${OSVERSION} >= 400004
|
||||
LDADD += -L${PREFIX}/lib -ljpeg -lg2c -lz -lm
|
||||
.else
|
||||
LDADD += -L${PREFIX}/lib -ljpeg -lf2c -lz
|
||||
.endif
|
||||
|
||||
afterinstall:
|
||||
install -c -o root -g wheel -m 444 \
|
||||
atom.h bitvect.h cdeflate.h cnbit.h cnone.h crle.h \
|
||||
cskphuff.h df.h dfan.h dfconvrt.h dfgr.h dfi.h dfivms.h \
|
||||
dfrig.h dfsd.h dfstubs.h dfufp2i.h dir_mac.h dynarray.h \
|
||||
glist.h hbitio.h hchunks.h hcomp.h hcompi.h hconv.h \
|
||||
hdf.h hdfi.h herr.h hfile.h hkit.h hlimits.h hntdefs.h \
|
||||
hproto.h hqueue.h htags.h linklist.h maldebug.h mcache.h \
|
||||
mfan.h mfgr.h mstdio.h patchlevel.h sys_dir_mac.h tbbt.h \
|
||||
trace.h vattr.h vg.h vgint.h hdf.inc dffunc.inc \
|
||||
${PREFIX}/include
|
||||
|
||||
.include <bsd.lib.mk>
|
68
science/hdf5/files/hdf/test/Makefile
Normal file
68
science/hdf5/files/hdf/test/Makefile
Normal file
@ -0,0 +1,68 @@
|
||||
# $FreeBSD$
|
||||
|
||||
CSRCS= rig.c sdstr.c blocks.c an.c anfile.c extelt.c file.c file1.c vers.c \
|
||||
sdmms.c sdnmms.c slab.c litend.c tvset.c comp.c bitio.c tree.c macros.c \
|
||||
conv.c nbit.c man.c mgr.c testhdf.c tbv.c tvsfpack.c chunks.c tvattr.c \
|
||||
buffer.c
|
||||
|
||||
COBJS= ${CSRCS:S/.c/.o/g}
|
||||
|
||||
FSRCS= fortest.c fortestF.f forsupff.f forsupf.c \
|
||||
manf.f mgrf.f slabwf.f t24f.f tanf.f tanfilef.f tpf.f tr8f.f \
|
||||
tsdmmsf.f tsdnmmsf.f tsdnntf.f tsdntf.f tsdstrf.f tstubsf.f \
|
||||
tvsetf.f, tvattrf.f
|
||||
|
||||
FOBJS = fortestF.o forsupff.o forsupf.o \
|
||||
manf.o mgrf.o slabwf.o t24f.o tanf.o tanfilef.o tpf.o tr8f.o \
|
||||
tsdmmsf.o tsdnmmsf.o tsdnntf.o tsdntf.o tsdstrf.o tstubsf.o \
|
||||
tvsetf.o tvattrf.o
|
||||
|
||||
#CFORSUPSRCS = forsupf.c
|
||||
|
||||
HDFLIB = ${.CURDIR}/../src
|
||||
CFLAGS += -I${HDFLIB}
|
||||
FFLAGS += ${CFLAGS} -Nn802 -Nx400
|
||||
|
||||
FTESTS = fortest fortestF
|
||||
|
||||
all: testhdf $(FTESTS) gentest
|
||||
|
||||
#CFORSUPOBJS = forsupf.o
|
||||
|
||||
TESTF = fortest.o
|
||||
|
||||
# directory used by extelt test.
|
||||
TESTDIR = testdir
|
||||
|
||||
$(FOBJS): fortest.inc
|
||||
|
||||
test: atest-hdf
|
||||
|
||||
atest-hdf: testhdf $(FTESTS)
|
||||
-rm -f *.hdf
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../src ./testhdf
|
||||
-rm -f *.hdf
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../src ./fortest
|
||||
|
||||
testhdf: $(COBJS) $(HDFLIB)/libdf.so
|
||||
$(CC) -o testhdf $(COBJS) $(HDFLIB)/libdf.so -lm
|
||||
test -d $(TESTDIR) || mkdir $(TESTDIR)
|
||||
|
||||
fortestF: $(FOBJS) $(HDFLIB)/libdf.so
|
||||
$(FC) $(FFLAGS) -o $@ $(FOBJS) $(HDFLIB)/libdf.so -lm
|
||||
|
||||
fortest: $(HDFLIB)/libdf.so fortest.c $(CHDRS)
|
||||
$(CC) $(CFLAGS) -o fortest fortest.c $(HDFLIB)/libdf.so -lm
|
||||
|
||||
gentest: gentest.c $(HDFLIB)/libdf.so
|
||||
$(CC) $(CFLAGS) gentest.c -o gentest $(HDFLIB)/libdf.so -lm
|
||||
|
||||
clean:
|
||||
-rm -f $(COBJS) testhdf $(FOBJS) $(FTESTS) \
|
||||
core *.hdf ptesthdf qtesthdf gentest *.o fortest.arg $(TESTDIR)/* \
|
||||
.depend
|
||||
|
||||
depend:
|
||||
mkdep ${CFLAGS} ${CSRCS}
|
||||
|
||||
install:
|
30
science/hdf5/files/hdf/util/Makefile
Normal file
30
science/hdf5/files/hdf/util/Makefile
Normal file
@ -0,0 +1,30 @@
|
||||
# $FreeBSD$
|
||||
|
||||
UTILS = hdf24to8 hdfcomp hdfls hdfpack hdftopal hdftor8 paltohdf \
|
||||
r8tohdf ristosds vmake vshow hdf8to24 hdf2jpeg jpeg2hdf fp2hdf \
|
||||
hdfunpac vcompat
|
||||
|
||||
all: ${UTILS} hdfed
|
||||
|
||||
HEOBJ = he_main.o he_cntrl.o he_disp.o he_file.o
|
||||
|
||||
#CFLAGS += -I${PREFIX}/include -I${.CURDIR}/../src/
|
||||
CFLAGS += -I${.CURDIR}/../src/
|
||||
#LDFLAGS += -L${PREFIX}/lib -ljpeg -L${.CURDIR}/../src/ -ldf -lz
|
||||
LDFLAGS += -L${.CURDIR}/../src/ -ldf
|
||||
|
||||
hdfed: he.h he_proto.h $(HEOBJ)
|
||||
$(CC) $(HEOBJ) $(LDFLAGS) -o hdfed
|
||||
|
||||
test: all fptest
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../src ./testutil.sh
|
||||
|
||||
clean:
|
||||
-rm -f *.o $(UTILS) hdfed fptest
|
||||
-rm -f o* ctx* cb* fptestf .depend
|
||||
|
||||
depend:
|
||||
mkdep ${CFLAGS} ${UTILS:S/$/.c/g} ${HEOBJ:S/.o/.c/g}
|
||||
|
||||
install: all
|
||||
install -c -s -o root -g wheel -m 555 ${UTILS} hdfed ${BINDIR}
|
17
science/hdf5/files/man/Makefile
Normal file
17
science/hdf5/files/man/Makefile
Normal file
@ -0,0 +1,17 @@
|
||||
# $FreeBSD$
|
||||
|
||||
MANDIR = ${PREFIX}/man/man
|
||||
|
||||
MAN1 = hdf.1 hdfunpac.1
|
||||
MAN3 = gr_chunk.3
|
||||
|
||||
.include <bsd.man.mk>
|
||||
|
||||
install: all-man maninstall
|
||||
|
||||
clean:
|
||||
-rm -f *.gz
|
||||
|
||||
all: all-man
|
||||
|
||||
depend:
|
13
science/hdf5/files/mfhdf/Makefile
Normal file
13
science/hdf5/files/mfhdf/Makefile
Normal file
@ -0,0 +1,13 @@
|
||||
# $FreeBSD$
|
||||
|
||||
SUBDIR = fortran libsrc ncgen ncdump nctest dumper
|
||||
|
||||
.include <bsd.subdir.mk>
|
||||
|
||||
test: all
|
||||
@for d in ${SUBDIR} ; do \
|
||||
echo "===> testing in $$d"; \
|
||||
cd $$d; \
|
||||
${MAKE} test; \
|
||||
cd ..; \
|
||||
done
|
13
science/hdf5/files/mfhdf/dumper/Makefile
Normal file
13
science/hdf5/files/mfhdf/dumper/Makefile
Normal file
@ -0,0 +1,13 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = hdp
|
||||
NOMAN = 1
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
CFLAGS += -I${.CURDIR}/../libsrc -I${.CURDIR}/../../hdf/src
|
||||
|
||||
SRCS = hdp.c hdp_list.c hdp_sds.c hdp_util.c hdp_vd.c hdp_vg.c hdp_rig.c show.c hdp_dump.c hdp_gr.c
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
test: ${PROG}
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src sh testhdp.sh
|
42
science/hdf5/files/mfhdf/fortran/Makefile
Normal file
42
science/hdf5/files/mfhdf/fortran/Makefile
Normal file
@ -0,0 +1,42 @@
|
||||
# $FreeBSD$
|
||||
|
||||
.PATH: ${.CURDIR} ${.CURDIR}/config
|
||||
|
||||
all:
|
||||
|
||||
NOMAN = 1
|
||||
|
||||
FFLAGS += ${CFLAGS} -DNDEBUG -Nn802 -Nx400
|
||||
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
|
||||
afterinstall:
|
||||
install -c -o root -g wheel -m 444 config/netcdf-fbsd.inc \
|
||||
${PREFIX}/include/netcdf.inc
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
ENVIR = env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src
|
||||
|
||||
CLEANFILES+= hdftest hdftest.o ftest ftest-fbsd.o
|
||||
|
||||
config/netcdf.inc:
|
||||
ln -s netcdf-fbsd.inc config/netcdf.inc
|
||||
|
||||
ftest: ftest-fbsd.f config/netcdf.inc
|
||||
${MAKE} PROG=$@ SRCS=ftest-fbsd.f $@
|
||||
|
||||
hdftest: hdftest.f
|
||||
${MAKE} PROG=$@ SRCS=hdftest.f $@
|
||||
|
||||
test: ftest hdftest
|
||||
mkdir -p testdir
|
||||
# ================================
|
||||
# netCDF Fortran interface tests
|
||||
# ================================
|
||||
${ENVIR} ./ftest
|
||||
${ENVIR} ./hdftest > hdfout.new
|
||||
@diff -Bb hdfout.new hdftst.sav && \
|
||||
echo "*** HDF-SD Fortran interface tests passed ***" || \
|
||||
(echo "*** HDF-SD Fortran interface tests failed ***"; \
|
||||
echo "The above differences are OK if small")
|
43
science/hdf5/files/mfhdf/libsrc/Makefile
Normal file
43
science/hdf5/files/mfhdf/libsrc/Makefile
Normal file
@ -0,0 +1,43 @@
|
||||
# $FreeBSD$
|
||||
|
||||
.PATH: ${.CURDIR} ${.CURDIR}/../fortran/config ${.CURDIR}/../fortran
|
||||
|
||||
SRCS = array.c attr.c cdf.c dim.c file.c iarray.c error.c \
|
||||
globdef.c putget.c putgetg.c sharray.c string.c var.c \
|
||||
hdfsds.c mfsd.c nssdc.c xdrposix.c \
|
||||
jackets-fbsd.c mfsdf.c mfsdff.f
|
||||
|
||||
LIB = mfhdf
|
||||
SHLIB_MAJOR = 2
|
||||
SHLIB_MINOR = 3
|
||||
|
||||
LIBDIR = ${PREFIX}/lib
|
||||
|
||||
# uncomment the line below to avoid building static libraries
|
||||
#INTERNALLIB = Yes
|
||||
|
||||
CFLAGS += -DNDEBUG -DHDF -I${.CURDIR}/../../hdf/src -I${.CURDIR}
|
||||
.if ${MACHINE_ARCH} == "i386"
|
||||
CFLAGS += -DSWAP
|
||||
.endif
|
||||
|
||||
LDADD += -L${.CURDIR}/../../hdf/src -ldf
|
||||
LDFLAGS += -L. -l${LIB} ${LDADD}
|
||||
|
||||
afterinstall:
|
||||
install -c -o root -g wheel -m 444 hdf2netcdf.h local_nc.h \
|
||||
mfhdf.h netcdf.h ${PREFIX}/include
|
||||
|
||||
.include <bsd.lib.mk>
|
||||
|
||||
test: ${SHLIB_NAME} cdftest hdftest
|
||||
env LD_LIBRARY_PATH=${.CURDIR}:${.CURDIR}/../../hdf/src ./cdftest > cdfout.new
|
||||
@diff cdfout.new testout.sav && \
|
||||
echo "*** netCDF passes formatted test ***" || \
|
||||
(echo "*** netCDF fails formatted test ***" ; \
|
||||
echo "The above differences are OK if small")
|
||||
env LD_LIBRARY_PATH=${.CURDIR}:${.CURDIR}/../../hdf/src ./hdftest > hdfout.new
|
||||
@diff hdfout.new hdfout.sav && \
|
||||
echo "*** HDF passes formatted test ***" || \
|
||||
(echo "*** HDF fails formatted test ***" ; \
|
||||
echo "The above differences are OK if small")
|
22
science/hdf5/files/mfhdf/ncdump/Makefile
Normal file
22
science/hdf5/files/mfhdf/ncdump/Makefile
Normal file
@ -0,0 +1,22 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = ncdump
|
||||
MANDIR = ${PREFIX}/man/man
|
||||
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
CFLAGS += -I${.CURDIR}/../libsrc
|
||||
SRCS = ncdump.c vardata.c dumplib.c
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
ENVIR = env LD_LIBRARY_PATH=${.CURDIR}/../../hdf/src:${.CURDIR}/../libsrc
|
||||
NCGEN = ${.CURDIR}/../ncgen/ncgen
|
||||
|
||||
test: $(PROG) test0.cdl
|
||||
${ENVIR} $(NCGEN) -o test0.nc -n test0.cdl
|
||||
${ENVIR} ./$(PROG) test0.nc > test1.cdl
|
||||
${ENVIR} $(NCGEN) -o test1.nc -n test1.cdl
|
||||
${ENVIR} ./$(PROG) -n test0 test1.nc > test2.cdl
|
||||
@cmp test1.cdl test2.cdl && \
|
||||
echo "*** $(PROGRAM) test successful ***" ; \
|
||||
rm test1.cdl test1.nc test2.cdl
|
72
science/hdf5/files/mfhdf/ncgen/Makefile
Normal file
72
science/hdf5/files/mfhdf/ncgen/Makefile
Normal file
@ -0,0 +1,72 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = ncgen
|
||||
MANDIR = ${PREFIX}/man/man
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
CFLAGS += -I${.CURDIR}/../libsrc -I${.CURDIR}/../../hdf/src -DNDEBUG
|
||||
SRCS = main.c generate.c load.c ncgentab.c escapes.c \
|
||||
getfill.c init.c close.c genlib.c
|
||||
|
||||
ENVIR = env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src
|
||||
NCDUMP = ${.CURDIR}/../ncdump/ncdump
|
||||
|
||||
test: $(PROG) test0.cdl btest ctest ftest
|
||||
|
||||
ncgenyy.c: ncgen.l
|
||||
${LEX} ${LFLAGS} ncgen.l
|
||||
mv lex.yy.c ncgenyy.c
|
||||
|
||||
ncgentab.c: ncgenyy.c ncgen.y
|
||||
${YACC} ${YFLAGS} ncgen.y
|
||||
mv y.tab.c ncgentab.c
|
||||
mv y.tab.h ncgentab.h
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
#
|
||||
# test "-b" option of ncgen
|
||||
#
|
||||
btest: $(PROG) test0.cdl test1.cdl
|
||||
${ENVIR} ./$(PROG) -b test1.cdl
|
||||
${ENVIR} $(NCDUMP) test1.nc > test2.cdl
|
||||
@diff test1.cdl test2.cdl && \
|
||||
echo "*** $(PROG) -b test successful ***"
|
||||
|
||||
#
|
||||
# test "-c" option of ncgen
|
||||
#
|
||||
ctest: test1.cdl ctest0
|
||||
${ENVIR} ./ctest0 # tests `-c' option, creates ctest0.nc
|
||||
${ENVIR} $(NCDUMP) -n test1 ctest0.nc > ctest1.cdl
|
||||
@diff test1.cdl ctest1.cdl && \
|
||||
echo "*** $(PROG) -c test successful ***"
|
||||
|
||||
ctest0: ncgen test0.cdl
|
||||
${ENVIR} ./$(PROG) -c -o ctest0.nc test0.cdl > test0.c
|
||||
$(CC) $(CFLAGS) -o $@ test0.c ${LDFLAGS}
|
||||
|
||||
#
|
||||
# test "-f" option of ncgen
|
||||
#
|
||||
ftest: test1.cdl ftest0
|
||||
${ENVIR} ./ftest0
|
||||
${ENVIR} $(NCDUMP) -n test1 ftest0.nc > ftest1.cdl
|
||||
@if diff test1.cdl ftest1.cdl; then \
|
||||
echo "*** ncgen -f test successful ***"; \
|
||||
else \
|
||||
echo "*** ncgen -f test failed " \
|
||||
"(but roundoff differences are OK) ***"; \
|
||||
fi
|
||||
|
||||
ftest0: $(PROG) test0.cdl netcdf.inc
|
||||
${ENVIR} ./$(PROG) -f -o ftest0.nc test0.cdl > test0.f; \
|
||||
$(FC) $(FFLAGS) ${CFLAGS} -o $@ test0.f ${LDFLAGS}
|
||||
|
||||
test1.cdl: test0.nc
|
||||
${ENVIR} $(NCDUMP) -n test1 test0.nc > $@
|
||||
|
||||
test0.nc: $(PROG) test0.cdl
|
||||
${ENVIR} ./$(PROG) -b -o test0.nc test0.cdl
|
||||
|
||||
netcdf.inc:
|
||||
ln -s ../fortran/config/netcdf-fbsd.inc $@
|
19
science/hdf5/files/mfhdf/nctest/Makefile
Normal file
19
science/hdf5/files/mfhdf/nctest/Makefile
Normal file
@ -0,0 +1,19 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PROG = nctest
|
||||
NOMAN = 1
|
||||
CFLAGS += -I${.CURDIR}/../libsrc
|
||||
LDFLAGS += -L${.CURDIR}/../libsrc -L${.CURDIR}/../../hdf/src -lmfhdf -ldf
|
||||
SRCS = varget.c vargetg.c varput.c varputg.c vardef.c vartests.c \
|
||||
vputget.c vputgetg.c driver.c cdftests.c dimtests.c rec.c \
|
||||
atttests.c misctest.c add.c error.c emalloc.c val.c slabs.c
|
||||
|
||||
install:
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
test: $(PROG)
|
||||
@ echo "==========================="
|
||||
@ echo "netCDF C interface tests"
|
||||
@ echo "==========================="
|
||||
env LD_LIBRARY_PATH=${.CURDIR}/../libsrc:${.CURDIR}/../../hdf/src ./$(PROG)
|
@ -20,7 +20,11 @@ bin/vcompat
|
||||
bin/vmake
|
||||
bin/vshow
|
||||
lib/libmfhdf.a
|
||||
lib/libmfhdf.so.2
|
||||
lib/libmfhdf.so
|
||||
lib/libdf.a
|
||||
lib/libdf.so
|
||||
lib/libdf.so.1
|
||||
include/atom.h
|
||||
include/bitvect.h
|
||||
include/cdeflate.h
|
||||
@ -30,7 +34,6 @@ include/crle.h
|
||||
include/cskphuff.h
|
||||
include/df.h
|
||||
include/dfan.h
|
||||
include/dffunc.f90
|
||||
include/dffunc.inc
|
||||
include/dfgr.h
|
||||
include/dfi.h
|
||||
@ -45,7 +48,6 @@ include/hcomp.h
|
||||
include/hcompi.h
|
||||
include/hconv.h
|
||||
include/hdf.h
|
||||
include/hdf.f90
|
||||
include/hdf.inc
|
||||
include/hdf2netcdf.h
|
||||
include/hdfi.h
|
||||
@ -63,7 +65,6 @@ include/mfgr.h
|
||||
include/mfhdf.h
|
||||
include/mstdio.h
|
||||
include/netcdf.h
|
||||
include/netcdf.f90
|
||||
include/netcdf.inc
|
||||
include/tbbt.h
|
||||
include/vattr.h
|
||||
|
Loading…
Reference in New Issue
Block a user