Re: [PATCH v4 0/5] meson: wire up support for benchmarks
On Fri, Apr 25, 2025 at 10:26 AM Patrick Steinhardt <ps@pks.im> wrote:
>
> On Fri, Apr 25, 2025 at 10:06:12AM +0200, Christian Couder wrote:
Show 32 quoted lines
> > In https://lore.kernel.org/git/aAc8f52rJ8ATncVc@pks.im/ you said you
> > would try to paraphrase some explanations about how GIT_BUILD_DIR is
> > computed, but it looks like there aren't any changes in the patch
> > since the previous version :-(
>
> There were, but not in this version:
>
> 3: d03ca0c0630 ! 3: a66bc5aaf51 t/perf: fix benchmarks with out-of-tree builds
> @@ Commit message
> assumption breaks with both CMake and Meson, where the build directory
> can be located in an arbitrary place.
>
> - Adapt the script so that it works with out-of-tree builds. This prepares
> - us for wiring up benchmarks in Meson.
> + Adapt the script so that it works with out-of-tree builds. Most
> + importantly, this requires us to figure out the location of the build
> + directory:
> +
> + - When running benchmarks via our Makefile the build directory is the
> + same as the source directory. We already know to derive the test
> + directory ("t/") via `$(pwd)/..`, which works because we chdir into
> + "t/perf" before executing benchmarks. We can thus derive the build
> + directory by appending another "/.." to that path.
> +
> + - When running benchmarks via Meson the build directory is located at
> + an arbitrary location. The build system thus has to make the path
> + known by exporting the `GIT_BUILD_DIR` environment variable.
> +
> + This change prepares us for wiring up benchmarks in Meson.
>
> The changes were already part of v3, so you have to look at the diff
> versus v2.Oops, sorry for the noise.