-
-
Notifications
You must be signed in to change notification settings - Fork 30.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Doc sys.prefix lib & include directories on Windows and Mac #89946
Comments
On the page: https://docs.python.org/3.10/library/sys.html#sys.prefix the text says The main collection of Python library modules is installed in the directory prefix/lib/pythonX.Y while the platform independent header files (all except pyconfig.h) are stored in prefix/include/pythonX.Y, where X.Y is the version number of Python, for example 3.2. However, this seems to only be true on *nix systems. On Windows, the lib and header files are just in prefix/lib and prefix/include. Maybe the text should be changed to say: On linux, the main collection of Python library modules is installed in the directory prefix/lib/pythonX.Y while the platform independent header files (all except pyconfig.h) are stored in prefix/include/pythonX.Y, where X.Y is the version number of Python, for example 3.2. On Winodws, there are in prefix/lib and prefix/includes. |
On Windows, I believe the correct sentence would be "On Windows, they are in prefix/Lib and prefix/include". Ned, how to complete "On macOS, they are in ?." Victor, with recent file movement, is "while the platform independent header files (all except pyconfig.h) are stored in prefix/include" still true? In what way is pyconfig.h exceptional? Should 'include' be augmented with 'or its subdirectories'? |
Which installations paths are used varies on other factors besides platform. Rather than duplicate information here, I suggest simplifying the sys.prefix doc here by removing the details about installation paths and instead refer to the Installation Paths section of the sysconfig module documentation, which should be the primary reference for this info: https://docs.python.org/3/library/sysconfig.html#installation-paths |
Are you talking about Include/cpython/ and Include/internal/ subdirectories?
You can add it if you want. |
Ned, I like your idea. In particular, link to sysconfig.get_paths for how prefix is used on a particular machine to define installation paths. Sidenote: |
Hey thanks Ned, sysconfig was exactly what I was looking for when I was reading the sys documentation. |
Yes, it should be there. |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: