// $Header: /cvsroot/swig/SWIG/Lib/perl5/perlmain.i,v 1.2 2003/09/01 18:13:33 beazley Exp $
// Code to statically rebuild perl5.
This module provides support for building a new version of the
Perl executable. This will be necessary on systems that do
not support shared libraries and may be necessary with C++
This module may only build a stripped down version of the
Perl executable. Thus, it may be necessary (or desirable)
to hand-edit this file for your particular application. To
do this, simply copy this file from swig_lib/perl5/perlmain.i
to your working directory and make the appropriate modifications.
This library file works with Perl 5.003. It may work with earlier
versions, but it hasn't been tested. As far as I know, this
static void xs_init _((pTHX));
static PerlInterpreter *my_perl;
int perl_eval(char *string) {
return perl_call_argv("eval",0,argv);
main(int argc, char **argv, char **env)
perl_construct( my_perl );
exitstatus = perl_parse( my_perl, xs_init, argc, argv, (char **) NULL );
/* Initialize all of the module variables */
exitstatus = perl_run( my_perl );
perl_destruct( my_perl );
/* Register any extra external extensions */
/* Do not delete this line--writemain depends on it */
/* EXTERN_C void boot_DynaLoader _((CV* cv)); */
/* newXS("DynaLoader::boot_DynaLoader", boot_DynaLoader, file); */
newXS(SWIG_name, SWIG_init, file);