Modifications to the module system

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@961 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Dave Beazley 2000-12-19 04:38:06 +00:00
commit d66f561cfc
20 changed files with 561 additions and 571 deletions

View file

@ -11,12 +11,16 @@
#include "swig.h"
extern void testmodule();
extern void pythonmodule();
extern void inputmodule();
extern void preprocessormodule();
extern void cparsemodule();
extern void swig11module();
static void (*modules[])(void) = {
testmodule,
pythonmodule,
inputmodule,
preprocessormodule,
cparsemodule,
swig11module,
0
};
@ -33,7 +37,16 @@ void init_modules() {
}
}
/* This array contains the names of modules that should be loaded by default */
static char *default_modules[] = {
"input",
"preprocessor",
"cparse",
0
};
int main(int argc, char **argv) {
init_modules();
return Swig_main(argc, argv);
return Swig_main(argc, argv, default_modules);
}