2017-01-03 22:06:53 +00:00
|
|
|
TOOLS_DIR=../../scsi
|
|
|
|
DEFINES+=
|
|
|
|
PREFIX?=
|
2017-01-03 21:19:24 +00:00
|
|
|
CC=$(PREFIX)gcc
|
|
|
|
LD=$(PREFIX)gcc
|
2017-01-03 22:06:53 +00:00
|
|
|
CFLAGS=-g -std=c99 -Wall $(DEFINES) -I$(TOOLS_DIR)
|
|
|
|
LDFLAGS=-L$(TOOLS_DIR) -lrbscsi
|
2012-12-11 19:15:51 +00:00
|
|
|
BINS=scsitool
|
|
|
|
|
|
|
|
all: $(BINS)
|
|
|
|
|
|
|
|
%.o: %.c
|
|
|
|
$(CC) $(CFLAGS) -c -o $@ $<
|
|
|
|
|
2017-01-03 23:41:35 +00:00
|
|
|
scsitool: scsitool.o misc.o stmp_scsi.o
|
|
|
|
$(MAKE) -C $(TOOLS_DIR)
|
2012-12-11 19:15:51 +00:00
|
|
|
$(LD) -o $@ $^ $(LDFLAGS)
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -fr *.o
|
|
|
|
|
|
|
|
veryclean:
|
|
|
|
rm -rf $(BINS)
|