Hello everyone, I have run into the same issue which the fname-convert patch solves: http://rsync.samba.org/ftp/unpacked/rsync/patches/fname-convert.diff i.e. rsyncing between and latin 1 and utf-8 locales. First I'd really like to thank Eran Tromer for providing the patch as this fixes my immediate issue! I've attached an updated version which applies to the rsync-2.6.5 release and includes updates to proto.h. I must admit, I would have been fully pleased with a libiconv solution that merely interprets the file names in the character set defined be the current locale of the process and converted into UTF-8 internally for comparison/transfer to the remote system, and converts the UTF-8 representation back to the charset defined by the local process on when writing files. But this would have needed both rsync versions to support this feature, couldn't handle conversion if the file names on the local system could not be interpreted in the locale of the process and of course lacks the extreme flexibility of the conversion which this solution allows. It think it would be great if this patch (or something similar) could make it into the trunk. Let me also thank Paul Slootman for pointing me to this patch! Thanks a lot folks! David Ayers -------------- next part -------------- A non-text attachment was scrubbed... Name: fname-convert.patch Type: text/x-patch Size: 19701 bytes Desc: not available Url : http://lists.samba.org/archive/rsync/attachments/20050728/3e9ad5a3/fname-convert.bin
On Thu, Jul 28, 2005 at 12:35:21PM +0200, David Ayers wrote:> I've attached an updated version which applies to the rsync-2.6.5 > release and includes updates to proto.h.2.6.5 already comes with the patch in the "patches" subdir (and none of the patches have proto.h changes because they are easily recreated via "make proto").> It think it would be great if this patch (or something similar) could > make it into the trunk.I've commented before that I don't like this solution, so this will never go onto the trunk. If someone would like to work on a solution that uses iconv library calls, I'd be glad to consider including that. Complexities including adding a option(s) to indicate the encoding to be used on the client and the server side, using UTF-8 for the names sent over the wire, and always outputting names in messages using the client encoding. Also, there would be no need to increment the protocol version since an older rsync would not understand the conversion option(s) that the client would send to it. ..wayne..
On Thu, 2005-07-28 12:35:21 +0200, David Ayers <d.ayers@inode.at> wrote:> diff -uNr ../rsync-2.6.5/fnameconv.c ./fnameconv.c > --- ../rsync-2.6.5/fnameconv.c 1970-01-01 01:00:00.000000000 +0100 > +++ ./fnameconv.c 2005-07-28 11:29:59.202388904 +0200 > @@ -0,0 +1,220 @@[...]> +/** > + * Runs the filename converter process. Should be called before filename > + * conversion begins (actually it's not necessarh, but it keeps the proress report^^^^^^^ Typo in comment. MfG, JBG -- Jan-Benedict Glaw jbglaw@lug-owl.de . +49-172-7608481 _ O _ "Eine Freie Meinung in einem Freien Kopf | Gegen Zensur | Gegen Krieg _ _ O fuer einen Freien Staat voll Freier Buerger" | im Internet! | im Irak! O O O ret = do_actions((curr | FREE_SPEECH) & ~(NEW_COPYRIGHT_LAW | DRM | TCPA)); -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 189 bytes Desc: Digital signature Url : http://lists.samba.org/archive/rsync/attachments/20050728/dec1d117/attachment.bin