netcdf-c/nc_test/Make0

35 lines
826 B
Plaintext
Raw Normal View History

# Test c output
2015-08-16 06:26:35 +08:00
T=t
#CMD=valgrind --leak-check=full
2015-08-16 06:26:35 +08:00
#CMD=gdb --args
CC=mpicc
CFLAGS=-g -O0 -I.. -I../include
2015-08-16 06:26:35 +08:00
#LDFLAGS=../liblib/.libs/libnetcdf.a -L/usr/local/lib -lhdf5_hl -lhdf5 -lz -lm -lcurl
LDFLAGS=-L/usr/local/lib -lhdf5_hl -lhdf5 -lz ../liblib/.libs/libnetcdf.a -ldl -lm -lcurl
CC=/usr/local/bin/mpicc
LDFLAGS=-L/usr/local/lib -lhdf5_hl -lhdf5 -lz ../liblib/.libs/libnetcdf.a -ldl -lcurl -lpnetcdf -lmpich -lm
# cd .. ; ${MAKE} all
2015-08-16 06:26:35 +08:00
LLP=/usr/local/lib:${LD_LIBRARY_PATH}
all::
2015-08-16 06:26:35 +08:00
echo ${LD_RUN_PATH}
export LD_LIBRARY_PATH=${LLP}; export CFLAGS; export LDFLAGS; \
${CC} -o t ${CFLAGS} ${T}.c ${LDFLAGS}; \
${CMD} ./t
cpp::
${CC} -E ${CFLAGS} ${T}.c > ${T}.txt
2015-08-16 06:26:35 +08:00
all::
echo ${LD_RUN_PATH}
export LD_LIBRARY_PATH=${LLP}; export CFLAGS; export LDFLAGS; \
gcc -o t ${CFLAGS} ${T}.c ${LDFLAGS}; \
${CMD} ./t