From 64c25ac8bfa4273c09e7fbf10ebb19c5c90ea13d Mon Sep 17 00:00:00 2001
From: Tino Lippold <Tino.Lippold@de.bosch.com>
Date: Mon, 19 Sep 2022 07:35:50 +0000
Subject: [PATCH] Print a message for failed ABI check

The call of the abi-compliance-checker might fail due to
errors. Possible reasons are the failed compilation of the
header files. To ease the analysis of the job logs the
additional printout might help.
Correct 'apt update' command.

Signed-off-by: Tino Lippold <Tino.Lippold@de.bosch.com>
---
 debian/changelog          | 8 ++++++++
 tools/apertis-abi-compare | 4 +++-
 2 files changed, 11 insertions(+), 1 deletion(-)

diff --git a/debian/changelog b/debian/changelog
index 3a99d7c..0b74133 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,11 @@
+apertis-dev-tools (0.2022.3) apertis; urgency=medium
+
+  * apertis-abi-compare:
+     - print a message in case of the ABI check fails due to errors
+     - correct 'apt update' command
+
+ -- Tino Lippold <Tino.Lippold@de.bosch.com>  Mon, 19 Sep 2022 07:19:12 +0000
+
 apertis-dev-tools (0.2022.2) apertis; urgency=medium
 
   * apertis-abi-compare:
diff --git a/tools/apertis-abi-compare b/tools/apertis-abi-compare
index fb0bf25..a332694 100755
--- a/tools/apertis-abi-compare
+++ b/tools/apertis-abi-compare
@@ -123,6 +123,8 @@ def run_abi_checker(lib, xml_old, ver_old, xml_new, ver_new):
         print('INFO: no ABI breakage detected!')
     elif acc_process.returncode == 1:
         print('WARNING: ABI breakage detected!')
+    else:
+        print('ERROR: ABI check failed!')
     return acc_process.returncode
 
 
@@ -196,7 +198,7 @@ def main():
     print("INFO: abi-compliance-checker requires having Build-Deps installed")
     print("INFO: Trying to install them now:")
     print(my_builddeps)
-    subprocess.run(['sudo', '/usr/bin/apt', 'update'] + my_builddeps)
+    subprocess.run(['sudo', '/usr/bin/apt', 'update'])
     subprocess.run(['sudo', '/usr/bin/apt', 'install', '-y'] + my_builddeps)
 
     # Download debs of old version
-- 
GitLab