From 63304b3a01a237cff2943373e4467dd678eadb53 Mon Sep 17 00:00:00 2001 From: "Robin Burchell w00t@inspircd.org" Date: Tue, 30 Sep 2008 18:45:13 +0000 Subject: Add MODULE_INIT workaround for modules, so they are loadable. Inspired by InspIRCd solution to this. git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@1272 5417fbe8-f217-4b02-8779-1006273d7864 --- include/services.h | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'include') diff --git a/include/services.h b/include/services.h index 58d24bc8f..a62b8d849 100644 --- a/include/services.h +++ b/include/services.h @@ -201,6 +201,17 @@ extern int strncasecmp(const char *, const char *, size_t); #define MARK_DEPRECATED #endif + +#ifndef _WIN32 + #define MODULE_INIT(x) \ + extern "C" int anope_modinit(int argc, char **argv) \ + { \ + return AnopeInit(argc, argv); \ + } +#else + #error Not yet supported on Windows, XXX +#endif + /* Miscellaneous definitions. */ #include "defs.h" #include "slist.h" -- cgit