summaryrefslogtreecommitdiff
path: root/mastoapi.c
diff options
context:
space:
mode:
authordefault <nobody@localhost>2023-04-21 23:17:58 +0200
committerdefault <nobody@localhost>2023-04-21 23:17:58 +0200
commit526d4e8abb27127625a228796dc9c196efcfa8bf (patch)
tree76a5c05240474df1fdfc5902bdb0fe6d70cdd203 /mastoapi.c
parent7c5fb6f1789fb30957e820465a907648b7c8abaf (diff)
Added a new compilation variable NO_MASTODON_API.
The Mastodon API is a big and ugly beast; if you don't want it in your snac, you can compile it out by running make CFLAGS=-DNO_MASTODON_API And your snac binary will be as slim as always.
Diffstat (limited to 'mastoapi.c')
-rw-r--r--mastoapi.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/mastoapi.c b/mastoapi.c
index 6e5fe09..3858e13 100644
--- a/mastoapi.c
+++ b/mastoapi.c
@@ -1,6 +1,8 @@
/* snac - A simple, minimalistic ActivityPub instance */
/* copyright (c) 2022 - 2023 grunfink / MIT license */
+#ifndef NO_MASTODON_API
+
#include "xs.h"
#include "xs_encdec.h"
#include "xs_openssl.h"
@@ -1453,3 +1455,5 @@ int mastoapi_post_handler(const xs_dict *req, const char *q_path,
return status;
}
+
+#endif /* #ifndef NO_MASTODON_API */