Jan Alexander Steffens (heftig) pushed to branch main at Arch Linux / Packaging 
/ Packages / meson


Commits:
984f8386 by Jan Alexander Steffens (heftig) at 2025-01-04T05:34:19+01:00
Simplify test fix

- - - - -


3 changed files:

- .SRCINFO
- 0002-tests-Avoid-modifying-test-dirs-in-allplatformtests.patch → 
0002-tests-Avoid-modifying-17-prebuild-shared-test-dir.patch
- PKGBUILD


Changes:

=====================================
.SRCINFO
=====================================
@@ -67,7 +67,7 @@ pkgbase = meson
        source = cross-lib32
        source = native-clang
        source = 0001-Skip-broken-tests.patch
-       source = 0002-tests-Avoid-modifying-test-dirs-in-allplatformtests.patch
+       source = 0002-tests-Avoid-modifying-17-prebuild-shared-test-dir.patch
        validpgpkeys = 19E2D6D9B46D8DAA6288F877C24E631BABB1FE70
        b2sums = 
7ccdb3bf3f701fc787fabf91413db8301a8658b89e08c1d712711bd35845dc2468211e4b666cf46ad68ad9462e62b12b62d60c3767a2804f9b695b4390bb8235
        b2sums = SKIP
@@ -77,6 +77,6 @@ pkgbase = meson
        b2sums = 
9b16477aa77a706492e26fb3ad42e90674b8f0dfe657dd3bd9ba044f921be12ceabeb0050a50a15caee4d999e1ec33ed857bd3bed9e4444d73bb4a4f06381081
        b2sums = 
7d88929d5a3b49d91c5c9969f19d9b47f3151706526b889515acaeda0141257d5115875ac84832e9ea46f83a7700d673adcc5db84b331cd798c70ae6e90eac1e
        b2sums = 
41b5d1fea3ef014b9c52f292bf35bf87f589909a4de316ca324fb717f997a36cfc7bcd82c6f18039ea066131cd630381d275984fb9f3462d468a93d1ca437b2d
-       b2sums = 
9202300b5ddac7017fdc1865a4e4298f606d39e39ccb379284de998decc621491761804bb88f7e1b2cd8893e5f8f7300f3b37f305ef3cbad40ee4693418e8167
+       b2sums = 
9f62ffc6038739eeb3f1b76463e6b37363d1439dcf7a5878764fcb52ce54d16bb2f1ab9c590ba348196d7c5455aa5912240124df448ca4724de9896edc56c33a
 
 pkgname = meson


=====================================
0002-tests-Avoid-modifying-test-dirs-in-allplatformtests.patch → 
0002-tests-Avoid-modifying-17-prebuild-shared-test-dir.patch
=====================================
@@ -1,12 +1,12 @@
 From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
 From: "Jan Alexander Steffens (heftig)" <hef...@archlinux.org>
 Date: Mon, 9 Dec 2024 16:18:50 +0100
-Subject: [PATCH] tests: Avoid modifying test dirs in allplatformtests
+Subject: [PATCH] tests: Avoid modifying '17 prebuild shared' test dir
 
 Tests can tread on each other's toes when parallelism is high enough.
 
-For a concrete case, `test_prebuilt_shared_lib` creates an object file
-in the `17 prebuilt shared` test dir.
+In this case, `test_prebuilt_shared_lib` creates an object file in the
+`17 prebuilt shared` test dir.
 
 `test_prebuilt_shared_lib_rpath_same_prefix` uses `shutil.copytree` to
 copy that same test dir to a temporary location.
@@ -14,25 +14,15 @@ copy that same test dir to a temporary location.
 If the former test cleans up its object file while `copytree` is
 running, the copy can fail with a fatal ENOENT `shutil.Error`.
 
-Use `copy_srcdir` in all tests that modify the testdir (that I spotted)
-to prevent this from happening.
+Use `copy_srcdir` to prevent this from happening.
 ---
- unittests/allplatformstests.py | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
+ unittests/allplatformstests.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/unittests/allplatformstests.py b/unittests/allplatformstests.py
-index cadbc40e9680..69bdb12d3f4a 100644
+index cadbc40e9680..4279039582d9 100644
 --- a/unittests/allplatformstests.py
 +++ b/unittests/allplatformstests.py
