mirror of
https://github.com/Unidata/netcdf-c.git
synced 2024-12-27 08:49:16 +08:00
3c7ffcc6d1
Fix https://github.com/Unidata/netcdf-c/issues/962 1. remove the --disable-diskless option since it is no longer needed. Similarly for CMakeLists.txt. 2. Fixed nc4files.c where BAIL and return were mixed leading to situation where cleanup code was not being invoked. This probably occurs elsewhere, but I did not find any specifically.
38 lines
895 B
Plaintext
38 lines
895 B
Plaintext
# Test c output
|
|
T=tst_diskless
|
|
|
|
#ARGS=t
|
|
|
|
#CMD=valgrind --leak-check=full
|
|
#CMD=export NETCDF_LOG_LEVEL=5 ;gdb --args
|
|
CMD=gdb --args
|
|
|
|
#PAR=1
|
|
|
|
CFLAGS=-Wall -Wno-unused-variable -Wno-unused-function -g -O0 -I.. -I../include
|
|
|
|
ifdef PAR
|
|
CC=mpicc
|
|
#CC=/usr/local/bin/mpicc
|
|
LDFLAGS=../liblib/.libs/libnetcdf.a -L/usr/local/lib -lhdf5_hl -lhdf5 -lz -ldl -lcurl -lpnetcdf -lmpich -lm
|
|
else
|
|
CC=gcc
|
|
#LDFLAGS=../liblib/.libs/libnetcdf.a -L/usr/local/lib -lhdf5_hl -lhdf5 -lz -lm -lcurl
|
|
LDFLAGS=../liblib/.libs/libnetcdf.a -L/usr/local/lib -lhdf5_hl -lhdf5 -lz -ldl -lm -lcurl
|
|
endif
|
|
|
|
# cd .. ; ${MAKE} all
|
|
|
|
LLP=/usr/local/lib:${LD_LIBRARY_PATH}
|
|
|
|
all:: cmp
|
|
export LD_LIBRARY_PATH=${LLP}; export CFLAGS; export LDFLAGS; \
|
|
${CMD} ./t ${ARGS}
|
|
|
|
cmp::
|
|
export LD_LIBRARY_PATH=${LLP}; export CFLAGS; export LDFLAGS; \
|
|
${CC} -o t ${CFLAGS} ${T}.c ${SRC} ${LDFLAGS}; \
|
|
|
|
cpp::
|
|
${CC} -E ${CFLAGS} ${T}.c > ${T}.txt
|