]> git.proxmox.com Git - mirror_zfs-debian.git/commitdiff
make dkms distdir before build
authorAntonio Russo <antonio.e.russo@gmail.com>
Sun, 1 Jul 2018 12:54:48 +0000 (08:54 -0400)
committerMo Zhou <cdluminate@gmail.com>
Fri, 26 Oct 2018 12:30:42 +0000 (12:30 +0000)
Per discussion with Fabian Gruenbichler, avoid pulling build artifacts
into the dkms source by extracting it ahead of dh_auto_build

Signed-off-by: Antonio Russo <antonio.e.russo@gmail.com>
debian/rules

index a699b0521da4bcca2f0307e0f15cab2019a17978..f3f15e4a7680863c3749efaa8b0e6baeaf85648b 100755 (executable)
@@ -57,6 +57,14 @@ endif
          --with-systemdpresetdir=/lib/systemd/system-preset \
          --with-config=user
 
+override_dh_auto_build:
+       @# Get a bare copy of the source code for DKMS.
+       @# This creates the $(CURDIR)/$(NAME)-$(DEB_VERSION_UPSTREAM)/ tree, which does not
+       @# contain the userland sources. NB: Remove-userland-dist-rules.patch
+       $(MAKE) distdir
+
+       dh_auto_build
+
 override_dh_auto_test:
        # The dh_auto_test rule is disabled because
        # `make check` cannot run in an unprivileged build environment.
@@ -81,11 +89,6 @@ override_dh_auto_install:
        $(INSTALL) -d '$(CURDIR)/debian/tmp/usr/sbin/'
        mv '$(CURDIR)/debian/tmp/sbin/zed' '$(CURDIR)/debian/tmp/usr/sbin/zed'
 
-       @# Get a bare copy of the source code for DKMS.
-       @# This creates the $(CURDIR)/$(NAME)-$(DEB_VERSION_UPSTREAM)/ tree, which does not
-       @# contain the userland sources. NB: Remove-userland-dist-rules.patch
-       $(MAKE) distdir
-
        @# Install the DKMS source.
        @# We only want the files needed to build the modules
        mkdir -p '$(CURDIR)/debian/tmp/usr/src/$(NAME)-$(DEB_VERSION_UPSTREAM)/scripts'