From de666eec6a939eb7034d6f6c9bf7a22ede463303 Mon Sep 17 00:00:00 2001 From: Aaron Stone Date: Tue, 17 Dec 2013 13:08:12 -0800 Subject: commandline: Makefile use shell assignments to execute once Backticks in the variables would execute at each invocation. With Macports, libusb 0.x config is called libusb-legacy-config. --- commandline/Makefile | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'commandline') diff --git a/commandline/Makefile b/commandline/Makefile index af9a9ee..b5bea87 100644 --- a/commandline/Makefile +++ b/commandline/Makefile @@ -1,17 +1,17 @@ # Makefile initially writen for Little-Wire by Omer Kilic -# Later on modified by ihsan Kehribar for Micronucleus bootloader application. +# Later on modified by ihsan Kehribar for Micronucleus bootloader application. CC=gcc # FIXME: Need to add OSX stuff ifeq ($(shell uname), Linux) - USBFLAGS = `libusb-config --cflags` - USBLIBS = `libusb-config --libs` + USBFLAGS=$(shell libusb-config --cflags) + USBLIBS=$(shell libusb-config --libs) EXE_SUFFIX = OSFLAG = -D LINUX else ifeq ($(shell uname), Darwin) - USBFLAGS = `libusb-config --cflags` - USBLIBS = `libusb-config --libs` + USBFLAGS=$(shell libusb-config --cflags || libusb-legacy-config --cflags) + USBLIBS=$(shell libusb-config --libs || libusb-legacy-config --libs) EXE_SUFFIX = OSFLAG = -D MAC_OS else @@ -36,7 +36,7 @@ library: $(LWLIBS) $(LWLIBS): @echo Building library: $@... - $(CC) $(CFLAGS) -c library/$@.c + $(CC) $(CFLAGS) -c library/$@.c $(EXAMPLES): $(addsuffix .o, $(LWLIBS)) @echo Building example: $@... -- cgit v1.2.3