From 6fcdc552ffdca93334ffe2d044745c83de0722fa Mon Sep 17 00:00:00 2001 From: David Oberhollenzer Date: Sun, 28 Feb 2021 13:50:57 +0100 Subject: Cleanup handling of optional dependencies Don't use super pedantic parsing of the argument and work with the generated variable instead of assigning it to our own and set it to "check" if not value is assigned. Then search for a dependency if the with variable is anything other than "no" and fail if it was set to "yes". In addition, the WITHOUT_xxx defines are replaced with WITH_xxx defines. Signed-off-by: David Oberhollenzer --- Makefile.am | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'Makefile.am') diff --git a/Makefile.am b/Makefile.am index dd14d96..299a5fb 100644 --- a/Makefile.am +++ b/Makefile.am @@ -3,16 +3,16 @@ ACLOCAL_AMFLAGS = -I m4 AM_CPPFLAGS = $(WARN_CFLAGS) -D_GNU_SOURCE -std=gnu99 -I$(top_srcdir)/include \ -include $(top_builddir)/include/config.h -if WITHOUT_XATTR -AM_CPPFLAGS += -DWITHOUT_XATTR +if WITH_XATTR +AM_CPPFLAGS += -DWITH_XATTR endif -if WITHOUT_LZO -AM_CPPFLAGS += -DWITHOUT_LZO +if WITH_LZO +AM_CPPFLAGS += -DWITH_LZO endif -if WITHOUT_ZSTD -AM_CPPFLAGS += -DWITHOUT_ZSTD +if WITH_ZSTD +AM_CPPFLAGS += -DWITH_ZSTD endif if WITH_SELINUX -- cgit v1.2.3