Dear Mentors, For a package [1], I have to patch one file (Makefile.am) twice: once from debian/patches, and the other times from debian/rules. The patch in debian/patches is needed to bring allow the use of a standard automake (upstream uses a patched version), while the patch done from debian/rules contains a rename of all libraries built. It is done in the following way:
------------------------8<------------------------------------- override_dh_autoreconf: sed s/libast/libstarlink_ast/g -i Makefile.am AUTOMAKE="automake --foreign" dh_autoreconf override_dh_clean: sed s/libstarlink_ast/libast/g -i Makefile.am dh_clean ------------------------8<------------------------------------- The problem is now, that debuild finally calls "dpkg-source --after-build", which undoes debian/patches before (or without) calling dh_clean. Since debian/patches works with the original names (libast), undoing the patches fails. What is the proper solution to deal with this? Converting the patching from debian/rules to a debian/patches patch is not a good solution, since the library names are heavily used in the whole Makefile.am, and the resulting patch would be huge, complicated (understanding the lines in debian/rules is much easier) and fill fail on each small change. Best regards Ole -- To UNSUBSCRIBE, email to debian-mentors-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/ytzlil09yqh....@news.ole.ath.cx