From b50d30851b844b74dbd9e03dd9de8d0fa5b0a9f8 Mon Sep 17 00:00:00 2001 From: NunoSempere Date: Tue, 7 Feb 2023 14:17:10 +0100 Subject: fix: fix some warts - stuff to deal with plugin code wasn't actually compiling - created a "stand_in" plugin to provide headers and function definitions - when these are not used - it is likely there are better approaches here - hidebar, newtab -> hide_bar, new_tab --- plugins/stand_in/stand_in.c | 27 +++++++++++++++++++++++++++ plugins/stand_in/stand_in.h | 23 +++++++++++++++++++++++ 2 files changed, 50 insertions(+) create mode 100644 plugins/stand_in/stand_in.c create mode 100644 plugins/stand_in/stand_in.h (limited to 'plugins/stand_in') diff --git a/plugins/stand_in/stand_in.c b/plugins/stand_in/stand_in.c new file mode 100644 index 0000000..dbcc7e8 --- /dev/null +++ b/plugins/stand_in/stand_in.c @@ -0,0 +1,27 @@ +/* Why this file is needed: + * If the plugins are disabled, + * their conditionals will never resolve + * and their functionality never comes into play + * but the compiler still wants to know their type +*/ + +int libre_redirect(const char* uri, char* uri_filtered){ + return 0; +} +void str_init(char* str, int n){ + +}; + +int str_replace_start(const char* string, const char* target, + const char* replacement, char* output){ + return 1; +}; + +void read_readability_js(char* string){ + +} + +void read_style_js(char* string){ + +} + diff --git a/plugins/stand_in/stand_in.h b/plugins/stand_in/stand_in.h new file mode 100644 index 0000000..e221734 --- /dev/null +++ b/plugins/stand_in/stand_in.h @@ -0,0 +1,23 @@ +/* Why this file is needed: + * If the plugins are disabled, + * their conditionals will never resolve + * and their functionality never comes into play + * but the compiler still wants to know their type +*/ + +#pragma once + +#define LIBRE_N 0 +#define STYLE_N 0 +#define READABILITY_N 0 + +int libre_redirect(const char* uri, char* uri_filtered); +void str_init(char* str, int n); + +int str_replace_start(const char* string, const char* target, + const char* replacement, char* output); + +void read_readability_js(char* string); + +void read_style_js(char* string); + -- cgit v1.2.3