[Libreoffice-commits] core.git: bin/update_pch bin/update_pch.sh
LuboÅ¡ LuÅák (via logerrit)
logerrit at kemper.freedesktop.org
Thu Apr 8 15:22:45 UTC 2021
bin/update_pch | 3 ++-
bin/update_pch.sh | 5 +++++
2 files changed, 7 insertions(+), 1 deletion(-)
New commits:
commit 9cd313228477f0b471f759e3e71810ddae8654e4
Author: Luboš Luňák <l.lunak at collabora.com>
AuthorDate: Thu Apr 8 13:14:53 2021 +0200
Commit: Luboš Luňák <l.lunak at collabora.com>
CommitDate: Thu Apr 8 17:21:55 2021 +0200
make update_pch.sh abort on an error
The script depends also on generated sources in workdir, which
it may fail to find if they haven't been built before running
the script. Prefer to fail on errors rather than ignoring them.
Note that when using builddir != srcdir, the script requires
$WORKDIR to be set (done e.g. by the recommended
'make cmd cmd="./bin/update_pch.sh [..]"').
Change-Id: I93429c133bd0876730a850d944707880848201f0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113798
Tested-by: Jenkins
Reviewed-by: Luboš Luňák <l.lunak at collabora.com>
diff --git a/bin/update_pch b/bin/update_pch
index 6641f1584055..9b541d8a87a9 100755
--- a/bin/update_pch
+++ b/bin/update_pch
@@ -1107,7 +1107,8 @@ def main():
return 0
# Didn't update.
- return 1
+ # Use exit code 2 to distinguish it from exit code 1 used e.g. when an exception occurs.
+ return 2
if __name__ == '__main__':
""" Process all the includes in a Module
diff --git a/bin/update_pch.sh b/bin/update_pch.sh
index 78b4a47e6044..4c17a0374757 100755
--- a/bin/update_pch.sh
+++ b/bin/update_pch.sh
@@ -58,6 +58,11 @@ for x in $headers; do
libname=`echo $header | sed -e s/.*precompiled_// -e s/\.hxx//`
./bin/update_pch "$module" "$libname"
+ exitcode=$?
+ if test $exitcode -ne 0 -a $exitcode -ne 2; then
+ echo Failed.
+ exit 1
+ fi
fi
done
More information about the Libreoffice-commits
mailing list