extra/meson to 1.2.2-2

This commit is contained in:
Kevin Mihelich 2023-10-04 23:29:35 +00:00
parent e4cb4393ef
commit 013fcf6334
4 changed files with 151 additions and 5 deletions

View file

@ -1,7 +1,7 @@
pkgbase = meson pkgbase = meson
pkgdesc = High productivity build system pkgdesc = High productivity build system
pkgver = 1.2.2 pkgver = 1.2.2
pkgrel = 1 pkgrel = 2
url = https://mesonbuild.com/ url = https://mesonbuild.com/
arch = any arch = any
license = Apache license = Apache
@ -64,6 +64,7 @@ pkgbase = meson
source = native-clang source = native-clang
source = 0001-Skip-broken-tests.patch source = 0001-Skip-broken-tests.patch
source = 0002-Use-C-17-for-protobuf-tests.patch source = 0002-Use-C-17-for-protobuf-tests.patch
source = 0003-Revert-rust-apply-global-project-and-environment-C-a.patch
validpgpkeys = 19E2D6D9B46D8DAA6288F877C24E631BABB1FE70 validpgpkeys = 19E2D6D9B46D8DAA6288F877C24E631BABB1FE70
b2sums = b355c8e5ab7508fca51dbe5c95eea68f91b995a670ad20eb9b7e93d3c97ad5363afe3fbd39cd554d1a6953a07166851257d16706acc9db6d5265e6452e40a857 b2sums = b355c8e5ab7508fca51dbe5c95eea68f91b995a670ad20eb9b7e93d3c97ad5363afe3fbd39cd554d1a6953a07166851257d16706acc9db6d5265e6452e40a857
b2sums = SKIP b2sums = SKIP
@ -73,6 +74,7 @@ pkgbase = meson
b2sums = e56c75dd9122d866e8a92381f1f8a3fa268451d13a18b73906c0089601d3e6edf28602b36f40d8a32758e9958a167a1bdccd70283581e19b2ed39863640daf95 b2sums = e56c75dd9122d866e8a92381f1f8a3fa268451d13a18b73906c0089601d3e6edf28602b36f40d8a32758e9958a167a1bdccd70283581e19b2ed39863640daf95
b2sums = 7d88929d5a3b49d91c5c9969f19d9b47f3151706526b889515acaeda0141257d5115875ac84832e9ea46f83a7700d673adcc5db84b331cd798c70ae6e90eac1e b2sums = 7d88929d5a3b49d91c5c9969f19d9b47f3151706526b889515acaeda0141257d5115875ac84832e9ea46f83a7700d673adcc5db84b331cd798c70ae6e90eac1e
b2sums = c2a1c6ea016fca855b949dba286e966404a2ce44dfc4e55542b201719ab7654c0176a97e1d5b906043ca4cd741dfd2fe3554a520116c26ceb4ba313f78548380 b2sums = c2a1c6ea016fca855b949dba286e966404a2ce44dfc4e55542b201719ab7654c0176a97e1d5b906043ca4cd741dfd2fe3554a520116c26ceb4ba313f78548380
b2sums = 338df79aa545c2eaa10e9c14ca93b59456572a0c31721e50f202daab8fbbe9595f6cd8575b6e11b333398ebb9dd9eef1f45beb9c7e24ed475e9fa6782e1d98f4 b2sums = c0154434fefb00aebb66b276c3b871b9ec629adc8f3c5b020a21b4662667c0bdaa2c48c6a7498d0c7ab901bb9c3911bd0bb82fbae5e5f3ae2da006e3849e0ff0
b2sums = 623539918a5a265e521c2bff50e66a4c9d59a684131d32a8f568aa167db6feeaa21627f362bf3bd0995a46960405e9802ddacff251a8a6b85ba3da3eadeb200f
pkgname = meson pkgname = meson

View file

@ -3,7 +3,7 @@ From: "Jan Alexander Steffens (heftig)" <heftig@archlinux.org>
Date: Wed, 12 Jul 2023 00:10:11 +0200 Date: Wed, 12 Jul 2023 00:10:11 +0200
Subject: [PATCH] Use C++17 for protobuf tests Subject: [PATCH] Use C++17 for protobuf tests
Recent protobuf no longer supports C++11. Our protobuf (and abseil-cpp) can currently only be used with C++17.
--- ---
test cases/frameworks/5 protocol buffers/meson.build | 2 +- test cases/frameworks/5 protocol buffers/meson.build | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-) 1 file changed, 1 insertion(+), 1 deletion(-)

View file

