blob: de940eed2385b36e30cee82b7081084e4794baa8 (
plain)
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
|
# This tool is a linux userland tool and should be completely stand alone
prefix = /usr/local/
sbindir = $(prefix)/sbin
CC = $(CROSS_COMPILE)gcc
CFLAGS += -m64 -Werror -Wall -g2 -ggdb
LDFLAGS += -m64
ASFLAGS = -m64
CPPFLAGS += -I. -I../../
OBJS = file_flash.o gard.o libflash.o libffs.o ecc.o
EXE = gard
all: $(EXE)
%.o: %.c
$(COMPILE.c) $< -o $@
%.o: ../../libflash/%.c
$(COMPILE.c) $< -o $@
$(EXE): $(OBJS)
$(LINK.o) -o $@ $^
install: all
install -D gard $(DESTDIR)$(sbindir)/opal-gard
clean:
rm -f $(OBJS) $(EXE) *.d
distclean: clean
|