Signed-off-by: Eivind Næss <eivnaes@yahoo.com>
SUBDIRS = chat contrib pppd pppstats pppdump
SUBDIRS = chat contrib pppd pppstats pppdump
SUBDIRS += pppd/plugins
endif
SUBDIRS += pppd/plugins
endif
AC_ARG_ENABLE([plugins],
AS_HELP_STRING([--disable-plugins], [Disable support for loadable plugins]))
AS_IF([test "x$enable_plugins" != "xno"],
AC_ARG_ENABLE([plugins],
AS_HELP_STRING([--disable-plugins], [Disable support for loadable plugins]))
AS_IF([test "x$enable_plugins" != "xno"],
- AC_DEFINE([PLUGIN], 1, ["Have support for loadable plugins"]))
-AM_CONDITIONAL(WITH_PLUGINS, test "${enable_plugins}" != "no")
+ AC_DEFINE([PPP_WITH_PLUGINS], 1, ["Have support for loadable plugins"]))
+AM_CONDITIONAL(PPP_WITH_PLUGINS, test "${enable_plugins}" != "no")
#
# Disable EAP-TLS support
#
# Disable EAP-TLS support
pppd_LIBS += $(PCAP_LIBS)
endif
pppd_LIBS += $(PCAP_LIBS)
endif
pppd_CPPFLAGS += -DPPPD_PLUGIN_DIR='"@PPPD_PLUGIN_DIR@"'
pppd_LIBS += -ldl
if LINUX
pppd_CPPFLAGS += -DPPPD_PLUGIN_DIR='"@PPPD_PLUGIN_DIR@"'
pppd_LIBS += -ldl
if LINUX
#include <syslog.h>
#include <string.h>
#include <pwd.h>
#include <syslog.h>
#include <string.h>
#include <pwd.h>
#include <dlfcn.h>
#endif
#include <dlfcn.h>
#endif
static int showhelp(char **);
static void usage(void);
static int setlogfile(char **);
static int showhelp(char **);
static void usage(void);
static int setlogfile(char **);
static int loadplugin(char **);
#endif
static int loadplugin(char **);
#endif
"Bundle name for multilink", OPT_PRIO },
#endif /* PPP_WITH_MULTILINK */
"Bundle name for multilink", OPT_PRIO },
#endif /* PPP_WITH_MULTILINK */
{ "plugin", o_special, (void *)loadplugin,
"Load a plug-in module into pppd", OPT_PRIV | OPT_A2LIST },
#endif
{ "plugin", o_special, (void *)loadplugin,
"Load a plug-in module into pppd", OPT_PRIV | OPT_A2LIST },
#endif
static int
loadplugin(char **argv)
{
static int
loadplugin(char **argv)
{
+#endif /* PPP_WITH_PLUGINS */
/*
* Set an environment variable specified by the user.
/*
* Set an environment variable specified by the user.
#undef PPP_FILTER
/* "Have support for loadable plugins" */
#undef PPP_FILTER
/* "Have support for loadable plugins" */
/* "Limit sessions by maximum number of octets" */
#undef MAXOCTETS
/* "Limit sessions by maximum number of octets" */
#undef MAXOCTETS