From c37c95d8996b06cf76e834afe3b95d6c40274caa Mon Sep 17 00:00:00 2001 From: =?utf8?q?Thibaut=20VAR=C3=88NE?= Date: Wed, 27 Jun 2018 18:12:39 +0200 Subject: [PATCH] phase1: move kmod archive after 'checksums' MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit We don't want the special kmod archive to show up in checksums output. Signed-off-by: Thibaut VARÈNE --- phase1/master.cfg | 51 +++++++++++++++++++++++++---------------------- 1 file changed, 27 insertions(+), 24 deletions(-) diff --git a/phase1/master.cfg b/phase1/master.cfg index c49d79e..5bf8d90 100644 --- a/phase1/master.cfg +++ b/phase1/master.cfg @@ -753,30 +753,7 @@ for target in targets: )) if enable_kmod_archive: - factory.addStep(ShellCommand( - name = "kmoddir", - description = "Creating kmod directory", - command=["mkdir", "-p", Interpolate("bin/targets/%(kw:target)s/%(kw:subtarget)s%(prop:libc)s/kmods/%(prop:kernelversion)s", target=ts[0], subtarget=ts[1])], - haltOnFailure = True - )) - - factory.addStep(ShellCommand( - name = "kmodprepare", - description = "Preparing kmod archive", - command=["rsync", "--include=/kmod-*.ipk", "--exclude=*", "-va", - Interpolate("bin/targets/%(kw:target)s/%(kw:subtarget)s%(prop:libc)s/packages/", target=ts[0], subtarget=ts[1]), - Interpolate("bin/targets/%(kw:target)s/%(kw:subtarget)s%(prop:libc)s/kmods/%(prop:kernelversion)s/", target=ts[0], subtarget=ts[1])], - haltOnFailure = True - )) - - factory.addStep(ShellCommand( - name = "kmodindex", - description = "Indexing kmod archive", - command=["make", Interpolate("-j%(kw:jobs)s", jobs=GetNumJobs), "package/index", "V=s", - Interpolate("PACKAGE_SUBDIRS=bin/targets/%(kw:target)s/%(kw:subtarget)s%(prop:libc)s/kmods/%(prop:kernelversion)s/", target=ts[0], subtarget=ts[1])], - env = MakeEnv(), - haltOnFailure = True - )) + # embed kmod repository. Must happen before 'images' # find rootfs staging directory factory.addStep(SetPropertyFromCommand( @@ -827,6 +804,32 @@ for target in targets: haltOnFailure = True )) + if enable_kmod_archive: + factory.addStep(ShellCommand( + name = "kmoddir", + description = "Creating kmod directory", + command=["mkdir", "-p", Interpolate("bin/targets/%(kw:target)s/%(kw:subtarget)s%(prop:libc)s/kmods/%(prop:kernelversion)s", target=ts[0], subtarget=ts[1])], + haltOnFailure = True + )) + + factory.addStep(ShellCommand( + name = "kmodprepare", + description = "Preparing kmod archive", + command=["rsync", "--include=/kmod-*.ipk", "--exclude=*", "-va", + Interpolate("bin/targets/%(kw:target)s/%(kw:subtarget)s%(prop:libc)s/packages/", target=ts[0], subtarget=ts[1]), + Interpolate("bin/targets/%(kw:target)s/%(kw:subtarget)s%(prop:libc)s/kmods/%(prop:kernelversion)s/", target=ts[0], subtarget=ts[1])], + haltOnFailure = True + )) + + factory.addStep(ShellCommand( + name = "kmodindex", + description = "Indexing kmod archive", + command=["make", Interpolate("-j%(kw:jobs)s", jobs=GetNumJobs), "package/index", "V=s", + Interpolate("PACKAGE_SUBDIRS=bin/targets/%(kw:target)s/%(kw:subtarget)s%(prop:libc)s/kmods/%(prop:kernelversion)s/", target=ts[0], subtarget=ts[1])], + env = MakeEnv(), + haltOnFailure = True + )) + # sign if gpg_keyid is not None: factory.addStep(MasterShellCommand( -- 2.30.2