@ -0,0 +1,136 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: "Jan Alexander Steffens (heftig)" <heftig@archlinux.org>
Date: Wed, 4 Oct 2023 21:57:36 +0200
Subject: [PATCH] Revert "rust: apply global, project, and environment C args
to bindgen"
Applying CFLAGS from the project (which were tested against GCC) to
bindgen (which uses Clang) breaks Mesa's build, see
https://github.com/mesonbuild/meson/issues/12326.
This reverts commit 36210f64f22dc10d324db76bb1a7988c9cd5b14e.
---
mesonbuild/modules/rust.py | 6 ------
test cases/rust/12 bindgen/meson.build | 18 ------------------
.../rust/12 bindgen/src/global-project.h | 10 ----------
test cases/rust/12 bindgen/src/global.c | 5 -----
test cases/rust/12 bindgen/src/global.rs | 14 --------------
test cases/rust/12 bindgen/test.json | 5 +----
6 files changed, 1 insertion(+), 57 deletions(-)
delete mode 100644 test cases/rust/12 bindgen/src/global-project.h
delete mode 100644 test cases/rust/12 bindgen/src/global.c
delete mode 100644 test cases/rust/12 bindgen/src/global.rs
diff --git a/mesonbuild/modules/rust.py b/mesonbuild/modules/rust.py
index e6e5c633ff11..3514412e65df 100644
--- a/mesonbuild/modules/rust.py
+++ b/mesonbuild/modules/rust.py
@@ -232,12 +232,6 @@ class RustModule(ExtensionModule):
elif isinstance(s, CustomTarget):
depends.append(s)
- clang_args.extend(state.global_args.get('c', []))
- clang_args.extend(state.project_args.get('c', []))
- cargs = state.get_option('args', state.subproject, lang='c')
- assert isinstance(cargs, list), 'for mypy'
- clang_args.extend(cargs)
-
if self._bindgen_bin is None:
self._bindgen_bin = state.find_program('bindgen')
diff --git a/test cases/rust/12 bindgen/meson.build b/test cases/rust/12 bindgen/meson.build
index e7cb5f3db2c0..c05cc063136c 100644
--- a/test cases/rust/12 bindgen/meson.build
+++ b/test cases/rust/12 bindgen/meson.build
@@ -8,9 +8,6 @@ if not prog_bindgen.found()
error('MESON_SKIP_TEST bindgen not found')
endif
-add_project_arguments('-DPROJECT_ARG', language : 'c')
-add_global_arguments('-DGLOBAL_ARG', language : 'c')
-
# This seems to happen on windows when libclang.dll is not in path or is not
# valid. We must try to process a header file for this to work.
#
@@ -84,18 +81,3 @@ test('generated header', rust_bin2)
subdir('sub')
subdir('dependencies')
-
-gp = rust.bindgen(
- input : 'src/global-project.h',
- output : 'global-project.rs',
-)
-
-gp_lib = static_library('gp_lib', 'src/global.c')
-
-gp_exe = executable(
- 'gp_exe',
- structured_sources(['src/global.rs', gp]),
- link_with : gp_lib,
-)
-
-test('global and project arguments', gp_exe)
diff --git a/test cases/rust/12 bindgen/src/global-project.h b/test cases/rust/12 bindgen/src/global-project.h
deleted file mode 100644
index 6084e8ed6b0b..000000000000
--- a/test cases/rust/12 bindgen/src/global-project.h
+++ /dev/null
@@ -1,10 +0,0 @@
-#ifndef GLOBAL_ARG
-char * success(void);
-#endif
-#ifndef PROJECT_ARG
-char * success(void);
-#endif
-#ifndef CMD_ARG
-char * success(void);
-#endif
-int success(void);
diff --git a/test cases/rust/12 bindgen/src/global.c b/test cases/rust/12 bindgen/src/global.c
deleted file mode 100644
index 10f6676f7a1b..000000000000
--- a/test cases/rust/12 bindgen/src/global.c
+++ /dev/null
@@ -1,5 +0,0 @@
-#include "src/global-project.h"
-
-int success(void) {
- return 0;
-}
diff --git a/test cases/rust/12 bindgen/src/global.rs b/test cases/rust/12 bindgen/src/global.rs
deleted file mode 100644
index 4b70b1ecc728..000000000000
--- a/test cases/rust/12 bindgen/src/global.rs
+++ /dev/null
@@ -1,14 +0,0 @@
-// SPDX-license-identifer: Apache-2.0
-// Copyright © 2023 Intel Corporation
-
-#![allow(non_upper_case_globals)]
-#![allow(non_camel_case_types)]
-#![allow(non_snake_case)]
-
-include!("global-project.rs");
-
-fn main() {
- unsafe {
- std::process::exit(success());
- };
-}
diff --git a/test cases/rust/12 bindgen/test.json b/test cases/rust/12 bindgen/test.json
index b3a758562969..f94ee85f9740 100644
--- a/test cases/rust/12 bindgen/test.json
+++ b/test cases/rust/12 bindgen/test.json
@@ -1,10 +1,7 @@
{
- "env": {
- "CFLAGS": "-DCMD_ARG"
- },
"stdout": [
{
- "line": "test cases/rust/12 bindgen/meson.build:30: WARNING: Project targets '>= 0.63' but uses feature introduced in '1.0.0': \"rust.bindgen\" keyword argument \"include_directories\" of type array[str]."
+ "line": "test cases/rust/12 bindgen/meson.build:27: WARNING: Project targets '>= 0.63' but uses feature introduced in '1.0.0': \"rust.bindgen\" keyword argument \"include_directories\" of type array[str]."
}
]
}

