aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile13
1 files changed, 7 insertions, 6 deletions
diff --git a/Makefile b/Makefile
index eb2177a..0a16b32 100644
--- a/Makefile
+++ b/Makefile
@@ -57,18 +57,19 @@ else # Linux / FreeBSD
GRAPHICS_LOFI:=redist/CNFGFunctions.c redist/CNFGXDriver.c
endif
+ifdef LINUX_USE_HIDAPI
+ CFLAGS:=$(CFLAGS) -DHIDAPI
+ #TODO why doesn't the redist version work
+ #REDISTS:=$(REDISTS) redist/hid-linux.c
+ LDFLAGS:=$(LDFLAGS) -ludev -lhidapi-libusb
+endif
+
ifdef MINIMAL
LIBSURVIVE_C:=$(REDISTS) $(LIBSURVIVE_CORE) $(MINIMAL_NEEDED)
else
LIBSURVIVE_C:=$(POSERS) $(REDISTS) $(LIBSURVIVE_CORE) $(SBA) $(MINIMAL_NEEDED) $(AUX_NEEDED)
endif
-ifdef LINUX_USE_HIDAPI
- CFLAGS:=$(CFLAGS) -DHIDAPI
- REDISTS:=$(REDISTS) redist/hid-linux.o
- LDFLAGS:=$(LDFLAGS) -ludev
-endif
-
#Actually make object and dependency lists.
LIBSURVIVE_O:=$(LIBSURVIVE_C:%.c=$(OBJDIR)/%.o)