-----Original Message-----
From: activeperl-boun...@listserv.activestate.com
[mailto:activeperl-boun...@listserv.activestate.com] On Behalf Of Xiao
Yafeng
Sent: Tuesday, 7 April 2009 9:01 AM
To: Lyle
Cc: ActivePerl@listserv.ActiveState.com
Subject: Re: Perl6 though IIS7 CGI

I know my English is not well, but I guess s/awful/awesome/ ?

On 4/7/09, Lyle <webmas...@cosmicperl.com> wrote:
> Hi All,
>   I know this is a bit off topic, but I couldn't think of a list that
> would have as much IIS/CGI knowledge as you guys.
>
> I'm trying to get the latest build of Rakudo Perl 6 to run as a CGI
> through IIS7 on my Vista32 machine.
>
> At first I thought it might be something in my code, but after trying
> several things I tried it under Apache on the same machine and it worked
> fine. It's a very basic hello script:-
>
> #!c:/temp/rakudo/perl6.exe
>
> $*ERR = open("C:/inetpub/wwwroot/cgi-bin/perl6/err.txt", :w);
> my $crlf = "\x[0D]\x[0A]";
> $*OUT.say( "Content-Type: text/html$crlf$crlf" );
> $*OUT.say( 'hello' );
> #$*ERR.say( 'hello' );
>
> I've had problems in the past with IIS treating STDERR the same as
> STDOUT, which is why I've redirected it to a file to see if any errors
> were coming out (which there aren't).
>
> I thought things might not be going to STDOUT for some reason which is
> why the content-type, etc, is sent explicitly to $*OUT. But this made no
> difference.
>
> The Perl6.exe file is configured in IIS in exactly the same way as
Perl.exe.
>
> If I run this through the browser I get a 502 error. If I run it on the
> command prompt it returns the headers as expected. If I uncomment the
> #$*ERR.say( 'hello' ); on the end and run through the browser then
> err.txt is being filled with 'hello' so I know the script it definitely
> being executed.
>
> I can't figure out why IIS isn't picking up the headers? It doesn't seem
> to be picking up any of the program output as it says headers returned
> were "".
>
> I've started a thread on the IIS.net forum about this as well:-
>
> http://forums.iis.net/p/1156635/1899524.aspx
>
> Jan, I know you did an awful lot of the work to get Perl 5 working well
> under IIS. Is there anything that springs to mind that Perl6 needs to be
> doing for this to work?
>
>
> Lyle
> _______________________________________________
> ActivePerl mailing list
> ActivePerl@listserv.ActiveState.com
> To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Lyle,

I havent played too much with perl6 or IIS7, but I would hazard a guess that
the open on err.txt is failing. Have you tried a bare bones version without
opening any files? i.e. just printing out the Content-Type and hello with
say without any filehandles prepended. 

Xiao,

Awful in this context means that there was a lot of work done. Lyle is
actually complementing Jan on his hard work believe it or not!

Just in

_______________________________________________
ActivePerl mailing list
ActivePerl@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to