From: Kornel Benko Date: Sat, 1 Aug 2020 07:35:20 +0000 (+0200) Subject: Cmake export tests: Make the destination directory for test results unique X-Git-Tag: lyx-2.4.0dev-acb2ca7b~502 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=b62c6e896127f0c90d4558a90346943eeaf30d1a;hp=4ce9e784b4b766f464712d51c6e99940dbe19768;p=features.git Cmake export tests: Make the destination directory for test results unique Exporting files with identical names (but in different directories) could lead to conflicts in parallel executed tests. --- diff --git a/development/autotests/export.cmake b/development/autotests/export.cmake index a9f2a01540..45a2635152 100755 --- a/development/autotests/export.cmake +++ b/development/autotests/export.cmake @@ -48,6 +48,15 @@ if(ENCODING STREQUAL "default") else() set(_enc "_${ENCODING}") endif() + +# move the the last directory part of LYX_ROOT to filename +# to make the destination unique for otherwise identical +# filenames +get_filename_component(updir_ "${LYX_ROOT}" DIRECTORY) +get_filename_component(updir2_ "${LYX_ROOT}" NAME) +set(file "${updir2_}/${file}") +set(LYX_ROOT "${updir_}") + if(format MATCHES "dvi|pdf") message(STATUS "LYX_TESTS_USERDIR = ${LYX_TESTS_USERDIR}") message(STATUS "Converting with perl ${Perl_Script}")