2 Copyright © 1995-2011, The AROS Development Team. All rights reserved.
5 Main for genmodule. A tool to generate files for building modules.
9 int main(int argc
, char **argv
)
12 struct config
*cfg
= initconfig(argc
, argv
);
19 if (cfg
->options
& OPTION_AUTOINIT
)
21 writeautoinit(cfg
, 0); /* normal */
22 if (cfg
->options
& OPTION_RELLINKLIB
)
23 writeautoinit(cfg
, 1); /* relbase */
25 if (cfg
->modtype
== LIBRARY
)
27 writegetlibbase(cfg
, 0); /* normal */
28 if (cfg
->options
& OPTION_RELLINKLIB
)
29 writegetlibbase(cfg
, 1); /* relbase */
31 if (cfg
->options
& OPTION_STUBS
)
33 writestubs(cfg
, 0); /* normal */
34 if (cfg
->options
& OPTION_RELLINKLIB
)
35 writestubs(cfg
, 1); /* relbase */
40 if (cfg
->options
& OPTION_INCLUDES
)
47 if (cfg
->interfacelist
)
48 writeincinterfaces(cfg
);
60 /* Ignore the functionlist and the methodlist that are available in the
64 if (cfg
->classlist
!= NULL
)
65 cfg
->classlist
->methlist
= NULL
;
83 fprintf(stderr
, "Internal error in main: Unhandled command type\n");