Skip to content

Commit

Permalink
report about all WITH_* flags in --features
Browse files Browse the repository at this point in the history
  • Loading branch information
mdevaev committed Feb 8, 2025
1 parent b2d1a56 commit e19a3ca
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,14 @@ _OBJS = $(_USTR_SRCS:%.c=$(_BUILD)/%.o) $(_DUMP_SRCS:%.c=$(_BUILD)/%.o)


# =====
ifneq ($(call optbool,$(WITH_PYTHON)),)
override _CFLAGS += -DWITH_PYTHON
endif

ifneq ($(call optbool,$(WITH_JANUS)),)
override _CFLAGS += -DWITH_JANUS
endif

ifneq ($(call optbool,$(WITH_GPIO)),)
override _CFLAGS += -DWITH_GPIO $(shell $(PKG_CONFIG) --atleast-version=2 libgpiod 2> /dev/null && echo -DHAVE_GPIOD2)
override _USTR_LDFLAGS += -lgpiod
Expand Down
12 changes: 12 additions & 0 deletions src/ustreamer/options.c
Original file line number Diff line number Diff line change
Expand Up @@ -581,6 +581,18 @@ static int _check_instance_id(const char *str) {
}

static void _features(void) {
# ifdef WITH_PYTHON
puts("+ WITH_PYTHON");
# else
puts("- WITH_PYTHON");
# endif

# ifdef WITH_JANUS
puts("+ WITH_JANUS");
# else
puts("- WITH_JANUS");
# endif

# ifdef WITH_V4P
puts("+ WITH_V4P");
# else
Expand Down

0 comments on commit e19a3ca

Please sign in to comment.