Adjust file permissions also of files that are added during dh_quilt_patch stage
[live-boot-grml.git] / debian / rules
index 710e6fa..e84a4b9 100755 (executable)
@@ -1,8 +1,6 @@
 #!/usr/bin/make -f
 
 build:
-       # this is needed because dpatch doesn't do file modes on diffs.
-       chmod a+rx scripts/live-bottom/*
        # regular build.
        dh build
 
@@ -24,8 +22,17 @@ override_dh_auto_install:
        mkdir -p debian/live-boot-grml-initramfs-tools/usr/share
        mv debian/tmp/usr/share/initramfs-tools debian/live-boot-grml-initramfs-tools/usr/share
 
-override_dh_installinit:
-       dh_installinit -p live-boot-grml --no-restart-on-upgrade --no-start --update-rcd-params='start 89 0 6 .'
+       # this is needed because dpatch doesn't do file modes on diffs
+       # and we can't execute this fix during build stage as new files
+       # might be installed during dh_quilt_patch
+       chmod a+rx debian/live-boot-grml-initramfs-tools/usr/share/initramfs-tools/scripts/live-bottom/*
+       chmod a+rx debian/live-boot-grml-initramfs-tools/usr/share/initramfs-tools/hooks/*
+
+override_dh_builddeb:
+       dh_builddeb -- -Zgzip -z9
 
 override_dh_install:
        dh_install --fail-missing
+
+override_dh_installinit:
+       dh_installinit -p live-boot-grml --no-restart-on-upgrade --no-start --update-rcd-params='start 89 0 6 .'