netcdf-c/ncdump/Make0
Dennis Heimbigner 39e9cd0ffe Fix issues with Github pull request 187
(https://github.com/Unidata/netcdf-c/pull/187)
Primary problem was cmake build errors.
2016-01-08 12:55:11 -07:00

25 lines
600 B
Plaintext

# Test c output
T=tst_dimsizes
#CMD=valgrind --leak-check=full
#CMD=gdb --args
#MPI=1
LLP="LD_LIBRARY_PATH=/usr/local/lib"
ifndef MPI
CC=gcc
CFLAGS=-g -O0 -I.. -I../include
LDFLAGS=../liblib/.libs/libnetcdf.a -L/usr/local/lib -lhdf5_hl -lhdf5 -lz -lm -lcurl
else
CC=/usr/local/bin/mpicc
LDFLAGS=../liblib/.libs/libnetcdf.a -L/usr/local/lib -lhdf5_hl -lhdf5 -lz ../liblib/.libs/libnetcdf.a -ldl -lcurl -lpnetcdf -lmpich -lm
endif
all::
export ${LLP}; export CFLAGS; export LDFLAGS; \
${CC} -o $T.exe ${CFLAGS} ${T}.c ${LDFLAGS}; \
${CMD} ./$T.exe
cpp::
${CC} -E ${CFLAGS} ${T}.c > ${T}.txt