[Numpy-discussion] Re: Meson - C extension - Finding numpy includes in virtual env
It looks like `spin build` does `meson build` and `meson install` and doesn't do `pip install`. I'd like numpy to be importable in a python environment of my choosing, so I tend to instead manually install numpy into that environment by invoking pip with something like `python -m pip install . -v --no-build-isolation -Cbuilddir=build -C'compile_args=-v' -C'setup_args=-Dbuildtype=debug'. I like seeing the compile command meson uses, so I pass in `-v` through meson's `compile_args` and I often need a debug build, so I set the build type manually as well. I could probably get the same effect by either manually activating the spin python environment (not sure how to do that) or using `spin run` somehow outside of the numpy tree, but what I have seems to work OK for me now so I haven't tried to mess with spin more. On Sun, Nov 26, 2023 at 1:57 PM Stefan van der Walt wrote: > On Sun, Nov 26, 2023, at 12:03, Nathan wrote: > > For my work I tend to use a persistent build directory with build > isolation disabled as discussed in the meson-python docs. > > > Out of curiosity, how is this different from, e.g., `spin build` which > builds into `./build-install`? > > Stéfan > > ___ NumPy-Discussion mailing list -- numpy-discussion@python.org To unsubscribe send an email to numpy-discussion-le...@python.org https://mail.python.org/mailman3/lists/numpy-discussion.python.org/ Member address: arch...@mail-archive.com
[Numpy-discussion] Re: Meson - C extension - Finding numpy includes in virtual env
Hi Nathan, On Tue, Nov 28, 2023, at 08:42, Nathan wrote: > It looks like `spin build` does `meson build` and `meson install` and doesn't > do `pip install`. I'd like numpy to be importable in a python environment of > my choosing, so I tend to instead manually install numpy into that > environment by invoking pip with something like `python -m pip install . -v > --no-build-isolation -Cbuilddir=build -C'compile_args=-v' > -C'setup_args=-Dbuildtype=debug'. I like seeing the compile command meson > uses, so I pass in `-v` through meson's `compile_args` and I often need a > debug build, so I set the build type manually as well. That makes sense. We recently added the `spin.pip.install` command for that purpose, but of course you don't *need* a command if you know the invocation :) Stéfan ___ NumPy-Discussion mailing list -- numpy-discussion@python.org To unsubscribe send an email to numpy-discussion-le...@python.org https://mail.python.org/mailman3/lists/numpy-discussion.python.org/ Member address: arch...@mail-archive.com
[Numpy-discussion] Next Newcomers' Hour: Thursday Nov 30th, 12pm UTC
Hi all! Our next Newcomers' Hour will be held this Thursday, November 30th at 12 pm (noon) UTC. Stop by to ask questions, share your progress, celebrate success, or just to say hi. To add to the meeting agenda the topics you’d like to discuss, follow the link: https://hackmd.io/3f3otyyuTte3FU9y3QzsLg?both Join the meeting via Zoom: https://numfocus-org.zoom.us/j/82563808729?pwd=ZFU3Z2dMcXBGb05YemRsaGE1OW5nQT09 Hope to see you around! - Melissa ___ NumPy-Discussion mailing list -- numpy-discussion@python.org To unsubscribe send an email to numpy-discussion-le...@python.org https://mail.python.org/mailman3/lists/numpy-discussion.python.org/ Member address: arch...@mail-archive.com