Fix Patch Debian Packages
###########################

For automatic script check this out: sdbe

Here are manual steps to patch a debian package:

 

dpkg –info packagename-NEW.deb
dpkg –contents packagename-NEW.deb
# install new package
dpkg -i packagename-NEW.deb

GOOD NOTES:
http://www.g-loaded.eu/2008/01/28/how-to-extract-rpm-or-deb-packages/
http://ubuntuforums.org/showthread.php?t=1826900
Re: patching a deb package using “ar” for unpacking and packing
I’ve been told that it is not a good idea to use ar for packaging debs. Apparently there are two versions of ar. The one that comes with Ubuntu/Debian is the GNU version. But the one that is built into dpkg is the BSD version and apparently there are small differences in the produced packages. I’m not 100% sure about this, but it is what I have been told.
This is what I would do: Create a directory to hold the contents of the deb. Unpack the contents of data.tar.gz to the directory. Make a subdirectory called “DEBIAN” and extract the contents of control.tar.gz to the DEBIAN directory. Make your changes then repackage using dpkg. From a terminal navigate to the directory that contains your new directory. So if you placed your directory on the desktop you would navigate to the desktop. Now use the following command to package the deb (I’m doing this from memory so I hope that it is all correct):
Code:
fakeroot dpkg -b mydirectory

 

Leave a Reply

Your email address will not be published. Required fields are marked *