perl -x doesn't recognize file as executable

Gerrit P. Haase gerrit@familiehaase.de
Mon Jun 6 12:08:00 GMT 2005


Yitzchak Scott-Thoennes wrote:
> On Sun, Jun 05, 2005 at 06:31:31PM -0700, Brian Dessent wrote:
> 
>>Volker Quetschke wrote:
>>
>>
>>>You mean special logic for windows file permissions (ACL?), not only
>>>using the owner/group/other scheme?
>>
>>I think that it recognises files ending in ".exe" and special-cases
>>them.
>>
>>
>>>$ getfacl /cygdrive/c/Programme/NSIS/NSIS.exe
>>># file: /cygdrive/c/Programme/NSIS/NSIS.exe
>>># owner: Administratoren
>>># group: none
>>>user::rwx
>>>group::---
>>>group:SYSTEM:rwx
>>>group:Benutzer:r-x
>>>                  ^
>>>with ------------|
>>>
>>>So it is executable. But ugo rights do not show this
>>
>>You're right.  But as far as I know most unix utilities don't know about
>>ACLs and only recognise standard 777 type permissions.
> 
> 
> perl only checks ACLs if you ask it to.  What does:
> 
> $ perl -e 'use filetest "access"; if ( ! -x "/cygdrive/c/Programme/NSIS/NSIS.exe" ) {print "not executable";}'
> not executable
> 
> show?

Yep, this is ok, even if I'm not the owner.

gerrit@ismene /p/mirrors.rcn.net/pub/sourceware/cygwin/release/gcc/gcc-gdc
$ getfacl /c/Programme/Mozilla/mozilla.exe
# file: /c/Programme/Mozilla/mozilla.exe
# owner: Administrator
# group: Domänen-Benutzer
user::rwx
group::---
group:SYSTEM:rwx
mask:rwx
other:---

$ perl -e 'use filetest "access"; if ( ! -x 
"/c/Programme/Mozilla/mozilla.exe" ) {print "not executable";}'

gerrit@ismene ~
$


Gerrit
-- 
=^..^=


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/



More information about the Cygwin mailing list