]> granicus.if.org Git - graphviz/commitdiff
archive all shared libraries in Ubuntu 21.04 build for ctest
authorMagnus Jacobsson <Magnus.Jacobsson@berotec.se>
Mon, 5 Jul 2021 08:03:17 +0000 (10:03 +0200)
committerMagnus Jacobsson <Magnus.Jacobsson@berotec.se>
Wed, 7 Jul 2021 04:53:27 +0000 (06:53 +0200)
The Ubuntu 21.04 build is renamed and modified to be able to run
ctest, which uses the build products directly from where they reside
before installing them.

Adds archiving of all shared libraries produced directly by "cmake
--build". In the test stage, the test executables load them from those
directory locations since LD_LIBRARY_PATH is automatically set up to
contain them.

.gitlab-ci.yml

index 63e265fcac700f362f02a1b6143df6a3b819c5f3..3ef34db910b885f4497e5165aefe9154a9d9b822 100644 (file)
@@ -452,7 +452,7 @@ ubuntu21-04-cmake-build:
     variables:
       IMAGE: ubuntu-21.04
 
-ubuntu21-04-cmake-ASan-build:
+ubuntu21-04-cmake-ASan-build-for-ctest:
     <<: *deb_build_definition
     needs:
         - job: docker_build_ubuntu-21.04
@@ -466,6 +466,26 @@ ubuntu21-04-cmake-ASan-build:
         - export CXXFLAGS=-Werror
         - export CMAKE_OPTIONS="-Duse_sanitizers=ON"
         - echo experimental > COLLECTION
+    # override the deb_build_definition artifacts since we need more
+    # files from the build directory when running ctest in the test
+    # stage.
+    artifacts:
+        when: on_success
+        expire_in: 1 week
+        paths:
+            # archive all shared libraries produced directly by "cmake
+            # --build" (but not those in the install directory that
+            # cpack has copied). In the test stage, the test
+            # executables load them from those directory locations
+            # since LD_LIBRARY_PATH is automatically set up to contain
+            # them.
+            - build/lib/**/lib*.so.*
+            - build/plugin/**/lib*.so.*
+            # the packages need to be installed for the post-install tests
+            - Packages/*/*/*/*/*/*deb
+            - Metadata/*/*/*/configure.log
+        reports:
+            metrics: metrics.txt
     tags:
         - linux
     variables:
@@ -792,7 +812,7 @@ ubuntu21.04-cmake-ASan-test:
     needs:
         - job: portable-source
           artifacts: true
-        - job: "ubuntu21-04-cmake-ASan-build"
+        - job: "ubuntu21-04-cmake-ASan-build-for-ctest"
           artifacts: true
     tags:
         - linux