-@@ -1732,7 +1732,7 @@ class AllPlatformTests(BasePlatformTests):
- 
-     def test_prebuilt_static_lib(self):
-         (cc, stlinker, object_suffix, _) = self.detect_prebuild_env()
--        tdir = os.path.join(self.unit_test_dir, '16 prebuilt static')
-+        tdir = self.copy_srcdir(os.path.join(self.unit_test_dir, '16 prebuilt 
static'))
-         source = os.path.join(tdir, 'libdir/best.c')
-         objectfile = os.path.join(tdir, 'libdir/best.' + object_suffix)
-         stlibfile = os.path.join(tdir, 'libdir/libbest.a')
 @@ -1766,7 +1766,7 @@ class AllPlatformTests(BasePlatformTests):
  
      def test_prebuilt_shared_lib(self):
@@ -42,12 +32,3 @@ index cadbc40e9680..69bdb12d3f4a 100644
          source = os.path.join(tdir, 'alexandria.c')
          objectfile = os.path.join(tdir, 'alexandria.' + object_suffix)
          impfile = os.path.join(tdir, 'alexandria.lib')
-@@ -1981,7 +1981,7 @@ class AllPlatformTests(BasePlatformTests):
-         https://github.com/mesonbuild/meson/issues/2785
-         '''
-         (cc, stlinker, objext, shext) = self.detect_prebuild_env()
--        testdir = os.path.join(self.unit_test_dir, '18 pkgconfig static')
-+        testdir = self.copy_srcdir(os.path.join(self.unit_test_dir, '18 
pkgconfig static'))
-         source = os.path.join(testdir, 'foo.c')
-         objectfile = os.path.join(testdir, 'foo.' + objext)
-         stlibfile = os.path.join(testdir, 'libfoo.a')


=====================================
PKGBUILD
=====================================
@@ -77,7 +77,7 @@ source=(
   cross-lib32
   native-clang
   0001-Skip-broken-tests.patch
-  0002-tests-Avoid-modifying-test-dirs-in-allplatformtests.patch
+  0002-tests-Avoid-modifying-17-prebuild-shared-test-dir.patch
 )
 
b2sums=('7ccdb3bf3f701fc787fabf91413db8301a8658b89e08c1d712711bd35845dc2468211e4b666cf46ad68ad9462e62b12b62d60c3767a2804f9b695b4390bb8235'
         'SKIP'
@@ -87,7 +87,7 @@ 
b2sums=('7ccdb3bf3f701fc787fabf91413db8301a8658b89e08c1d712711bd35845dc2468211e4
         
'9b16477aa77a706492e26fb3ad42e90674b8f0dfe657dd3bd9ba044f921be12ceabeb0050a50a15caee4d999e1ec33ed857bd3bed9e4444d73bb4a4f06381081'
         
'7d88929d5a3b49d91c5c9969f19d9b47f3151706526b889515acaeda0141257d5115875ac84832e9ea46f83a7700d673adcc5db84b331cd798c70ae6e90eac1e'
         
'41b5d1fea3ef014b9c52f292bf35bf87f589909a4de316ca324fb717f997a36cfc7bcd82c6f18039ea066131cd630381d275984fb9f3462d468a93d1ca437b2d'
-        
'9202300b5ddac7017fdc1865a4e4298f606d39e39ccb379284de998decc621491761804bb88f7e1b2cd8893e5f8f7300f3b37f305ef3cbad40ee4693418e8167')
+        
'9f62ffc6038739eeb3f1b76463e6b37363d1439dcf7a5878764fcb52ce54d16bb2f1ab9c590ba348196d7c5455aa5912240124df448ca4724de9896edc56c33a')
 validpgpkeys=(
   19E2D6D9B46D8DAA6288F877C24E631BABB1FE70  # Jussi Pakkanen 
<jpakk...@gmail.com>
 )
@@ -97,7 +97,9 @@ prepare() {
 
   # Pass tests
   patch -Np1 -i ../0001-Skip-broken-tests.patch
-  patch -Np1 -i 
../0002-tests-Avoid-modifying-test-dirs-in-allplatformtests.patch
+
+  # https://github.com/mesonbuild/meson/pull/13991
+  patch -Np1 -i ../0002-tests-Avoid-modifying-17-prebuild-shared-test-dir.patch
 }
 
 build() {



View it on GitLab: 
https://gitlab.archlinux.org/archlinux/packaging/packages/meson/-/commit/984f83868286d80f7bf50ec1921a51bcdb3e26ff

-- 
View it on GitLab: 
https://gitlab.archlinux.org/archlinux/packaging/packages/meson/-/commit/984f83868286d80f7bf50ec1921a51bcdb3e26ff
You're receiving this email because of your account on gitlab.archlinux.org.


Reply via email to