Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Modules/attr.c compile error on Mac OS X



(Aside: Sourceforge CVS access is really slow right now.)

On Mar 8,  7:55pm, Peter Stephenson wrote:
} Subject: Re: Modules/attr.c compile error on Mac OS X
}
} On Sun, 8 Mar 2009 17:21:47 +0900
} Taro M <taromeister@xxxxxxxxx> wrote:
} > The new Modules/attr.c does not compile on Mac OS X (and probably others):
} 
} I don't know about the others, and you don't say, but a bit of research
} suggests Mac OS X takes some extra arguments.  I don't have Mac OS X so
} can't test that; if it still doesn't compile, please could one of the
} numerous Mac users provide a patch.

Compiling on MacOS now ... snippet of config.log:

configure:13232: checking if getxattr etc. are Linux-like
configure:13264: gcc -c  -Wall -Wmissing-prototypes -O2  conftest.c >&5
conftest.c: In function 'main':
conftest.c:211: error: too few arguments to function 'listxattr'
conftest.c:212: error: too few arguments to function 'getxattr'
conftest.c:213: error: too few arguments to function 'setxattr'
conftest.c:214: error: too few arguments to function 'removexattr'
configure:13270: $? = 1
configure: failed program was:
    (omitted)
configure:13285: result: no
configure:13289: checking if getxattr etc. are MAC-like
configure:13319: gcc -c  -Wall -Wmissing-prototypes -O2  conftest.c >&5
configure:13325: $? = 0
configure:13340: result: yes
configure:13352: checking if getxattr etc. are usable
configure:13364: result: yes

However, it didn't build the attr module.  Still didn't build it after
a "make clean".  Missing dependency?  Trying again from "make distclean":
OK, compiled the attr module that time.

} If it compiles but doesn't work,
} I will need someone else to research the problem.

I tried this:

% zmodload zsh/attr
% for x in /*; print -R $x $'\t= ' $(zlistattr $x)
/Applications   = 
/Desktop DB     = com.apple.FinderInfo
/Desktop DF     = com.apple.FinderInfo
/Developer      = com.apple.FinderInfo
/Library        = 
/Network        = com.apple.FinderInfo
/System         = 
/User Guides And Information    = com.apple.FinderInfo
/Users  = 
/Volumes        = com.apple.FinderInfo
/bin    = com.apple.FinderInfo
/cores  = com.apple.FinderInfo
/dev    = 
/etc    = 
/home   = 
/mach.sym       = com.apple.FinderInfo
/mach_kernel    = com.apple.FinderInfo
/mach_kernel.ctfsys     = com.apple.FinderInfo
/net    = 
/opt    = 
/private        = com.apple.FinderInfo
/sbin   = com.apple.FinderInfo
/tmp    = 
/usr    = com.apple.FinderInfo
/var    = com.apple.FinderInfo

Is there more that should be tested?
 
} ... patches are useful even if incomplete (and preferred to text
} statements along the lines of "wouldn't it be better to change ...").

Pardon for my tendency to do that lately.  My inclination is to avoid
sending a patch unless I actually intend for someone to apply it, so
if I'm not certain about a change ...



Messages sorted by: Reverse Date, Date, Thread, Author