forked from LPD-EPFL/ASCYLIB
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
47 lines (31 loc) · 1.18 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
ROOT = ../..
include $(ROOT)/common/Makefile.common
ALGO_O = stack-lockb.o
ALGO_C = stack-lockb.c
ifeq ($(BIN_SUFFIX),_gl)
NEW_SUFFIX = _tas
endif
BINS = "$(BINDIR)/lb-st_lock$(NEW_SUFFIX)"
PROF = $(ROOT)/src
.PHONY: all clean
all: main
measurements.o:
$(CC) $(CFLAGS) -c -o $(BUILDIR)/measurements.o $(PROF)/measurements.c
ssalloc.o:
$(CC) $(CFLAGS) -c -o $(BUILDIR)/ssalloc.o $(PROF)/ssalloc.c
htlock.o:
$(CC) $(CFLAGS) -c -o $(BUILDIR)/htlock.o $(PROF)/htlock.c
clh.o:
$(CC) $(CFLAGS) -c -o $(BUILDIR)/clh.o $(PROF)/clh.c
stack-lock.o:
$(CC) $(CFLAGS) -c -o $(BUILDIR)/stack-lock.o stack-lock.c
$(ALGO_O): stack-lock.h
$(CC) $(CFLAGS) -c -o $(BUILDIR)/$(ALGO_O) $(ALGO_C)
intset.o: stack-lock.h stack-lock.h htlock.o clh.o
$(CC) $(CFLAGS) -c -o $(BUILDIR)/intset.o intset.c
test.o: stack-lock.h stack-lock.h intset.h
$(CC) $(CFLAGS) -c -o $(BUILDIR)/test.o $(TEST_FILE)
main: measurements.o ssalloc.o stack-lock.o $(ALGO_O) intset.o test.o clh.o
$(CC) $(CFLAGS) $(BUILDIR)/measurements.o $(BUILDIR)/ssalloc.o $(BUILDIR)/htlock.o $(BUILDIR)/clh.o $(BUILDIR)/stack-lock.o $(BUILDIR)/$(ALGO_O) $(BUILDIR)/intset.o $(BUILDIR)/test.o -o $(BINS) $(LDFLAGS)
clean:
-rm -f $(BINS) *.o