]> rtime.felk.cvut.cz Git - coffee/mt-apps.git/commitdiff
Fix Makefile to work under buildroot
authorMichal Sojka <michal.sojka@cvut.cz>
Tue, 7 Aug 2018 08:39:18 +0000 (10:39 +0200)
committerMichal Sojka <michal.sojka@cvut.cz>
Tue, 7 Aug 2018 09:10:30 +0000 (11:10 +0200)
Makefile

index 4479467a540e2d8a2c58c2588f6c9df1c512faeb..9aa981771c75f5e3b5ac5100137c5a1f60cda04b 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,7 @@
 OUTPUT_DIR    = build
 
 CFLAGS       = -Ilibwebsockets/include -Llibwebsockets/lib
-can_compile   = $(shell set -x; if echo '$(1)' | $(CC) $(CFLAGS) -c -xc - -o /dev/null >/dev/null 2>&1; then echo yes; fi)
+can_compile   = $(shell if echo '$(1)' | $(CC) $(CFLAGS) -c -xc - -o /dev/null >/dev/null 2>&1; then echo yes; fi)
 HAVE_RFID    := $(call can_compile,\#include <uFCoder.h>)
 
 ifeq ($(HAVE_RFID),yes)
@@ -12,6 +12,7 @@ endif
 
 mtrfid_SRCS   = signal_exit.c mt_rfid.c
 mtrfid_LIBS   = -lev -luFCoder-armhf
+mtrfid_DEFS   = -DHAVE_RFID=1
 
 mtserver_SRCS = signal_exit.c mt_server.c
 mtserver_LIBS = -lev -lwebsockets