develooper Front page | perl.perl5.porters | Postings from March 2014

-l on win32, VMS etc

Thread Next
Dave Mitchell
March 26, 2014 11:03
-l on win32, VMS etc
Message ID:
There's some code I want to fix in ExtUtils::Install which currently does

    chmod 0666, $file;
    unlink $file;

and I want to change it to 

    chmod 0666, $file unless -l $file;
    unlink $file;

but I don't know how to do this on non-UNIX platforms.

I'm wondering whether I can rely on -l always being false on platforms
that don't support symlinks? perlport is very vague: it just says:

    C<-g>, C<-k>, C<-l>, C<-u>, C<-A> are not particularly meaningful.
    (Win32, VMS, S<RISC OS>)

Or do I have to do the whole $^O thing? Or some other approach?

(And does anyone know how to search for "-l" in google?)

Dave's first rule of Opera:
If something needs saying, say it: don't warble it.

Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About