Issue #255: libgpiod 2.0 API supported

Thanks for @jpalus for #249 with compatibility code
This commit is contained in:
Maxim Devaev
2024-01-07 04:33:46 +02:00
parent 2997906d98
commit d9b5f2b03d
3 changed files with 91 additions and 21 deletions

View File

@@ -42,7 +42,7 @@ endef
ifneq ($(call optbool,$(WITH_GPIO)),)
_USTR_LIBS += -lgpiod
override _CFLAGS += -DWITH_GPIO
override _CFLAGS += -DWITH_GPIO $(shell pkg-config --atleast-version=2 libgpiod 2> /dev/null && echo -DHAVE_GPIOD2)
_USTR_SRCS += $(shell ls ustreamer/gpio/*.c)
endif