Skip Menu |

This queue is for tickets about the Archive-Tar CPAN distribution.

Report information
The Basics
Id: 1961
Status: resolved
Priority: 0/
Queue: Archive-Tar

People
Owner: kane [...] cpan.org
Requestors: kane [...] dwim.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.22
Fixed in: (no value)



Subject: Archive::Tar->write() of version 0.22 will NOT WORK on Win32
use Archive::Tar; use strict; my $tar = new Archive::Tar; $tar->add_files($0); for (0..1) { eval { $tar->write('tmp' . scalar $_, $_) }; warn "case $_: $@" if $@; } __END__ case 0: Your vendor has not defined Fcntl macro F_GETFL, used at C:/Perl/site/lib/Archive/Tar.pm line 265. case 1: Can't call method "gzwrite" on an undefined value at C:/Perl/site/lib/Archive/Tar.pm line 509. in case 0, it's obvious what's at fault: you can't call fcntl on win32 apparently. in case 1, this part is the problem: $fh = Compress::Zlib::gzdopen_ ($fh, $mode, 0) or &_drat; which occurs at roughly line 255 in my source (version 0.22) since before that, Dumper $fh == $VAR1 = \*Symbol::GEN1; and after that, Dumper $fh == $VAR1 = undef this file also attached. this bug has also been reported to activestate: http://bugs.activestate.com/show_bug.cgi?id=22790
use Archive::Tar; use strict; my $tar = new Archive::Tar; $tar->add_files($0); for (0..1) { eval { $tar->write('tmp' . scalar $_, $_) }; warn "case $_: $@" if $@; } __END__ Your vendor has not defined Fcntl macro F_GETFL, used at C:/Perl/site/lib/Archive/Tar.pm line 265. Can't call method "gzwrite" on an undefined value at C:/Perl/site/lib/Archive/Tar.pm line 509.
From: kane
perl -V for completeness: C:\>perl -V Summary of my perl5 (revision 5 version 8 subversion 0) configuration: Platform: osname=MSWin32, osvers=4.0, archname=MSWin32-x86-multi-thread uname='' config_args='undef' hint=recommended, useposix=true, d_sigaction=undef usethreads=undef use5005threads=undef useithreads=define usemultiplicity=def ine useperlio=define d_sfio=undef uselargefiles=define usesocks=undef use64bitint=undef use64bitall=undef uselongdouble=undef usemymalloc=n, bincompat5005=undef Compiler: cc='cl', ccflags ='-nologo -Gf -W3 -MD -DNDEBUG -O1 -DWIN32 -D_CONSOLE -DNO_ STRICT -DHAVE_DES_FCRYPT -DPERL_IMPLICIT_CONTEXT -DPERL_IMPLICIT_SYS -DUSE_PERL IO -DPERL_MSVCRT_READFIX', optimize='-MD -DNDEBUG -O1', cppflags='-DWIN32' ccversion='', gccversion='', gccosandvers='' intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=1234 d_longlong=undef, longlongsize=8, d_longdbl=define, longdblsize=10 ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='__int64', lseeksi ze=8 alignbytes=8, prototype=define Linker and Libraries: ld='link', ldflags ='-nologo -nodefaultlib -release -libpath:"C:\Perl\lib\C ORE" -machine:x86' libpth="C:\Perl\lib\CORE" libs= oldnames.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32 .lib advapi32.lib shell32.lib ole32.lib oleaut32.lib netapi32.lib uuid.lib wsoc k32.lib mpr.lib winmm.lib version.lib odbc32.lib odbccp32.lib msvcrt.lib perllibs= oldnames.lib kernel32.lib user32.lib gdi32.lib winspool.lib comd lg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib netapi32.lib uuid.lib wsock32.lib mpr.lib winmm.lib version.lib odbc32.lib odbccp32.lib msvcrt.lib libc=msvcrt.lib, so=dll, useshrplib=yes, libperl=perl58.lib gnulibc_version='undef' Dynamic Linking: dlsrc=dl_win32.xs, dlext=dll, d_dlsymun=undef, ccdlflags=' ' cccdlflags=' ', lddlflags='-dll -nologo -nodefaultlib -release -libpath:"C: \Perl\lib\CORE" -machine:x86' Characteristics of this binary (from libperl): Compile-time options: MULTIPLICITY USE_ITHREADS USE_LARGE_FILES PERL_IMPLICIT_ CONTEXT PERL_IMPLICIT_SYS Locally applied patches: ActivePerl Build 804 Built under MSWin32 Compiled at Dec 1 2002 23:15:13 %ENV: PERL5LIB="f:\p4\cpanplus\devel" @INC: f:\p4\cpanplus\devel C:/Perl/lib C:/Perl/site/lib . C:\>