- char *embedding[] = { "", "-e", "0" };
-
- Debug( LDAP_DEBUG_TRACE, "perl backend open\n", 0, 0, 0 );
-
- if( PERL_INTERPRETER != NULL ) {
- Debug( LDAP_DEBUG_ANY, "perl backend open: already opened\n",
- 0, 0, 0 );
- return 1;
- }
-
- PERL_INTERPRETER = perl_alloc();
- perl_construct(PERL_INTERPRETER);
- perl_parse(PERL_INTERPRETER, perl_back_xs_init, 3, embedding, (char **)NULL);
- perl_run(PERL_INTERPRETER);
+ char *embedding[] = { "", "-e", "0", NULL }, **argv = embedding;
+ int argc = 3;
+#ifdef PERL_SYS_INIT3
+ char **env = environ;
+#else
+ char **env = NULL;
+#endif