aboutsummaryrefslogtreecommitdiff
path: root/main.c
diff options
context:
space:
mode:
authorMarc André Tanner <mat@brain-dump.org>2017-02-14 14:21:32 +0100
committerMarc André Tanner <mat@brain-dump.org>2017-02-14 14:21:32 +0100
commit63adc2c1b3c2a75030b05f0e737af1da4ca04134 (patch)
tree64f32f809b74d53e9fa0c99750cbb1476d5d777e /main.c
parentc8e153c124fb606aed507ba99eda424048e24112 (diff)
downloadvis-63adc2c1b3c2a75030b05f0e737af1da4ca04134.tar.gz
vis-63adc2c1b3c2a75030b05f0e737af1da4ca04134.tar.xz
vis: add compile time features to version output
Diffstat (limited to 'main.c')
-rw-r--r--main.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/main.c b/main.c
index 565d438..a909b8a 100644
--- a/main.c
+++ b/main.c
@@ -2282,7 +2282,18 @@ int main(int argc, char *argv[]) {
} else if (strcmp(argv[i], "--") == 0) {
break;
} else if (strcmp(argv[i], "-v") == 0) {
- puts("vis " VERSION);
+ fputs("vis " VERSION, stdout);
+ if (CONFIG_LUA)
+ fputs(" +lua", stdout);
+ if (CONFIG_LPEG)
+ fputs(" +lpeg", stdout);
+ if (CONFIG_TRE)
+ fputs(" +tre", stdout);
+ if (CONFIG_ACL)
+ fputs(" +acl", stdout);
+ if (CONFIG_SELINUX)
+ fputs(" +selinux", stdout);
+ fputs("\n", stdout);
return 0;
} else {
fprintf(stderr, "Unknown command option: %s\n", argv[i]);