mackyle/fakeroot — pull request #1 by torsten-s (2012-10-18 11:18:26+00:00)
Title: Add wrappers for *xattr calls

This change adds support for setting extended attributes in a fakeroot environment.
The following syscalls are wrapped: {,l,f}{set,get,list,remove}xattr()
capset(2) is wrapped to make the userspace tool setcap(8) work.
Using setfattr(1) directly works too.

I tested the changes on linux i386 and amd64.

This change would be useful for packaging:
No more need to set xattr/capabilites in postinst.

Limitations:

Currently the ipc from libfakeroot.so to faked only deals with stat information.
I extended the message format to pass a fixed size (256byte) buffer around.
Extended attributes which need more space would generate an ERANGE error.

I did not test on platform other than linux or x86.

Best Regards,
Torsten Schmutzler