diff options
author | Robin Burchell w00t@inspircd.org <Robin Burchell w00t@inspircd.org@5417fbe8-f217-4b02-8779-1006273d7864> | 2008-09-30 18:45:13 +0000 |
---|---|---|
committer | Robin Burchell w00t@inspircd.org <Robin Burchell w00t@inspircd.org@5417fbe8-f217-4b02-8779-1006273d7864> | 2008-09-30 18:45:13 +0000 |
commit | 63304b3a01a237cff2943373e4467dd678eadb53 (patch) | |
tree | 92fd01606d977400383f681be343bb6bf4c31e1f /include | |
parent | a03ece92ed1f092995d8bb1cc2c56b188da00ec8 (diff) |
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
Diffstat (limited to 'include')
-rw-r--r-- | include/services.h | 11 |
1 files changed, 11 insertions, 0 deletions
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" |