Making rsync compile under Mac OS X 10.3.9 with extended
attributes
Vitorio Machado
v.machado at permanence-informatique.fr
Fri Feb 15 21:48:27 GMT 2008
I've corrected the bug that was making rsync crash, a silly pointer
issue (was using &value instead of value, shame on me).
I've also corrected a bracket bug in sys_llistxattr: sizeof foo is
dangerous as sizeof is a macro, works fine as value, but on return
variable it bugs. I've changed in sizeof(foo).
Also putted some printfs to be able to debug easily when verbose > 3
(option -vvvv).
Now it's working here, there is only a Finder bug that doesn't display
a file with only a resource fork.
Ordinateur-de-LaG:~/Desktop/rsync-test lag$ ls -la ../test/
total 24
drwxr-xr-x 4 lag lag 136 15 Feb 21:53 .
drwx------ 11 lag lag 374 15 Feb 22:17 ..
-rw-r--r-- 1 lag lag 6148 15 Feb 21:53 .DS_Store
-rw-r--r-- 1 lag lag 0 15 Feb 15:55 ons.o io.o compat.o hlink.o
.textClipping
Ordinateur-de-LaG:~/Desktop/rsync-test lag$ ls -la ../test/ons.o\ io.o\
compat.o\ hlink.o\ .textClipping/rsrc
-rw-r--r-- 1 lag lag 2617 15 Feb 15:55 ../test/ons.o io.o compat.o
hlink.o .textClipping/rsrc
Ordinateur-de-LaG:~/Desktop/rsync-test lag$ ls -la ~/rsynctest/
total 8
drwxr-xr-x 3 lag lag 102 15 Feb 22:06 .
drwxr-xr-x 17 lag lag 578 15 Feb 22:03 ..
-rw-r--r-- 1 lag lag 0 15 Feb 15:55 ons.o io.o compat.o hlink.o
.textClipping
Ordinrdinateur-de-LaG:~/Desktop/rsync-test lag$ ls -la
~/rsynctest/ons.o\ io.o\ compat.o\ hnnkk.textClipping/rsrc
-rw-r--r-- 1 lag lag 2617 15 Feb 15:55 /Users/lag/rsynctest/ons.o
io.o compat.o hlink.o .textClipping/rsrc
Ordinateur-de-LaG:~/Desktop/rsync-test lag$ cat ~/rsynctest/ons.o\
io.o\ compat.o\ hlink.o\ .textClipping/rsrc
?Z?ons.o io.o compat.o hlink.o token.o uidlist.o socket.o
hashtable.o fileio.o batch.o clientname.o chmod.o acls.o xattrs.o
progress.o pipe.o params.o loadparm.o clientserver.o access.o
connection.o authenticate.o lib/wildmatch.o lib/compat.o lib/snprintf.o
lib/mdfour.o lib/md5.o lib/permstring.o lib/pool_alloc.o lib/sysacls.o
lib/sysxattrs.o zlib/deflate.o zlib/inffast.o zlib/inflate.o
zlib/inftrees.o zlib/trees.o zlib/zutil.o zlib/adler32.o
zlib/compress.o zlib/crc32.o popt/findme.o popt/popt.o
popt/poptconfig.o popt/popthelp.o popt/poptparse.o rsync tls getgroups
getfsdev trimslash t_unsafe wildtest tls.o getgroups.o getfsdev.o
t_stub.o t_unsafe.o trimslash.o wildtest.o testsuite/chown-fake.test
testsuite/devices-fake.test \?ons.o io.o compat.o hlink.o token.o
uidlist.o socket.o hashtable.o fileio.o batch.o clientname.o chmod.o
acls.o xattrs.o progress.o pipe.o params.o loadparm.o clientserver.o
access.o connection.o authenticate.o lib/wildmatch.o lib/compat.o
lib/snprintf.o lib/mdfour.o lib/md5.o lib/permstring.o lib/pool_alloc.o
lib/sysacls.o lib/sysxattrs.o zlib/deflate.o zlib/inffast.o
zlib/inflate.o zlib/inftrees.o zlib/trees.o zlib/zutil.o zlib/adler32.o
zlib/compress.o zlib/crc32.o popt/findme.o popt/popt.o
popt/poptconfig.o popt/popthelp.o popt/poptparse.o rsync tls getgroups
getfsdev trimslash t_unsafe wildtest tls.o getgroups.o getfsdev.o
t_stub.o t_unsafe.o trimslash.o wildtest.o testsuite/chown-fake.test
testsuite/devices-fake.test \0utxtTEXT ?Z>
?QZutxtTEXT&drag2??_????_????_?Ordinateur-de-LaG:~/Desktop/rsync-test
lag$
As you can see, on the Terminal the Text Clipping ons.o io.o compat.o
hlink.o .textClipping is just fine, but it won't appear in the Finder
even after deleting the .DS_Store.
Maybe rsync see an empty data fork and doesn't create a data fork in
the destination file. But maybe it's only the Panther's Finder that is
buggy.
@Rob: Are you sure you proceed as this for patching?
1) Download a fresh 3.0.0pre9 rsync and its patches folder
2) Put the patches folder into the rsync folder
3) Launch a Terminal and go to rsync folder (example: cd
~/Desktop/rsync)
4) Copy past the command: patch -p1 <patches/flags.diff
5) Copy past the command: patch -p1 <patches/crtimes.diff
6) Use the command: patch -p1 <path/to/rsync10.3xattr_supportv0.2.diff
substituting path/to by the right path
7) ./configure
8) make
The error you described me comes from ACL that seems to be built in
your config but it should be off as 10.3 doesn't support ACLs. Your
./configure should end like this:
checking whether -c -o works... yes
checking sys/acl.h usability... no
checking sys/acl.h presence... no
checking for sys/acl.h... no
checking acl/libacl.h usability... no
checking acl/libacl.h presence... no
checking for acl/libacl.h... no
checking for _acl... no
checking for __acl... no
checking for _facl... no
checking for __facl... no
checking whether to support ACLs... running tests:
checking for acl_get_file in -lacl... no
checking for ACL support... no
checking ACL test results... No ACL support found
checking attr/xattr.h usability... no
checking attr/xattr.h presence... no
checking for attr/xattr.h... no
checking sys/xattr.h usability... no
checking sys/xattr.h presence... no
checking for sys/xattr.h... no
checking sys/extattr.h usability... no
checking sys/extattr.h presence... no
checking for sys/extattr.h... no
checking whether to support extended attributes... Using OS X PreTiger
attrs
configure.sh: creating ./config.status
config.status: creating Makefile
config.status: creating lib/dummy
config.status: creating zlib/dummy
config.status: creating popt/dummy
config.status: creating shconfig
config.status: creating config.h
rsync 3.0.0pre9 configuration successful
If it says "checking whether to support ACLs... Using OS X ACLs", you
can force it to disable ACL running:
./configure --disable-acl-support
instead of simply ./configure
I think this time we got something more or less functional. Got to test
it!
Vitorio
-------------- next part --------------
A non-text attachment was scrubbed...
Name: rsync10.3xattr_supportv0.2.diff
Type: application/octet-stream
Size: 18637 bytes
Desc: not available
Url : http://lists.samba.org/archive/rsync/attachments/20080215/8f85dbdf/rsync10.3xattr_supportv0.2.obj
More information about the rsync
mailing list