3 CFLAGS += -Wall -g -DNMRPFLASH_VERSION=\"$(shell git describe --always)\"
6 .PHONY: clean install release release/osx release/linux
8 nmrp-flash: nmrp.o tftp.o ethsock.o main.o
9 $(CC) $(CFLAGS) -o nmrp-flash nmrp.o tftp.o ethsock.o main.o $(LIBS)
11 nmrp.o: nmrp.c nmrpd.h
12 $(CC) $(CFLAGS) -c -o nmrp.o nmrp.c
14 tftp.o: tftp.c nmrpd.h
15 $(CC) $(CFLAGS) -c -o tftp.o tftp.c
17 ethsock.o: ethsock.c nmrpd.h
18 $(CC) $(CFLAGS) -c -o ethsock.o ethsock.c
20 main.o: main.c nmrpd.h
21 $(CC) $(CFLAGS) -c -o main.o main.c
24 rm -f nmrp.o tftp.o main.o ethsock.o nmrp-flash nmrp-flash.exe
27 install -m 755 nmrp-flash $(PREFIX)/bin
30 make release CFLAGS="-arch i686 -arch x86_64"
31 cp nmrp-flash binaries/osx/
33 release/linux: release
34 cp nmrp-flash binaries/linux/
36 release: clean nmrp-flash