mirror of
https://github.com/legop3/MultiRoombaRover.git
synced 2026-09-16 01:21:20 -04:00
kinect stuff v1
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
CXX ?= g++
|
||||
PKG_CONFIG ?= pkg-config
|
||||
|
||||
# This probe is intentionally tiny and native. It links straight against
|
||||
# libfreenect so it can be compared with freenect-regview without any Node,
|
||||
# Python, Socket.IO, or browser code in the way.
|
||||
CXXFLAGS ?= -O2 -std=c++17 -Wall -Wextra -pedantic
|
||||
CPPFLAGS += $(shell $(PKG_CONFIG) --cflags libfreenect 2>/dev/null)
|
||||
LDLIBS += $(shell $(PKG_CONFIG) --libs libfreenect 2>/dev/null) -pthread
|
||||
|
||||
# Fedora's libfreenect package may not ship a pkg-config file in every install
|
||||
# shape, so keep the common include/library fallback explicit and boring.
|
||||
ifeq ($(strip $(CPPFLAGS)),)
|
||||
CPPFLAGS += -I/usr/include/libfreenect -I/usr/include/libusb-1.0
|
||||
endif
|
||||
ifeq ($(filter -lfreenect,$(LDLIBS)),)
|
||||
LDLIBS += -lfreenect
|
||||
endif
|
||||
|
||||
TARGET := kinect_probe
|
||||
SRC := kinect_probe.cpp
|
||||
|
||||
.PHONY: all clean run
|
||||
|
||||
all: $(TARGET)
|
||||
|
||||
$(TARGET): $(SRC)
|
||||
$(CXX) $(CXXFLAGS) $(CPPFLAGS) -o $@ $< $(LDLIBS)
|
||||
|
||||
run: $(TARGET)
|
||||
./$(TARGET)
|
||||
|
||||
clean:
|
||||
rm -f $(TARGET)
|
||||
Reference in New Issue
Block a user