Skip to content

Commit

Permalink
Update Makefile for the new version of GNU compiler which require lib…
Browse files Browse the repository at this point in the history
…rary loading flags put at the end in the link command
  • Loading branch information
lwang-astro committed Dec 16, 2015
1 parent 5bd01cb commit cf3f085
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@ OBJECTS = $(SOURCE:.f=.o)

mcluster_sse: $(OBJECTS) $(LFLAGS)
$(CC) -c main.c -D SSE -lm
$(CC) $(CFLAGS) $(OBJECTS) main.o -o mcluster_sse -lm
$(CC) $(OBJECTS) main.o -o mcluster_sse -lm $(CFLAGS)

mcluster_gpu: $(OBJECTS) $(LFLAGS) gpupot.gpu.o main.c
$(CC) -c main.c -D SSE -D GPU -lm -I$(CUDA_PATH)/include
$(CC) $(CFLAGS) $(OBJECTS) main.o gpupot.gpu.o -L$(CUDA_PATH)/lib64 -lcudart -lstdc++ -o mcluster_gpu -lm
$(CC) $(OBJECTS) main.o gpupot.gpu.o -o mcluster_gpu -L$(CUDA_PATH)/lib64 -lcudart -lstdc++ -lm $(CFLAGS)

mcluster:
$(CC) -o mcluster main.c -lm
Expand Down

0 comments on commit cf3f085

Please sign in to comment.