Re: disable building wheel for a package

Paul Moore <[email protected]>
Newsgroups gmane.comp.python.distutils.devel
Message-ID <CACac1F9qEp1UwzWSsEyccbM-iV_8X3z3dt4wGQo1r-0DepwG3A@mail.gmail.com>
On Fri, 14 Sep 2018 at 14:51, sashk <[email protected]> wrote:
> No, I'm not installing anything into standard unix locations. My package is for internal use, so we had a luxury to write it specifically for use with virtual environment.
>
> We need to install Jupyter kernels (and other files) into $VIRTUAL_ENV/etc/jupyter and $VIRTUAL_ENV/share/jupyter paths. This was done with the help of data_files, and works unless we build wheel, because of use of absolute paths.
>
> Do I understand correctly, that when using relative paths in the data_files and installing package into virtual environment,  installation prefix is sys.prefix and it is the same as $VIRTUAL_ENV?

My understanding (and I'm not an expert here, so hopefully someone
else will confirm or correct) is that yes, the data directory is
installed to "the installation root", which is $VIRTUAL_ENV for a
virtualenv, and "something else" for non-virtualenvs (I think it's /
on Unix and sys.prefix on Windows, no idea what happens for user
installs).

See https://github.com/pypa/pip/blob/master/src/pip/_internal/locations.py#L136
for what pip does, but basically it defers to whatever
distutils/setuptools considers to be the `install_data` location.

This also sounds like the sort of requirement that came up in the
discussion around Daniel's proposal for more install locations, from
https://mail.python.org/pipermail/distutils-sig/2015-April/026222.html,
so maybe it's another motivating case for that proposal (although the
discussion in that thread petered out, so someone will need to pick it
up again if there's interest).

Paul
--
Distutils-SIG mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mm3/mailman3/lists/distutils-sig.python.org/
Message archived at https://mail.python.org/mm3/archives/list/[email protected]/message/ADD7U6CAFHZOHBSBDQMBUJXEHWQGMNIW/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.