Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

If I modify the source code of some package that I've installed with apt-get in Ubuntu, is there some package tool that will let me see the diff between what was the original installation and my modifications?

share|improve this question
    
I'm modifying the source code of the packages and, for the record, I realize this isn't the ideal way to work. However, I'm just doing some quick and dirty testing on throw away VMs so I'm not too worried about it. –  Everett Toews Jul 8 '11 at 20:49

4 Answers 4

up vote 2 down vote accepted

How did you perform these modifications? Did you just modify the some of the files that where already installed, or did you download the source package, modify that, and the build a new package? If you built your own package then you should have generated a .diff. If you just modified installed stuff look at debsums.

Or you could always download and extract (dpkg -x foo.deb /tmp/bar.dir) the official package, then diff that against the files you have installed.

If really need to make local changes to files that are installed I strongly suggest you consider learning how to build your own Debian packages.

share|improve this answer

There's a tool called blueprint that might do what you're looking for:

Blueprint looks inside popular package managers, finds changes you made to configuration files, and archives software you built from source.

share|improve this answer

You can view the differences between two versions of a binary package (.deb) using the debdiff tool in the devscripts package. If you want to see the differences between versions of a source package, you can run debdiff on the .dsc or .changes files, but I prefer an interdiff -z on the .diff.gz files for the two versions of the packages.

Of course, this all presumes that you're making your local changes "properly". If you're doing a bodge job (modifying files in place, or unpacking and repacking the binary package) then all bets are off, both in how you'd do the diff, as well as what's going to go wrong with your systems in the future.

share|improve this answer

Not really. debsums will show you which files have been changed, but there's no tool I'm aware of that will get any more specific than that.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.