View file

@ -7,7 +7,7 @@
pkgname=meson pkgname=meson
pkgver=1.2.2 pkgver=1.2.2
pkgrel=1 pkgrel=2
pkgdesc="High productivity build system" pkgdesc="High productivity build system"
url="https://mesonbuild.com/" url="https://mesonbuild.com/"
arch=(any) arch=(any)
@ -77,6 +77,7 @@ source=(
native-clang native-clang
0001-Skip-broken-tests.patch 0001-Skip-broken-tests.patch
0002-Use-C-17-for-protobuf-tests.patch 0002-Use-C-17-for-protobuf-tests.patch
0003-Revert-rust-apply-global-project-and-environment-C-a.patch
) )
b2sums=('b355c8e5ab7508fca51dbe5c95eea68f91b995a670ad20eb9b7e93d3c97ad5363afe3fbd39cd554d1a6953a07166851257d16706acc9db6d5265e6452e40a857' b2sums=('b355c8e5ab7508fca51dbe5c95eea68f91b995a670ad20eb9b7e93d3c97ad5363afe3fbd39cd554d1a6953a07166851257d16706acc9db6d5265e6452e40a857'
'SKIP' 'SKIP'
@ -86,15 +87,22 @@ b2sums=('b355c8e5ab7508fca51dbe5c95eea68f91b995a670ad20eb9b7e93d3c97ad5363afe3fb
'e56c75dd9122d866e8a92381f1f8a3fa268451d13a18b73906c0089601d3e6edf28602b36f40d8a32758e9958a167a1bdccd70283581e19b2ed39863640daf95' 'e56c75dd9122d866e8a92381f1f8a3fa268451d13a18b73906c0089601d3e6edf28602b36f40d8a32758e9958a167a1bdccd70283581e19b2ed39863640daf95'
'7d88929d5a3b49d91c5c9969f19d9b47f3151706526b889515acaeda0141257d5115875ac84832e9ea46f83a7700d673adcc5db84b331cd798c70ae6e90eac1e' '7d88929d5a3b49d91c5c9969f19d9b47f3151706526b889515acaeda0141257d5115875ac84832e9ea46f83a7700d673adcc5db84b331cd798c70ae6e90eac1e'
'c2a1c6ea016fca855b949dba286e966404a2ce44dfc4e55542b201719ab7654c0176a97e1d5b906043ca4cd741dfd2fe3554a520116c26ceb4ba313f78548380' 'c2a1c6ea016fca855b949dba286e966404a2ce44dfc4e55542b201719ab7654c0176a97e1d5b906043ca4cd741dfd2fe3554a520116c26ceb4ba313f78548380'
'338df79aa545c2eaa10e9c14ca93b59456572a0c31721e50f202daab8fbbe9595f6cd8575b6e11b333398ebb9dd9eef1f45beb9c7e24ed475e9fa6782e1d98f4') 'c0154434fefb00aebb66b276c3b871b9ec629adc8f3c5b020a21b4662667c0bdaa2c48c6a7498d0c7ab901bb9c3911bd0bb82fbae5e5f3ae2da006e3849e0ff0'
'623539918a5a265e521c2bff50e66a4c9d59a684131d32a8f568aa167db6feeaa21627f362bf3bd0995a46960405e9802ddacff251a8a6b85ba3da3eadeb200f')
validpgpkeys=( validpgpkeys=(
19E2D6D9B46D8DAA6288F877C24E631BABB1FE70 # Jussi Pakkanen <jpakkane@gmail.com> 19E2D6D9B46D8DAA6288F877C24E631BABB1FE70 # Jussi Pakkanen <jpakkane@gmail.com>
) )
prepare() { prepare() {
cd $pkgname-$pkgver cd $pkgname-$pkgver
# Pass tests
patch -Np1 -i ../0001-Skip-broken-tests.patch patch -Np1 -i ../0001-Skip-broken-tests.patch
patch -Np1 -i ../0002-Use-C-17-for-protobuf-tests.patch patch -Np1 -i ../0002-Use-C-17-for-protobuf-tests.patch
# Unbreak Mesa build
# https://github.com/mesonbuild/meson/issues/12326
patch -Np1 -i ../0003-Revert-rust-apply-global-project-and-environment-C-a.patch
} }
build() { build() {