Re: Win32 crashes perl
by bart (Canon) on Nov 29, 2006 at 18:30 UTC
|
Do you, by any chance, have any other version of Perl installed? One that has a DLL that is more visible than the one that comes with this perl?
Or is there any other DLL file "Win32.dll" in your path, that gets loaded instead, by accident? | [reply] |
Re: Win32 crashes perl
by shmem (Chancellor) on Nov 29, 2006 at 17:09 UTC
|
Does "it crashes" mean it just disappears without saying "thanks for the fish" ? Or does it utter a
last wish, or any other useful message you forgot to post? How (Not) To Ask A Question
--shmem
_($_=" "x(1<<5)."?\n".q·/)Oo. G°\ /
/\_¯/(q /
---------------------------- \__(m.====·.(_("always off the crowd"))."·
");sub _{s./.($e="'Itrs `mnsgdq Gdbj O`qkdq")=~y/"-y/#-z/;$e.e && print}
| [reply] |
Re: Win32 crashes perl
by CountZero (Bishop) on Nov 29, 2006 at 18:25 UTC
|
Well, what can I say ... I have the same version of AS Perl on my computer and there it works (at least it does not "crash").On an entirely unrelated issue: why do you start your program with #!/usr/bin/perl? On a Windows system it is most unlikely that the perl-executable is to be found at that location.
CountZero "If you have four groups working on a compiler, you'll get a 4-pass compiler." - Conway's Law
| [reply] [d/l] |
|
|
why do you start your program with #!/usr/bin/perl?
There's no reason not to use the #! line. I use it in my Windows code as I sometimes will want to use that same code on a Linux box. One upside of Perl is it's portability (when you write with that in mind) - no reason not to accommodate that from the get-go.
| [reply] |
|
|
If you run Apache on your windows machine and you have installed Perl at C:\usr\, then Apache will find the perl executable at /usr/bin/perl. So this shebang is necessary and correct.
| [reply] |
|
|
I run Apache on my Windows machine. Perl is not installed at c:/usr/ and none of my scripts use the she-bang line and still it works. So it may be correct but it sure is not necessary.
CountZero "If you have four groups working on a compiler, you'll get a 4-pass compiler." - Conway's Law
| [reply] [d/l] |
Re: Win32 crashes perl
by xdg (Monsignor) on Nov 29, 2006 at 19:07 UTC
|
Works for me on Vanilla Perl on Win32. I'd second the call to check your PATH for conflicting .dll's or even a conflicting perl. (E.g. the Win32 SVK installer installs an entire perl.exe -- bad news if that's earlier in your PATH).
As an aside, for crashing perl on Win32, there's always this little bit of fun, too:
> perl -te fork
-xdg
Code written by xdg and posted on PerlMonks is public domain. It is provided as is with no warranties, express or implied, of any kind. Posted code may not have been tested. Use of posted code is at your own risk.
| [reply] [d/l] |
|
|
C:\>cmd
Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.
C:\>perl -te fork
C:\>perl -te "fork; print qq[I am $$\n]"
I am 3388
I am -5532
C:\>perl -v
This is perl, v5.8.3 built for MSWin32-x86-multi-thread
(with 8 registered patches, see perl -V for more detail)
...
I am wondering whether this is a joke/pun that I am not getting. Just curious...
Update: The same code runs on my Win2K machine at home:
C:\>cmd
Microsoft Windows 2000 [Version 5.00.2195]
(C) Copyright 1985-2000 Microsoft Corp.
C:\>perl -v
This is perl, v5.8.4 built for MSWin32-x86-multi-thread
(with 3 registered patches, see perl -V for more detail)
...
| [reply] [d/l] [select] |
|
|
| [reply] |
|
|
C:\>perl -te fork
Segfaults on all my Win32 perls (that I tried it on) on Windows 2000.
Cheers, <Rob>
| [reply] |
|
|
Re: Win32 crashes perl
by talexb (Chancellor) on Nov 29, 2006 at 18:21 UTC
|
I'm not that familiar with ActivePerl any more, but the first thing I'd try would be to run the tests for the Win32 module and see if they all pass. Based on that result, you can figure out your next strategy.
Alex / talexb / Toronto
"Groklaw is the open-source mentality applied to legal research" ~ Linus Torvalds
| [reply] |
Re: Win32 crashes perl
by Anonymous Monk on Nov 30, 2006 at 11:39 UTC
|
What shows in Event Viewer? | [reply] |