Skip to content

Commit

Permalink
fix compilation issue
Browse files Browse the repository at this point in the history
  • Loading branch information
Sheng Di committed Jan 23, 2020
1 parent a1a252b commit 6061e85
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions NetCDFReader/Makefile.linux
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
## COMPILERS
CC = gcc

SZPATH =/home/sdi/Install/sz-1.4.13-install
SZPATH =/ccs/home/shdi/SZ-install
SZINC = -I$(SZPATH)/include
SZFLAGS = -L$(SZPATH)/lib -lSZ -lzlib
SZFLAGS = -L$(SZPATH)/lib -lSZ -lzlib -lzstd -Wl,-rpath,${SZPATH}/lib

#Please modify NETCDFPATH based on your own installation of netcdf
NETCDFPATH =/home/sdi/Install/netcdf-4.5.0-install
NETCDFPATH =/ccs/home/shdi/netcdf-install

NETCDFINC = -I$(NETCDFPATH)/include
NETCDFFLAGS = -L$(NETCDFPATH)/lib -lnetcdf
NETCDFFLAGS = -L$(NETCDFPATH)/lib -lnetcdf -Wl,-rpath,$(NETCDFPATH)/lib
SO_FLAGS = -shared
INC = -I./include
FLAGS = -lnetcdfreader
Expand All @@ -29,7 +29,7 @@ libnetcdfreader.so: $(OBJS)
$(CC) $(SO_FLAGS) -Wl,-soname,libnetcdfreader.so -o $@ $^ -lc $(NETCDFFLAGS)

test/test_NetCDFReader: test/test_NetCDFReader.c
$(CC) -o test/test_NetCDFReader test/test_NetCDFReader.c $(INC) -L. $(FLAGS) $(NETCDFINC) $(NETCDFFLAGS) $(SZINC) $(SZFLAGS)
$(CC) -o test/test_NetCDFReader test/test_NetCDFReader.c $(INC) -L. $(FLAGS) $(NETCDFINC) $(NETCDFFLAGS) $(SZINC) $(SZFLAGS) -Wl,-rpath,$(realpath .)

clean:
rm -rf src/*.o *.a *.so test/test_NetCDFReader

0 comments on commit 6061e85

Please sign in to comment.