Re: [libgpiod][PATCH 1/1] bindings: python: standalone build tooling for tests

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 8 Nov 2023 at 15:04, Bartosz Golaszewski <brgl@xxxxxxxx> wrote:
>
> On Tue, 7 Nov 2023 22:51:56 +0100, Phil Howard <phil@xxxxxxxxxxxxx> said:
> > Move extension definitions and tooling for building tests into
> > `build_tests.py` and update Makefile.am to call it with appropriate path
> > prefixes.
> >
> > `build_tests.py` will perform a standalone build of the text extensions,
> > keeping any build noise in a temporary directory and copying the final
> > built modules automatically out to `tests/gpiosim` and `tests/procname`.
> >
> > Signed-off-by: Phil Howard <phil@xxxxxxxxxxxxx>
> > ---
>
> I'd like to be able to run the tests from the source tree but without
> --inplace the core C extension is no longer built in-tree so I cannot do:
>
>     PYTHONPATH=./bindings/python
> LD_LIBRARY_PATH=./lib/.libs/:./tests/gpiosim/.libs/:bindings/python/
> python -B -m tests
>
> Could you somehow keep this behavior?
>
> Bart

Sure, I can just add the gpiod extension to build_tests.py.

Looks like I had a stale one in my build directory, so when I ran the tests
they *just worked*. I'm adding gpiod/_ext.*.so and tests/*/_ext.*.so to
clean-local in Makefile.am to help prevent that.

I am also adding "python-tests-run" (could probably pick some better
names here?) to formalize your test command (I was running something
similar but not quite the same) so we (and any future pioneers) are working
on the same terms.

-- 
Phil



[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux