From 2c201c2140f9a75f3698e988880f00f8d0492315 Mon Sep 17 00:00:00 2001 From: Zbigniew Jędrzejewski-Szmek Date: Thu, 27 Apr 2017 21:13:08 -0400 Subject: meson: use booleans for conf.set and drop unecessary conditionals Using conf.set() with a boolean argument does the right thing: either #ifdef or #undef. This means that conf.set can be used unconditionally. Previously I used '1' as the placeholder value, and that needs to be changed to 'true' for consistency (under meson 1 cannot be used in boolean context). All checks need to be adjusted. --- src/journal/meson.build | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/journal') diff --git a/src/journal/meson.build b/src/journal/meson.build index 37ec559e41..582f83afb9 100644 --- a/src/journal/meson.build +++ b/src/journal/meson.build @@ -20,7 +20,7 @@ journal_internal_sources = files(''' sd-journal.c '''.split()) -if conf.get('HAVE_GCRYPT', 0) == 1 +if conf.get('HAVE_GCRYPT', false) journal_internal_sources += files(''' journal-authenticate.c journal-authenticate.h @@ -36,7 +36,7 @@ endif audit_type_includes = [config_h, missing_h, 'linux/audit.h'] -if conf.get('HAVE_AUDIT', 0) == 1 +if conf.get('HAVE_AUDIT', false) audit_type_includes += 'libaudit.h' endif @@ -95,7 +95,7 @@ systemd_cat_sources = files('cat.c') journalctl_sources = files('journalctl.c') -if conf.get('HAVE_QRENCODE', 0) == 1 +if conf.get('HAVE_QRENCODE', false) journalctl_sources += files('journal-qrcode.c', 'journal-qrcode.h') endif -- cgit v1.2.3-54-g00ecf