20 lines
268 B
Makefile
20 lines
268 B
Makefile
|
.PHONY: all clean
|
||
|
|
||
|
CC := cc
|
||
|
|
||
|
CFLAGS :=
|
||
|
LDFLAGS :=
|
||
|
|
||
|
CFLAGS += $(shell pkg-config --cflags mpi)
|
||
|
LDFLAGS += $(shell pkg-config --libs mpi)
|
||
|
|
||
|
all: qs_mpi
|
||
|
|
||
|
qs_mpi: qs_mpi.o
|
||
|
$(CC) $(LDFLAGS) -o $@ $^
|
||
|
|
||
|
qs_mpi.o: qs_mpi.c
|
||
|
$(CC) $(CFLAGS) -c -o $@ $^
|
||
|
|
||
|
clean:
|
||
|
rm -f qs_mpi *.o
|