I am making a new package from a project that I've been working on for practice. I've been using git, and I've noticed similarities between it and the Debian packing system. What's confusing me is when I make a change to any of the files and do not manually update the .orig.tar.xz file, dpkg wants me to add a patch. Making patches is very annoying and the source code in the .orig is not updated so it's a nightmare to extract.Now if I manually update .orig.tar.xz as well as make a new entry in changelog, it seems to be much more clean, it increments the build count as well (ie 3.2-2 -> 3.2-3).When should I use patch vs when should I update .orig and changelog?
Debian packaging: whats the difference between patches and changelog?
debian;packaging;deb
For the now standard Debian source format 3.0 (quilt), the correct procedure when you make changes to the original/upstream source, is to add corresponding patches in the debian/patches directory, not to .orig.tar.xz. This is commonly done using quilt, but you can alternatively use a proper version control system like Git, if you want.The Debian build system will automatically recreate the .debian.tar.xz based on the contents of the debian directory (including the patches subdirectory). The .orig.tar.xz file should not be modified. It's the upstream source.And as for updating the changelog, that's up to you. Updating the changelog will increment the Debian version number. It has no direct bearing on patching the source.