building debs from source
make sure to have deb-src entries in your sources.list[.d]
among the installed packages should be at least
build-essential debhelper fakeroot autoconf automake
add more if necessary (like dh-make, quilt and so on)
get the dependencies right:
sudo apt-get build-dep $package
get the sources and build them:
sudo apt-get -b source $package
for manual adjustments, leave out the -b and in the package source dir, do
fakeroot debian/rules binary
after changing whatever you wanted different.