From 68dc074516a6859e3424b48d1647bcb08b1a1a7d Mon Sep 17 00:00:00 2001 From: Perl 5 Porters Date: Sun, 9 Mar 1997 11:57:19 +1200 Subject: [inseparable changes from match from perl-5.003_93 to perl-5.003_94] BUILD PROCESS Subject: Don't use db 2.x, we're not yet ready for it From: Paul Marquess Files: Configure Subject: Warn if #! command is longer than 32 chars From: Chip Salzenberg Files: Configure Subject: patches re perl -wc install{perl,man} Date: Tue, 11 Mar 97 13:13:16 GMT From: Robin Barker Files: installman installperl I got the new installhtml from CPAN (TOMC/scripts/pod2html-v2.0beta.shar.gz) I had problems getting the system call to splitpod at line 376 to work. 1. splitroot was not being found 2. splitroot was not finding its library 3. I changed htmlroot to podroot at line 175 to match the documentation. p5p-msgid: 3180.9703270906@tempest.cise.npl.co.uk private-msgid: 21544.9703111313@tempest.cise.npl.co.uk Subject: 3_93 doesn't install pods Date: Sun, 16 Mar 1997 02:21:35 -0500 From: Spider Boardman Files: installperl Msg-ID: 199703160721.CAA08339@Orb.Nashua.NH.US (applied based on p5p patch as commit 43506a616735d616e03d277d64fbae1e864024bf) Subject: When installing, use File::Copy instead of `cp` From: Chip Salzenberg Files: installperl Subject: Make hint files' warnings more visible Date: Thu, 20 Mar 1997 23:18:03 +0100 (MET) From: Hallvard B Furuseth Files: hints/3b1.sh hints/apollo.sh hints/cxux.sh hints/dcosx.sh hints/dgux.sh hints/esix4.sh hints/freebsd.sh hints/hpux.sh hints/irix_4.sh hints/mips.sh hints/next_3_0.sh hints/os2.sh hints/qnx.sh hints/sco_2_3_3.sh hints/sco_2_3_4.sh hints/solaris_2.sh hints/ultrix_4.sh hints/utekv.sh private-msgid: 199703202218.XAA09041@bombur2.uio.no CORE LANGUAGE CHANGES Subject: Defer creation of array and hash elements as parameters From: Chip Salzenberg Files: dump.c global.sym mg.c op.c op.h perl.h pp.c pp_hot.c proto.h sv.c Subject: New special literal: __PACKAGE__ From: Chip Salzenberg Files: keywords.pl pod/perldata.pod toke.c Subject: Abort compilation at C or C after errors From: Chip Salzenberg Files: op.c pod/perldiag.pod t/pragma/subs.t Subject: allow C Date: Mon, 10 Mar 1997 15:55:44 -0800 From: David Dyck Files: pp.c Msg-ID: 97Mar10.155517pst.35716-2@gateway.fluke.com (applied based on p5p patch as commit 77f720bf92f3d0100352416caeedd57936807ff2) Subject: Regularize C, esp. when y is negative From: Chip Salzenberg Files: pp.c Subject: Flush before C From: Chip Salzenberg Files: pod/perldelta.pod pod/perlfunc.pod pp_sys.c Subject: Close loopholes in prototype mismatch warning From: Chip Salzenberg Files: op.c sv.c toke.c Subject: Warn on C From: Chip Salzenberg Files: op.c pod/perldiag.pod Subject: Don't warn on C From: Chip Salzenberg Files: toke.c CORE PORTABILITY Subject: Don't say 'static var = 1' Date: Sun, 9 Mar 1997 15:19:57 +0200 (EET) From: Jarkko Hietaniemi Files: malloc.c private-msgid: 199703091319.PAA24714@alpha.hut.fi Subject: HP/UX hint comments Date: Fri, 21 Mar 1997 15:43:07 -0500 (EST) From: Andy Dougherty Files: hints/hpux.sh private-msgid: Pine.SOL.3.95q.970321153918.28770B-100000@fractal.lafayette. Subject: VMS update Date: Tue, 11 Mar 1997 22:00:55 -0500 (EST) From: Charles Bailey Files: lib/ExtUtils/MM_VMS.pm lib/Test/Harness.pm t/op/taint.t utils/perlbug.PL vms/descrip.mms Msg-ID: 1997Mar11.220056.1873182@hmivax.humgen.upenn.edu (applied based on p5p patch as commit 2b5725676da60b49978f38b85bb7f8ee20b4cb55) Subject: vmsish.t and related patches Date: Fri, 21 Mar 1997 01:32:47 -0500 (EST) From: Charles Bailey Files: MANIFEST perl.h vms/descrip.mms vms/ext/vmsish.t vms/vms.c private-msgid: 01IGQW3IP1KK005VFB@hmivax.humgen.upenn.edu Subject: Win32 update (four patches) From: Gurusamy Sarathy Files: MANIFEST README.win32 lib/AutoSplit.pm lib/Cwd.pm lib/ExtUtils/Command.pm lib/ExtUtils/Install.pm lib/ExtUtils/MM_OS2.pm lib/ExtUtils/MM_Unix.pm lib/ExtUtils/MM_Win32.pm lib/ExtUtils/MakeMaker.pm lib/ExtUtils/Mksymlists.pm lib/File/Basename.pm lib/File/Path.pm mg.c t/comp/cpp.t t/comp/script.t t/harness t/io/argv.t t/io/dup.t t/io/fs.t t/io/inplace.t t/lib/filehand.t t/lib/io_dup.t t/lib/io_sel.t t/lib/io_taint.t t/op/closure.t t/op/exec.t t/op/glob.t t/op/goto.t t/op/magic.t t/op/misc.t t/op/rand.t t/op/split.t t/op/stat.t t/op/sysio.t t/op/taint.t t/pragma/strict.t t/pragma/subs.t t/pragma/warning.t util.c win32/* DOCUMENTATION Subject: perlfaq.pod Date: Mon, 17 Mar 1997 16:01:40 -0700 From: Tom Christiansen Files: MANIFEST pod/Makefile pod/buildtoc pod/perl.pod pod/perlfaq*.pod pod/roffitall private-msgid: 199703172301.QAA12566@jhereg.perl.com Subject: *.pod changes based on the FAQ Date: Mon, 17 Mar 1997 09:50:14 -0700 (MST) From: Nat Torkington Files: pod/perldata.pod pod/perlfunc.pod pod/perlipc.pod pod/perlop.pod pod/perlre.pod pod/perlrun.pod pod/perlsec.pod pod/perlvar.pod Msg-ID: 199703171650.JAA02655@elara.frii.com (applied based on p5p patch as commit 3c10ad8e31f7d77e71c048b1746912f41cb540f0) Subject: Document that $. is not reset on implicit open From: Chip Salzenberg Files: pod/perldelta.pod Subject: Re: Embedding success with _93 Date: Tue, 11 Mar 1997 17:55:05 -0500 From: Doug MacEachern Files: pod/perldelta.pod Msg-ID: 199703112255.RAA22775@postman.osf.org (applied based on p5p patch as commit 63a6ff3a1dc8d86edb4d8a7ec1548205e32a7114) Subject: Patch to document illegal characters Date: Fri, 14 Mar 1997 09:08:10 -0800 (PST) From: Tom Phoenix Files: pod/perldiag.pod pod/perltrap.pod private-msgid: Pine.GSO.3.96.970314090558.15346J-100000@kelly.teleport.com Subject: Document trap with //o and closures Date: Mon, 10 Mar 1997 18:08:08 -0500 (EST) From: Charles Bailey Files: pod/perltrap.pod Msg-ID: 01IGCHWRNSEU00661G@hmivax.humgen.upenn.edu (applied based on p5p patch as commit a54cb1465fdb400848f23705a6f130bb5c34ab70) Subject: Illegal character in input Date: Mon, 10 Mar 1997 15:21:21 -0800 (PST) From: Tom Phoenix Files: pod/perldiag.pod private-msgid: Pine.GSO.3.95q.970310151512.22489a-100000@kelly.teleport.com Subject: Patch for docs Re: Lost backslash Date: Wed, 19 Mar 1997 07:28:57 -0800 (PST) From: Tom Phoenix Files: pod/perlop.pod private-msgid: Pine.GSO.3.96.970319071438.24834G-100000@kelly.teleport.com Subject: XSUB's doc fix Date: Mon, 10 Mar 1997 11:42:06 -0500 From: Roderick Schertler Files: pod/perlcall.pod pod/perlguts.pod pod/perlxstut.pod Msg-ID: 28804.858012126@eeyore.ibcinc.com (applied based on p5p patch as commit 5f43237038ea7a4151d3bf65aeeecd56ceb78a6a) Subject: Document return from do FILE Date: Tue, 18 Mar 1997 14:50:10 +0000 From: "M.J.T. Guy" Files: pod/perlfunc.pod Msg-ID: E0w70DK-0001yJ-00@ursa.cus.cam.ac.uk (applied based on p5p patch as commit ba8d5fb439878113de8abc9b52d2af237d30fb3c) Subject: Document $^M in perlvar Date: Thu, 20 Mar 97 21:08:33 GMT From: Robin Barker Files: pod/perlvar.pod private-msgid: 6153.9703202108@tempest.cise.npl.co.uk Subject: typos in pods of 5.003_93 Date: 19 Mar 1997 10:39:38 -0600 From: Jim Meyering Files: pod/perlfunc.pod pod/perlguts.pod pod/perlre.pod pod/perltoot.pod pod/perlxs.pod Msg-ID: wpgendbzvhx.fsf@asic.sc.ti.com (applied based on p5p patch as commit 76a9873e006cf8f48f57062b2a0dd40b5ed45a95) Subject: Re: Updates to pod punctuations Date: Fri, 14 Mar 1997 17:00:12 -0500 From: Larry W. Virden Files: pod/*.pod private-msgid: 9703141700.AA22911@cas.org Subject: clarify example in perlfunc Date: Thu, 20 Mar 1997 19:46:01 +0200 (EET) From: Jarkko Hietaniemi Files: pod/perlfunc.pod private-msgid: 199703201746.TAA25195@alpha.hut.fi Subject: Regularize headings in DB_File documentation From: Chip Salzenberg Files: ext/DB_File/DB_File.pm LIBRARY AND EXTENSIONS Subject: New module: autouse.pm Date: Thu, 20 Mar 1997 19:34:30 -0500 (EST) From: Ilya Zakharevich Files: MANIFEST lib/autouse.pm Msg-ID: 199703210034.TAA13469@monk.mps.ohio-state.edu (applied based on p5p patch as commit 6757905eccb6dd0440ef65e8128a277a20f7d943) Subject: Refresh DB_File to 1.12 Date: Wed, 12 Mar 97 15:51:14 GMT From: Paul Marquess Files: ext/DB_File/DB_File.pm ext/DB_File/DB_File.xs Msg-ID: 9703121551.AA07435@claudius.bfsec.bt.co.uk (applied based on p5p patch as commit b3deed9189f963e9994815307931f9084f60d1d9) Subject: In File::Path, some systems can't remove read-only files From: Chip Salzenberg Files: lib/File/Path.pm Subject: Fix bugs revealed by prototype warnings From: Chip Salzenberg Files: ext/Opcode/Opcode.pm lib/ExtUtils/MakeMaker.pm lib/Getopt/Long.pm Subject: Problems with SKIP in makemaker Date: Thu, 20 Mar 1997 23:13:31 -0500 (EST) From: Ilya Zakharevich Files: lib/ExtUtils/MM_Unix.pm Msg-ID: 199703210413.XAA21601@monk.mps.ohio-state.edu (applied based on p5p patch as commit 970322a2e8024294ada6e8d1a027cb98f1f48ee3) Subject: In Exporter, don't C at file scope From: Chip Salzenberg Files: lib/Exporter.pm Subject: fix for Exporter's $SIG{__WARN__} handler Date: Thu, 13 Mar 1997 18:40:51 -0500 From: Roderick Schertler Files: lib/Exporter.pm Msg-ID: 2282.858296451@eeyore.ibcinc.com (applied based on p5p patch as commit 2768ea1aeef34f42d096f198fbe629c8374ca429) Subject: Don't try to substr() refs in Carp From: Chip Salzenberg Files: lib/Carp.pm Subject: Re: NUL in die and other messages Date: Fri, 21 Mar 1997 09:58:17 +0000 From: "M.J.T. Guy" Files: lib/Carp.pm Msg-ID: E0w815V-0005xs-00@ursa.cus.cam.ac.uk (applied based on p5p patch as commit 52a267c574cb66c4bc35601dcf148a1d7a3bc557) OTHER CORE CHANGES Subject: Guard against buffer overflow in yyerror() and related funcs From: Chip Salzenberg Files: toke.c Subject: For bin compat, rename calllist() and he_{,delay}free From: Chip Salzenberg Files: global.sym hv.c op.c perl.c pod/perlguts.pod proto.h Subject: Fix C on tied default handle From: Chip Salzenberg Files: pp_hot.c Subject: Fix C From: Chip Salzenberg Files: op.c Subject: Improve diagnostic on C<@a++>, C<--%a>, @a =~ s/a/b/ From: Chip Salzenberg Files: pp.c pp_hot.c Subject: Don't warn on C<$x{y} .= "z"> when %x is tied From: Chip Salzenberg Files: pp_hot.c Subject: Eliminate 'unreachable code' warnings From: Chip Salzenberg Files: ext/POSIX/POSIX.xs mg.c pp_ctl.c toke.c Subject: printf format corrections for -DDEBUGGING Date: Wed, 19 Mar 1997 12:42:50 -0500 From: Roderick Schertler Files: doop.c malloc.c op.c pp_ctl.c regexec.c sv.c x2p/str.c x2p/util.c Msg-ID: 26592.858793370@eeyore.ibcinc.com (applied based on p5p patch as commit e125f273e351a19a92b69d6244af55abbbf0a26d) Subject: Warn about missing -DMULTIPLICITY if likely a problem Date: Wed, 19 Mar 1997 18:45:53 -0500 From: Doug MacEachern Files: perl.c Msg-ID: 199703192345.SAA15070@postman.osf.org (applied based on p5p patch as commit 71aeea1753924e6e19c2461e241e3f7d8a570e90) --- t/op/closure.t | 8 ++++--- t/op/exec.t | 7 ++++++ t/op/glob.t | 7 +++++- t/op/goto.t | 3 ++- t/op/magic.t | 73 +++++++++++++++++++++++++++++++++++----------------------- t/op/misc.t | 13 ++++++++--- t/op/rand.t | 10 ++++---- t/op/split.t | 3 ++- t/op/stat.t | 40 +++++++++++++++++++++----------- t/op/sysio.t | 2 +- t/op/taint.t | 10 +++++--- 11 files changed, 115 insertions(+), 61 deletions(-) (limited to 't/op') diff --git a/t/op/closure.t b/t/op/closure.t index 7af3abb291..1220998b6b 100755 --- a/t/op/closure.t +++ b/t/op/closure.t @@ -377,7 +377,7 @@ END $test++; } - if ($Config{d_fork} and $^O ne 'VMS') { + if ($Config{d_fork} and $^O ne 'VMS' and $^O ne 'MSWin32') { # Fork off a new perl to run the tests. # (This is so we can catch spurious warnings.) $| = 1; print ""; $| = 0; # flush output before forking @@ -411,9 +411,11 @@ END my $errfile = "terr$$"; $errfile++ while -e $errfile; my @tmpfiles = ($cmdfile, $errfile); open CMD, ">$cmdfile"; print CMD $code; close CMD; - my $cmd = ($^O eq 'VMS') ? "MCR $^X" : "./perl"; + my $cmd = (($^O eq 'VMS') ? "MCR $^X" + : ($^O eq 'MSWin32') ? '.\perl' + : './perl'); $cmd .= " -w $cmdfile 2>$errfile"; - if ($^O eq 'VMS') { + if ($^O eq 'VMS' or $^O eq 'MSWin32') { # Use pipe instead of system so we don't inherit STD* from # this process, and then foul our pipe back to parent by # redirecting output in the child. diff --git a/t/op/exec.t b/t/op/exec.t index 1103a1a464..7dfcd6177f 100755 --- a/t/op/exec.t +++ b/t/op/exec.t @@ -3,6 +3,13 @@ # $RCSfile: exec.t,v $$Revision: 4.1 $$Date: 92/08/07 18:27:49 $ $| = 1; # flush stdout + +if ($^O eq 'MSWin32') { + print "# exec is unsupported on Win32\n"; + print "1..0\n"; + exit(0); +} + print "1..8\n"; print "not ok 1\n" if system "echo ok \\1"; # shell interpreted diff --git a/t/op/glob.t b/t/op/glob.t index cc60a17a72..dd95e980d5 100755 --- a/t/op/glob.t +++ b/t/op/glob.t @@ -7,7 +7,12 @@ print "1..6\n"; @oops = @ops = ; map { $files{$_}++ } ; -map { delete $files{$_} } split /[\s\n]/, `echo op/*`; +if ($^O eq 'MSWin32') { + map { delete $files{"op/$_"} } split /[\s\n]/, `cmd /c "dir /b /l op"`; +} +else { + map { delete $files{$_} } split /[\s\n]/, `echo op/*`; +} if (keys %files) { print "not ok 1\t(",join(' ', sort keys %files),"\n"; } else { print "ok 1\n"; } diff --git a/t/op/goto.t b/t/op/goto.t index 087331907e..1b34acda39 100755 --- a/t/op/goto.t +++ b/t/op/goto.t @@ -31,7 +31,8 @@ label4: print "#2\t:$foo: == 4\n"; if ($foo == 4) {print "ok 2\n";} else {print "not ok 2\n";} -$x = `./perl -e 'goto foo;' 2>&1`; +$PERL = ($^O eq 'MSWin32') ? '.\perl' : './perl'; +$x = `$PERL -e "goto foo;" 2>&1`; if ($x =~ /DCL-W-NOCOMD/) { $x = `\$ mcr sys\$disk:[]perl. -e "goto foo;"`; } if ($x =~ /label/) {print "ok 3\n";} else {print "not ok 3\n";} diff --git a/t/op/magic.t b/t/op/magic.t index 70f2bec2c3..fa19716c14 100755 --- a/t/op/magic.t +++ b/t/op/magic.t @@ -19,10 +19,14 @@ sub ok { } } +$Is_MSWin32 = ($^O eq 'MSWin32'); +$PERL = ($Is_MSWin32 ? '.\perl' : './perl'); + print "1..28\n"; eval '$ENV{"foo"} = "hi there";'; # check that ENV is inited inside eval -ok 1, `echo \$foo` eq "hi there\n"; +if ($Is_MSWin32) { ok 1, `set foo` eq "foo=hi there\n"; } +else { ok 1, `echo \$foo` eq "hi there\n"; } unlink 'ajslkdfpqjsjfk'; $! = 0; @@ -30,10 +34,14 @@ open(FOO,'ajslkdfpqjsjfk'); ok 2, $!, $!; close FOO; # just mention it, squelch used-only-once -# the next tests are embedded inside system simply because sh spits out -# a newline onto stderr when a child process kills itself with SIGINT. - -system './perl', '-e', <<'END'; +if ($Is_MSWin32) { + ok 3,1; + ok 4,1; +} +else { + # the next tests are embedded inside system simply because sh spits out + # a newline onto stderr when a child process kills itself with SIGINT. + system './perl', '-e', <<'END'; $| = 1; # command buffering @@ -51,8 +59,10 @@ system './perl', '-e', <<'END'; } END +} -@val1 = @ENV{keys(%ENV)}; # can we slice ENV? +# can we slice ENV? +@val1 = @ENV{keys(%ENV)}; @val2 = values(%ENV); ok 5, join(':',@val1) eq join(':',@val2); ok 6, @val1 > 1; @@ -84,9 +94,9 @@ ok 13, (keys %h)[0] eq "foo\034bar", (keys %h)[0]; } # $?, $@, $$ -system 'true'; +system "$PERL -e 'exit(0)'"; ok 15, $? == 0, $?; -system 'false'; +system "$PERL -e 'exit(1)'"; ok 16, $? != 0, $?; eval { die "foo\n" }; @@ -95,33 +105,38 @@ ok 17, $@ eq "foo\n", $@; ok 18, $$ > 0, $$; # $^X and $0 -if ($^O eq 'qnx' || $^O eq 'amigaos') { - chomp($wd = `pwd`); +if ($Is_MSWin32) { + for (19 .. 25) { ok $_, 1 } } else { - $wd = '.'; -} -$script = "$wd/show-shebang"; -$s1 = $s2 = "\$^X is $wd/perl, \$0 is $script\n"; -if ($^O eq 'os2') { - # Started by ksh, which adds suffixes '.exe' and '.' to perl and script - $s2 = "\$^X is $wd/perl.exe, \$0 is $script.\n"; -} -ok 19, open(SCRIPT, ">$script"), $!; -ok 20, print(SCRIPT <$script"), $!; + ok 20, print(SCRIPT <= 5.00319, $]; diff --git a/t/op/misc.t b/t/op/misc.t index 0f251ea354..02d32bd5c5 100755 --- a/t/op/misc.t +++ b/t/op/misc.t @@ -14,17 +14,24 @@ $tmpfile = "misctmp000"; 1 while -f ++$tmpfile; END { unlink $tmpfile if $tmpfile; } +$CAT = (($^O eq 'MSWin32') ? '.\perl -e "print <>"' : 'cat'); + for (@prgs){ my $switch; if (s/^\s*-\w+//){ $switch = $&; } my($prog,$expected) = split(/\nEXPECT\n/, $_); - open TEST, "| sh -c './perl $switch' >$tmpfile 2>&1"; + if ($^O eq 'MSWin32') { + open TEST, "| .\\perl -I../lib $switch >$tmpfile 2>&1"; + } + else { + open TEST, "| sh -c './perl $switch' >$tmpfile 2>&1"; + } print TEST $prog, "\n"; close TEST; $status = $?; - $results = `cat $tmpfile`; + $results = `$CAT $tmpfile`; $results =~ s/\n+$//; $expected =~ s/\n+$//; if ( $results ne $expected){ @@ -74,7 +81,7 @@ EXPECT ######## eval {sub bar {print "In bar";}} ######## -system "./perl -ne 'print if eof' /dev/null" +system './perl -ne "print if eof" /dev/null' ######## chop($file = <>); ######## diff --git a/t/op/rand.t b/t/op/rand.t index 4eeca6b10c..23a09b7388 100755 --- a/t/op/rand.t +++ b/t/op/rand.t @@ -329,12 +329,10 @@ AUTOSRAND: my($pid, $first); for (1..5) { - if ($^O eq 'VMS') { - $pid = open PERL, qq[MCR $^X -e "print rand"|]; - } - else { - $pid = open PERL, "./perl -e 'print rand'|"; - } + my $PERL = (($^O eq 'VMS') ? "MCR $^X" + : ($^O eq 'MSWin32') ? '.\perl' + : './perl'); + $pid = open PERL, qq[$PERL -e "print rand"|]; die "Couldn't pipe from perl: $!" unless defined $pid; if (defined $first) { if ($first ne ) { diff --git a/t/op/split.t b/t/op/split.t index 4144bbb88f..90bb436550 100755 --- a/t/op/split.t +++ b/t/op/split.t @@ -47,7 +47,8 @@ $_ = join(':', split(/:/,'1:2:3:4:5:6:::', 999)); print $_ eq '1:2:3:4:5:6:::' ? "ok 10\n" : "not ok 10 $_\n"; # Does assignment to a list imply split to one more field than that? -$foo = `./perl -D1024 -e '(\$a,\$b) = split;' 2>&1`; +if ($^O eq 'MSWin32') { $foo = `.\\perl -D1024 -e "(\$a,\$b) = split;" 2>&1` } +else { $foo = `./perl -D1024 -e '(\$a,\$b) = split;' 2>&1` } if ($foo =~ /DCL-W-NOCOMD/) { $foo = `\$ mcr sys\$disk:[]perl. "-D1024" -e "(\$a,\$b) = split;"`; } diff --git a/t/op/stat.t b/t/op/stat.t index f0fd9a00b1..d7271522c2 100755 --- a/t/op/stat.t +++ b/t/op/stat.t @@ -13,14 +13,16 @@ use Config; print "1..56\n"; -chop($cwd = `pwd`); +$Is_MSWin32 = $^O eq 'MSWin32'; +chop($cwd = ($Is_MSWin32 ? `cd` : `pwd`)); -$DEV = `ls -l /dev`; +$DEV = `ls -l /dev` unless $Is_MSWin32; unlink "Op.stat.tmp"; open(FOO, ">Op.stat.tmp"); -$junk = `ls Op.stat.tmp`; # hack to make Apollo update link count +# hack to make Apollo update link count: +$junk = `ls Op.stat.tmp` unless $Is_MSWin32; ($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,$atime,$mtime,$ctime, $blksize,$blocks) = stat(FOO); @@ -86,7 +88,7 @@ if (! -d 'Op.stat.tmp') {print "ok 22\n";} else {print "not ok 22\n";} if (-d '.') {print "ok 23\n";} else {print "not ok 23\n";} if (! -f '.') {print "ok 24\n";} else {print "not ok 24\n";} -if (`ls -l perl` =~ /^l.*->/) { +if (!$Is_MSWin32 and `ls -l perl` =~ /^l.*->/) { if (-l 'perl') {print "ok 25\n";} else {print "not ok 25\n";} } else { @@ -99,7 +101,9 @@ if (-e 'Op.stat.tmp') {print "ok 27\n";} else {print "not ok 27\n";} `rm -f Op.stat.tmp Op.stat.tmp2`; if (! -e 'Op.stat.tmp') {print "ok 28\n";} else {print "not ok 28\n";} -if ($DEV !~ /\nc.* (\S+)\n/) +if ($Is_MSWin32) + {print "ok 29\n";} +elsif ($DEV !~ /\nc.* (\S+)\n/) {print "ok 29\n";} elsif (-c "/dev/$1") {print "ok 29\n";} @@ -107,7 +111,9 @@ else {print "not ok 29\n";} if (! -c '.') {print "ok 30\n";} else {print "not ok 30\n";} -if ($DEV !~ /\ns.* (\S+)\n/) +if ($Is_MSWin32) + {print "ok 31\n";} +elsif ($DEV !~ /\ns.* (\S+)\n/) {print "ok 31\n";} elsif (-S "/dev/$1") {print "ok 31\n";} @@ -115,7 +121,9 @@ else {print "not ok 31\n";} if (! -S '.') {print "ok 32\n";} else {print "not ok 32\n";} -if ($DEV !~ /\nb.* (\S+)\n/) +if ($Is_MSWin32) + {print "ok 33\n";} +elsif ($DEV !~ /\nb.* (\S+)\n/) {print "ok 33\n";} elsif (-b "/dev/$1") {print "ok 33\n";} @@ -123,7 +131,7 @@ else {print "not ok 33\n";} if (! -b '.') {print "ok 34\n";} else {print "not ok 34\n";} -if ($^O eq 'amigaos') {print "ok 35\n"; goto tty_test;} +if ($^O eq 'amigaos' or $Is_MSWin32) {print "ok 35\n"; goto tty_test;} $cnt = $uid = 0; @@ -147,12 +155,18 @@ else tty_test: -unless (open(tty,"/dev/tty")) { - print STDERR "Can't open /dev/tty--run t/TEST outside of make.\n"; +if ($Is_MSWin32) { + print "ok 36\n"; + print "ok 37\n"; +} +else { + unless (open(tty,"/dev/tty")) { + print STDERR "Can't open /dev/tty--run t/TEST outside of make.\n"; + } + if (-t tty) {print "ok 36\n";} else {print "not ok 36\n";} + if (-c tty) {print "ok 37\n";} else {print "not ok 37\n";} + close(tty); } -if (-t tty) {print "ok 36\n";} else {print "not ok 36\n";} -if (-c tty) {print "ok 37\n";} else {print "not ok 37\n";} -close(tty); if (! -t tty) {print "ok 38\n";} else {print "not ok 38\n";} open(null,"/dev/null"); if (! -t null || -e '/xenix' || -e '/MachTen') diff --git a/t/op/sysio.t b/t/op/sysio.t index 0f546b270f..ee274c1692 100755 --- a/t/op/sysio.t +++ b/t/op/sysio.t @@ -6,7 +6,7 @@ chdir('op') || die "sysio.t: cannot look for myself: $!"; open(I, 'sysio.t') || die "sysio.t: cannot find myself: $!"; -$reopen = ($^O eq 'VMS' || $^O eq 'os2'); +$reopen = ($^O eq 'VMS' || $^O eq 'os2' || $^O eq 'MSWin32'); $x = 'abc'; diff --git a/t/op/taint.t b/t/op/taint.t index 56765fb71d..66e26d82c9 100755 --- a/t/op/taint.t +++ b/t/op/taint.t @@ -16,14 +16,18 @@ use strict; use Config; my $Is_VMS = $^O eq 'VMS'; -my $Invoke_Perl = $Is_VMS ? 'MCR Sys$Disk:[]Perl.' : './perl'; +my $Is_MSWin32 = $^O eq 'MSWin32'; +my $Invoke_Perl = $Is_VMS ? 'MCR Sys$Disk:[]Perl.' : + $Is_MSWin32 ? '.\perl' : './perl'; if ($Is_VMS) { + my ($olddcl) = $ENV{'DCL$PATH'} =~ /^(.*)$/; + my ($oldifs) = $ENV{IFS} =~ /^(.*)$/; eval <