# Profiles
# We'd like to keep site.local from being a conffile
- rm ./profiles/apparmor.d/tunables/xdg-user-dirs.d/site.local
+ rm -f ./profiles/apparmor.d/tunables/xdg-user-dirs.d/site.local
cd profiles; $(MAKE) \
DESTDIR=$(CURDIR)/debian/tmp \
EXTRAS_DEST=$(CURDIR)/debian/tmp/usr/share/doc/apparmor-profiles/extras \
I wonder about executing these debian/rules commands on a 'live' system though, rather than using sbuild to build the package in a chroot environment. These rules are tested and expected to run in a temporary build environment, and if your local system actually had a file in that location that you cared about, building the .deb "by hand" would destroy it -- and perhaps other files you care about.
You're not the first to report this specific error but I really think the better answer is to use sbuild to build debs.
The following patch should do the trick:
--- wily/apparmor- 2.10/debian/ rules 2015-05-07 16:42:50.000000000 -0700 apparmor- 2.10/debian/ rules 2015-10-07 17:40:48.754397618 -0700
+++ wily.fixed/
@@ -137,7 +137,7 @@
# Profiles apparmor. d/tunables/ xdg-user- dirs.d/ site.local apparmor. d/tunables/ xdg-user- dirs.d/ site.local $(CURDIR) /debian/ tmp \ DEST=$( CURDIR) /debian/ tmp/usr/ share/doc/ apparmor- profiles/ extras \
# We'd like to keep site.local from being a conffile
- rm ./profiles/
+ rm -f ./profiles/
cd profiles; $(MAKE) \
DESTDIR=
EXTRAS_
I wonder about executing these debian/rules commands on a 'live' system though, rather than using sbuild to build the package in a chroot environment. These rules are tested and expected to run in a temporary build environment, and if your local system actually had a file in that location that you cared about, building the .deb "by hand" would destroy it -- and perhaps other files you care about.
You're not the first to report this specific error but I really think the better answer is to use sbuild to build debs.
Thanks