Skip to content

Commit 5f71595

Browse files
committed
Merge remote-tracking branch 'upstream/master' into HEAD
2 parents 31161ee + 7ec1fc5 commit 5f71595

File tree

131 files changed

+2872
-1676
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

131 files changed

+2872
-1676
lines changed

.pylintrc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ disable=
1717
cell-var-from-loop,
1818
consider-using-f-string,
1919
consider-using-with,
20+
contextmanager-generator-missing-cleanup,
2021
cyclic-import,
2122
deprecated-decorator,
2223
duplicate-code,
@@ -47,6 +48,7 @@ disable=
4748
not-an-iterable,
4849
not-callable,
4950
pointless-string-statement,
51+
possibly-used-before-assignment,
5052
protected-access,
5153
raise-missing-from,
5254
redeclared-assigned-name,
@@ -75,6 +77,7 @@ disable=
7577
unsubscriptable-object,
7678
unused-argument,
7779
unused-variable,
80+
used-before-assignment,
7881
useless-super-delegation,
7982
wrong-import-order,
8083
wrong-import-position,

azure-pipelines.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ trigger:
2626
- 'test cases'
2727
- 'unittests'
2828
- 'azure-pipelines.yml'
29-
- 'ci/azure-steps.yml'
29+
- 'ci/run.ps1'
3030
- 'run_project_tests.py'
3131
- 'run_tests.py'
3232
- 'run_unittests.py'
@@ -41,7 +41,7 @@ pr:
4141
- 'test cases'
4242
- 'unittests'
4343
- 'azure-pipelines.yml'
44-
- 'ci/azure-steps.yml'
44+
- 'ci/run.ps1'
4545
- 'run_project_tests.py'
4646
- 'run_tests.py'
4747
- 'run_unittests.py'

ci/ciimage/build.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -80,11 +80,6 @@ def gen_bashrc(self) -> None:
8080
fi
8181
'''
8282

83-
if self.data_dir.name == 'gentoo':
84-
out_data += '''
85-
source /etc/profile
86-
'''
87-
8883
out_file.write_text(out_data, encoding='utf-8')
8984

9085
# make it executable

ci/ciimage/cuda/install.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@ install_minimal_python_packages
1818
# Manually remove cache to avoid GitHub space restrictions
1919
rm -rf /var/cache/pacman
2020

21-
echo "source /etc/profile.d/cuda.sh" >> /ci/env_vars.sh
21+
echo "source /etc/profile" >> /ci/env_vars.sh

ci/ciimage/gentoo/install.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,3 +156,5 @@ rm /usr/lib/python/EXTERNALLY-MANAGED
156156
python3 -m ensurepip
157157
install_python_packages
158158
python3 -m pip install "${base_python_pkgs[@]}"
159+
160+
echo "source /etc/profile" >> /ci/env_vars.sh

ci/run.ps1

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,21 +8,22 @@ if ($LastExitCode -ne 0) {
88
$env:Path = ($env:Path.Split(';') | Where-Object { $_ -notmatch 'mingw|Strawberry|Chocolatey|PostgreSQL' }) -join ';'
99

1010
if ($env:arch -eq 'x64') {
11+
rustup default 1.77
1112
# Rust puts its shared stdlib in a secret place, but it is needed to run tests.
12-
$env:Path += ";$HOME/.rustup/toolchains/stable-x86_64-pc-windows-msvc/bin"
13+
$env:Path += ";$HOME/.rustup/toolchains/1.77-x86_64-pc-windows-msvc/bin"
1314
} elseif ($env:arch -eq 'x86') {
1415
# Switch to the x86 Rust toolchain
15-
rustup default stable-i686-pc-windows-msvc
16-
17-
# Also install clippy
18-
rustup component add clippy
16+
rustup default 1.77-i686-pc-windows-msvc
1917

2018
# Rust puts its shared stdlib in a secret place, but it is needed to run tests.
21-
$env:Path += ";$HOME/.rustup/toolchains/stable-i686-pc-windows-msvc/bin"
19+
$env:Path += ";$HOME/.rustup/toolchains/1.77-i686-pc-windows-msvc/bin"
2220
# Need 32-bit Python for tests that need the Python dependency
2321
$env:Path = "C:\hostedtoolcache\windows\Python\3.7.9\x86;C:\hostedtoolcache\windows\Python\3.7.9\x86\Scripts;$env:Path"
2422
}
2523

24+
# Also install clippy
25+
rustup component add clippy
26+
2627
# Set the CI env var for the meson test framework
2728
$env:CI = '1'
2829

data/shell-completions/bash/meson

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -580,6 +580,7 @@ _meson-test() {
580580
quiet
581581
timeout-multiplier
582582
setup
583+
max-lines
583584
test-args
584585
)
585586

data/shell-completions/zsh/_meson

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -196,6 +196,7 @@ local -a meson_commands=(
196196
'(--quiet -q)'{'--quiet','-q'}'[produce less output to the terminal]'
197197
'(--timeout-multiplier -t)'{'--timeout-multiplier','-t'}'[a multiplier for test timeouts]:Python floating-point number: '
198198
'--setup[which test setup to use]:test setup: '
199+
'--max-lines[Maximum number of lines to show from a long test log]:Python integer number: '
199200
'--test-args[arguments to pass to the tests]: : '
200201
'*:Meson tests:__meson_test_names'
201202
)

docs/markdown/Builtin-options.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -408,7 +408,8 @@ interpreter directly, even if it is a venv. Setting to `venv` will instead use
408408
the paths for the virtualenv the python found installation comes from (or fail
409409
if it is not a virtualenv). Setting to `auto` will check if the found
410410
installation is a virtualenv, and use `venv` or `system` as appropriate (but
411-
never `prefix`). This option is mutually exclusive with the `platlibdir`/`purelibdir`.
411+
never `prefix`). Note that Conda environments are treated as `system`.
412+
This option is mutually exclusive with the `platlibdir`/`purelibdir`.
412413

413414
For backwards compatibility purposes, the default `install_env` is `prefix`.
414415

docs/markdown/FAQ.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -695,3 +695,16 @@ directory. It glob ignores ```"*"```, since all generated files should not be
695695
checked into git.
696696

697697
Users of older versions of Meson may need to set up ignore files themselves.
698+
699+
## How to add preprocessor defines to a target?
700+
701+
Just add `-DFOO` to `c_args` or `cpp_args`. This works for all known compilers.
702+
703+
```meson
704+
mylib = library('mylib', 'mysource.c', c_args: ['-DFOO'])
705+
```
706+
707+
Even though [MSVC documentation](https://learn.microsoft.com/en-us/cpp/build/reference/d-preprocessor-definitions)
708+
uses `/D` for preprocessor defines, its [command-line syntax](https://learn.microsoft.com/en-us/cpp/build/reference/compiler-command-line-syntax)
709+
accepts `-` instead of `/`.
710+
It's not necessary to treat preprocessor defines specially in Meson ([GH-6269](https://github.com/mesonbuild/meson/issues/6269#issuecomment-560003922)).

0 commit comments

Comments
 (0)