Score:0

How to patch rsync the correct way

cn flag

I want to patch rsync to support detect-renamed option, but I don't want to download a patch and extract it, I want to use apt (apt-get), how to do this?

Score:0
in flag

There is no way to patch a package without rebuilding it yourself. The easiest way to do this is probably to download the Debian package using apt, then build it with dpkg-buildpackage. To do this, first ensure that you have a line beginning with deb-src in your sources.list file. If you don't, copy the first 'deb' line (which should contain the name of your release), and switch the first word to deb-src.

Then, run sudo apt-get build-dep rsync and apt-get source rsync. Then, apply the patch to the source tree normally (instructions are given with this patch). Finally, call dpkg-buildpackage from inside the source tree. Use Gdebi to install the resulting binary package, which will be located in the parent directory of where the source tree was unpacked. You could also use dpkg to install it, but using Gdebi provides some useful safety checks.

cn flag
Hi, below is my current sources.list, can you help me further by showing how to add the rsync source/patches URL? I can't add the full file in the comment
Calum McConnell avatar
in flag
I explained how to add the source URL. The patch URL will need to be handled seprately: as far as I know, Apt is not designed to download and apply patches on packages at runtime.
cn flag
Thanks a lot for your help.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.