diff options
| author | Quentin Young <qlyoung@nvidia.com> | 2020-11-30 17:37:18 -0500 |
|---|---|---|
| committer | Quentin Young <qlyoung@nvidia.com> | 2020-12-01 18:37:14 -0500 |
| commit | e4e0229aba2b90d93bf681cc4e309c93f7cff61f (patch) | |
| tree | 3885492f543d13ae42dbe47b83fe3a5b38368027 /lib/frrscript.h | |
| parent | fa22080d22e1e4e69f7bed6d041083df1b85b4b7 (diff) | |
lib: add support for scripts directory
Specify default via --with-scriptdir at compile time, override default
with --scriptdir at runtime. If unspecified, it's {sysconfdir}/scripts
(usually /etc/frr/scripts)
Signed-off-by: Quentin Young <qlyoung@nvidia.com>
Diffstat (limited to 'lib/frrscript.h')
| -rw-r--r-- | lib/frrscript.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/frrscript.h b/lib/frrscript.h index 4206420f48..f4057f531b 100644 --- a/lib/frrscript.h +++ b/lib/frrscript.h @@ -30,8 +30,6 @@ extern "C" { #endif -#define FRRSCRIPT_PATH "/etc/frr/scripts" - typedef void (*encoder_func)(lua_State *, const void *); typedef void *(*decoder_func)(lua_State *, int); @@ -92,8 +90,11 @@ void frrscript_register_type_codecs(struct frrscript_codec *codecs); /* * Initialize scripting subsystem. Call this before anything else. + * + * scriptdir + * Directory in which to look for scripts */ -void frrscript_init(void); +void frrscript_init(const char *scriptdir); /* |
