]> git.e2factory.org Git - e2factory.git/commitdiff
e2tool: error on configured/installed version mismatch
authorTobias Ulmer <tu@emlix.com>
Tue, 28 Jun 2016 16:32:30 +0000 (18:32 +0200)
committerTobias Ulmer <tu@emlix.com>
Wed, 16 Nov 2016 14:41:18 +0000 (15:41 +0100)
Signed-off-by: Tobias Ulmer <tu@emlix.com>
local/e2-build.lua
local/e2tool.lua

index d7ccaf6648a920c5f83e3e4895f46149409cd82e..bc50db38affc5ddf3dd541c311b9d8b3d69c9a6d 100644 (file)
@@ -192,19 +192,6 @@ local function e2_build(arg)
         error(re)
     end
 
-    if opts.release then
-        local version_table, re = e2lib.parse_e2versionfile(
-            e2lib.join(info.root, e2lib.globals.e2version_file))
-        if not version_table then
-           error(re)
-        end
-
-        if version_table.tag == "^" then
-            error(
-                err.new("e2 is on a pseudo tag while building in release mode."))
-        end
-    end
-
     -- calculate buildids for selected results
     for _,r in ipairs(sel_res) do
         local bid, re = e2tool.buildid(info, r)
index 127c412da5869cd3dc53f3f1c209e9a79ade1599..952746b116857e93d9dd459d63f754245b16cab7 100644 (file)
@@ -528,22 +528,16 @@ function e2tool.collect_project_info(info, skip_load_config)
     -- if x86_64 mode is requested.
     info.chroot_call_prefix["x86_64"] = ""
 
-    if e2option.opts["check"] then
-        local f = e2lib.join(info.root, e2lib.globals.e2version_file)
-        local v, re = e2lib.parse_e2versionfile(f)
-        if not v then
-            return false, re
-        end
+    local f = e2lib.join(info.root, e2lib.globals.e2version_file)
+    local v, re = e2lib.parse_e2versionfile(f)
+    if not v then
+        return false, re
+    end
 
-        if v.tag == "^" then
-            return false, err.new("local tool version is not configured to " ..
-                "a fixed tag\nfix you configuration in %s before running " ..
-                "e2factory in release mode", f)
-        elseif v.tag ~= buildconfig.VERSIONSTRING then
-            return false, err.new("local tool version does not match the " ..
-                "version configured\n in `%s`\n local tool version is %s\n" ..
-                "required version is %s", f, buildconfig.VERSIONSTRING, v.tag)
-        end
+    if v.tag ~= buildconfig.VERSIONSTRING then
+        return false, err.new("local tool version does not match the " ..
+            "version configured\n in `%s`\nlocal tool version is %s\n" ..
+            "required version is %s", f, buildconfig.VERSIONSTRING, v.tag)
     end
 
     -- read environment configuration