solenv/gbuild/CppunitTest.mk | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-)
New commits: commit bd3dc6fc18a6360929e3427abccc572950d0aa8e Author: Stephan Bergmann <stephan.bergm...@allotropia.de> AuthorDate: Mon Feb 26 20:58:08 2024 +0100 Commit: Stephan Bergmann <stephan.bergm...@allotropia.de> CommitDate: Mon Feb 26 22:25:27 2024 +0100 Fix --enable-coredumpctl in CppunitTest ...which 533e993f2d11814252c40d60bdab469de03b14db "Don't reuse --unit values across (sequential, even) systemd-run invocations" had broken by moving the setting of the LIBO_TEST_UNIT var to a place where the use of that env var would no longer see it. Fix it by making the individual LO_TEST_LOCALE=* tests of gb_CppunitTest_localized more autonomous. Each one now has an individual log file and gets an individual gb_CppunitTest_postprocess treatment. Change-Id: Ie6875dda874e357426370d4d5166c05e36881210 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163967 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <stephan.bergm...@allotropia.de> diff --git a/solenv/gbuild/CppunitTest.mk b/solenv/gbuild/CppunitTest.mk index fc7351986b09..287ec84eb6c5 100644 --- a/solenv/gbuild/CppunitTest.mk +++ b/solenv/gbuild/CppunitTest.mk @@ -135,10 +135,10 @@ else $(if $(gb_CppunitTest__interactive),, \ $(if $(value gb_CppunitTest_postprocess), \ rm -fr $@.core && mkdir $@.core && cd $@.core &&)) \ - ( \ - $(if $(gb_CppunitTest_localized),for l in $(WITH_LANG_LIST) ; do \ - printf 'LO_TEST_LOCALE=%s ' "$$l" && ) \ + $(if $(gb_CppunitTest_localized),for l in $(WITH_LANG_LIST) ; do) \ $(call gb_CppunitTest_coredumpctl_setup,$@,$(if $(gb_CppunitTest_localized),$$l)) \ + ( \ + $(if $(gb_CppunitTest_localized),printf 'LO_TEST_LOCALE=%s ' "$$l" && ) \ $(if $(gb_CppunitTest_localized),LO_TEST_LOCALE="$$l") \ $(if $(gb_CppunitTest__vcl_no_svp), \ $(filter-out SAL_USE_VCLPLUGIN=svp,$(gb_TEST_ENV_VARS)),$(gb_TEST_ENV_VARS)) \ @@ -157,14 +157,15 @@ else $(gb_CppunitTest_CPPTESTCOMMAND) \ $(call gb_CppunitTest_get_linktarget_target,$*) \ $(call gb_CppunitTest__make_args) "-env:CPPUNITTESTTARGET=$@" \ - $(if $(gb_CppunitTest_localized),|| exit $$?; done) \ ) \ - $(if $(gb_CppunitTest__interactive),, \ - > $@.log 2>&1 \ - || ($(if $(value gb_CppunitTest_postprocess), \ + $(if $(gb_CppunitTest__interactive),$(if $(gb_CppunitTest_localized),|| exit $$?), \ + > $@.$(if $(gb_CppunitTest_localized),$$l.)log 2>&1 \ + || { $(if $(value gb_CppunitTest_postprocess), \ RET=$$?; \ - $(call gb_CppunitTest_postprocess,$(gb_CppunitTest_CPPTESTCOMMAND),$@.core,$$RET) >> $@.log 2>&1;) \ - cat $@.log; $(gb_CppunitTest_UNITTESTFAILED) Cppunit $*))) + $(call gb_CppunitTest_postprocess,$(gb_CppunitTest_CPPTESTCOMMAND),$@.core,$$RET) >> $@.$(if $(gb_CppunitTest_localized),$$l.)log 2>&1;) \ + cat $@.$(if $(gb_CppunitTest_localized),$$l.)log; $(gb_CppunitTest_UNITTESTFAILED) Cppunit $*; \ + $(if $(gb_CppunitTest_localized),exit $$RET;) } ) \ + $(if $(gb_CppunitTest_localized),; done)) $(call gb_Trace_EndRange,$*,CUT) endif