]> git.e2factory.org Git - e2factory.git/commitdiff
chroot: allow hashupdate for chroot config files
authorTobias Ulmer <tu@emlix.com>
Tue, 5 Jul 2022 10:39:21 +0000 (12:39 +0200)
committerTobias Ulmer <tu@emlix.com>
Wed, 31 Aug 2022 22:22:17 +0000 (00:22 +0200)
Signed-off-by: Tobias Ulmer <tu@emlix.com>
local/chroot.lua

index 1084374727ecb7f3a29e6b5840914215ee3af976..a7dce74d3d7c7c7c9ab69ae04a791f31c7ee1861 100644 (file)
@@ -1,7 +1,7 @@
 --- Chroot config module.
 -- @module local.chroot
 
--- Copyright (C) 2007-2016 emlix GmbH, see file AUTHORS
+-- Copyright (C) 2007-2022 emlix GmbH, see file AUTHORS
 --
 -- This file is part of e2factory, the emlix embedded build system.
 -- For more information see http://www.e2factory.org
@@ -48,6 +48,7 @@ local strict = require("strict")
 -- @field location File location.
 -- @field sha1 SHA1 sum, optional
 -- @field sha256 SHA256 sum, optional
+-- @field hashupdate Boolean flag, optional
 
 --- Default chroot group names applied to all results. Locked.
 chroot.groups_default = {}
@@ -259,6 +260,7 @@ function chroot.load_chroot_config()
                     "location",
                     "sha1",
                     "sha256",
+                    "hashupdate",
                 })
             if not rc then
                 return false, e:cat(re)
@@ -270,7 +272,7 @@ function chroot.load_chroot_config()
                 return false, e:cat(re)
             end
 
-            rc, re = file:validate_set_checksums(f.sha1, f.sha256)
+            rc, re = file:validate_set_checksums(f.sha1, f.sha256, f.hashupdate)
             if not rc then
                 e:cat(ferr)
                 return false, e:cat(re)