s/\bthe the\b/the/g *.pod
[p5sagit/p5-mst-13.2.git] / miniperlmain.c
CommitLineData
a0d0e21e 1/*
2 * "The Road goes ever on and on, down from the door where it began."
3 */
4
60e4866f 5#ifdef OEMVS
6#pragma runopts(HEAP(1M,32K,ANYWHERE,KEEP,8K,4K))
7#endif
8
4633a7c4 9
ecfc5424 10#include "EXTERN.h"
2304df62 11#include "perl.h"
12
a0d0e21e 13static void xs_init _((void));
14static PerlInterpreter *my_perl;
15
c07a80fd 16int
dc6439a4 17main(int argc, char **argv, char **env)
2304df62 18{
19 int exitstatus;
2304df62 20
22239a37 21#ifdef PERL_GLOBAL_STRUCT
22#define PERLVAR(var,type) /**/
533c011a 23#define PERLVARI(var,type,init) PL_Vars.var = init;
24#define PERLVARIC(var,type,init) PL_Vars.var = init;
22239a37 25#include "perlvars.h"
26#undef PERLVAR
27#undef PERLVARI
0f3f18a6 28#undef PERLVARIC
22239a37 29#endif
30
c07a80fd 31 PERL_SYS_INIT(&argc,&argv);
4633a7c4 32
b5dd7652 33 perl_init_i18nl10n(1);
4633a7c4 34
3280af22 35 if (!PL_do_undump) {
a0d0e21e 36 my_perl = perl_alloc();
37 if (!my_perl)
38 exit(1);
39 perl_construct( my_perl );
3280af22 40 PL_perl_destruct_level = 0;
a0d0e21e 41 }
2304df62 42
28e44ed9 43 exitstatus = perl_parse( my_perl, xs_init, argc, argv, (char **) NULL );
b5dd7652 44 if (!exitstatus) {
45 exitstatus = perl_run( my_perl );
46 }
2304df62 47
748a9306 48 perl_destruct( my_perl );
2304df62 49 perl_free( my_perl );
50
a91be337 51 PERL_SYS_TERM();
52
2304df62 53 exit( exitstatus );
4e35701f 54 return exitstatus;
2304df62 55}
56
57/* Register any extra external extensions */
58
4633a7c4 59/* Do not delete this line--writemain depends on it */
60
a0d0e21e 61static void
8ac85365 62xs_init(void)
2304df62 63{
a91be337 64 dXSUB_SYS;
2304df62 65}