develooper Front page | perl.perl5.porters | Postings from December 2018

[perl #133661] Minimal perlembed test case fails to run a minimalscript on cygwin64/win64/appveyor .

Thread Previous
From:
Tony Cook via RT
Date:
December 5, 2018 02:51
Subject:
[perl #133661] Minimal perlembed test case fails to run a minimalscript on cygwin64/win64/appveyor .
Message ID:
rt-4.0.24-7717-1543978256-315.133661-15-0@perl.org
On Sat, 17 Nov 2018 09:34:45 -0800, shlomif@shlomifish.org wrote:
> 
> The test case here:
> 
> * https://github.com/thewml/website-meta-language/tree/reduce-
> appveyor-error
> (note the branch)
> 
> * https://ci.appveyor.com/project/shlomif/website-meta-
> language/builds/20374998
> 
> * https://travis-ci.org/thewml/website-meta-language/builds/456382402
> 
> fails to work on cygwin64 / appveyor while running fine on travis
> ci/ubuntu
> 14.04 x86-64.
> 
> The file is:
> 
> ----------------------------------------------------------------------
> #include <stdio.h>
> #include <stdarg.h>
> #include <stdlib.h>
> #include <string.h>
> #include <ctype.h>
> 
> /*  first include the standard Perl
>  *      includes designed for embedding   */
> #if 0
> #define PERL_NO_GET_CONTEXT     /* for efficiency reasons, see
> perlguts(3) */
> #endif
> #include <EXTERN.h>
> #include <perl.h>
> 
> int Perl5_Run(int myargc, char **myargv, char **env)
> {
>     int rc;
>     PerlInterpreter *my_perl = NULL;
> 
> my_perl = perl_alloc();
> perl_construct(my_perl);

You aren't calling PERL_SYS_INIT3(...)

If I add:

      PERL_SYS_INIT3(&myargc, &myargv, &env);

before the call to perl_alloc() the expected output is generated (I didn't test on appveyor)

Tony

---
via perlbug:  queue: perl5 status: new
https://rt.perl.org/Ticket/Display.html?id=133661

Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About