summarylogtreecommitdiffstats
path: root/Makefile
blob: b63e564c52e636e8a5b96f4c45e66a7c5aeb4886 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
SOURCES := ramspeed.c

ifeq ($(CARCH),i686)
SOURCES += $(wildcard i386/*.s) $(wildcard i386/cpuinfo/*.s)
CPPFLAGS += -DI386_ASM
else ifeq ($(CARCH),x86_64)
SOURCES += $(wildcard amd64/*.s)
CPPFLAGS += -DAMD64_ASM
else
SOURCES += fltmem.c intmem.c fltmark.c intmark.c
endif

CPPFLAGS += -DLinux
CFLAGS += -O3

ramspeed: $(SOURCES)
	echo $(CARCH)
	$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $^ -o $@

clean:
	rm -f *.o ramspeed