[issue42307] make install must not copy python.o into $prefix/lib/python3.10/config-3.10-x86_64-linux-gnu/

2021-02-17 Thread STINNER Victor
STINNER Victor added the comment: I consider that this issue is now fixed by bpo-43103 with the addition of a new configure --without-static-libpython option. If someone prefers to remove python.o and get it from libpython.a, please open a separated issue. -- resolution: ->

[issue42307] make install must not copy python.o into $prefix/lib/python3.10/config-3.10-x86_64-linux-gnu/

2021-02-02 Thread STINNER Victor
STINNER Victor added the comment: I created bpo-43103 "Add configure option to disable build libpython.a and don't install python.o". -- ___ Python tracker ___

[issue42307] make install must not copy python.o into $prefix/lib/python3.10/config-3.10-x86_64-linux-gnu/

2021-01-27 Thread Miro Hrončok
Change by Miro Hrončok : -- nosy: +hroncok ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue42307] make install must not copy python.o into $prefix/lib/python3.10/config-3.10-x86_64-linux-gnu/

2020-11-10 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: Hummm, I think the gains of having the .o over the .a are very very small as you can almost recreate anything you want with the .o using the .a and a small initialization function unless I am missing something. --

[issue42307] make install must not copy python.o into $prefix/lib/python3.10/config-3.10-x86_64-linux-gnu/

2020-11-10 Thread STINNER Victor
STINNER Victor added the comment: The Fedora package of Python doesn't build the static libpython for 10 years (patch added at 2010-01-18): https://src.fedoraproject.org/rpms/python3.9/blob/master/f/00111-no-static-lib.patch libpython3.10.a (static) is around 15 MB and libpython3.10.so

[issue42307] make install must not copy python.o into $prefix/lib/python3.10/config-3.10-x86_64-linux-gnu/

2020-11-10 Thread Neil Schemenauer
Neil Schemenauer added the comment: I think the comments are correct in that it is used to create a new statically linked interpreter that includes a user provided extension module. We could include python.o inside the libpythonXX.a file but then I think it breaks if you are embedding

[issue42307] make install must not copy python.o into $prefix/lib/python3.10/config-3.10-x86_64-linux-gnu/

2020-11-10 Thread Ned Deily
Ned Deily added the comment: > Embedding? The example I cited from the docs was for extending Python by building a new interpreter using an installed Python, not embedding. Dunno how often that is done, though. Perhaps on Windows where it was more difficult to build an interpreter from

[issue42307] make install must not copy python.o into $prefix/lib/python3.10/config-3.10-x86_64-linux-gnu/

2020-11-10 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: > But... does any user really build Python manually after Python is installed? > The Python build system couldn't handle that as part of the regular build? > Maybe using a new configure --enable-static flag? Embedding? But they should use the .a not

[issue42307] make install must not copy python.o into $prefix/lib/python3.10/config-3.10-x86_64-linux-gnu/

2020-11-10 Thread STINNER Victor
STINNER Victor added the comment: Oh! I managed to build a static Python with the following commands: cd /opt/pymaster/lib/python3.10/config-3.10-x86_64-linux-gnu gcc -static -o ~/python-static python.o -L. $(./python-config.py --libs --embed) I get a static binary: $ ldd ~/python-static

[issue42307] make install must not copy python.o into $prefix/lib/python3.10/config-3.10-x86_64-linux-gnu/

2020-11-10 Thread Ned Deily
Ned Deily added the comment: I don't know for sure why python.o is included but perhaps the intent was to allow a user to rebuild a static interpreter with an user-supplied extension as is hinted at in https://docs.python.org/dev/extending/extending.html#compilation-and-linkage --

[issue42307] make install must not copy python.o into $prefix/lib/python3.10/config-3.10-x86_64-linux-gnu/

2020-11-10 Thread STINNER Victor
STINNER Victor added the comment: python.o is the object file build by the C compiler from Programs/python.c. I don't see why anyone would need such object file. Programs/python.c: --- /* Minimal main program -- everything is loaded from the library */ #include "Python.h" #ifdef MS_WINDOWS

[issue42307] make install must not copy python.o into $prefix/lib/python3.10/config-3.10-x86_64-linux-gnu/

2020-11-10 Thread STINNER Victor
Change by STINNER Victor : -- keywords: +patch pull_requests: +22117 stage: -> patch review pull_request: https://github.com/python/cpython/pull/23219 ___ Python tracker ___

[issue42307] make install must not copy python.o into $prefix/lib/python3.10/config-3.10-x86_64-linux-gnu/

2020-11-10 Thread STINNER Victor
STINNER Victor added the comment: At commit 85515ad9795ffc3b676cbddeeea2b003818a2623, "make install" installs the following files in the config/ directory: $ find /opt/pyold/lib/python2.1/config/ /opt/pyold/lib/python2.1/config/ /opt/pyold/lib/python2.1/config/libpython2.1.a

[issue42307] make install must not copy python.o into $prefix/lib/python3.10/config-3.10-x86_64-linux-gnu/

2020-11-10 Thread STINNER Victor
STINNER Victor added the comment: python.o is installed by "make libainstall". It is done since 2001 (commit 85515ad9795ffc3b676cbddeeea2b003818a2623). Git history: commit 49fd7fa4431da299196d74087df4a04f99f9c46f Author: Thomas Wouters Date: Fri Apr 21 10:40:58 2006 + Merge p3yk

[issue42307] make install must not copy python.o into $prefix/lib/python3.10/config-3.10-x86_64-linux-gnu/

2020-11-10 Thread STINNER Victor
New submission from STINNER Victor : Commands reproduce the issue: cd /path/to/python/source/ ./configure --prefix /opt/pymaster CFLAGS="-O0" make make install make install copies python.o: $ find /opt/pymaster/ -name "*.o" /opt/pymaster/lib/python3.10/config-3.10-x86_64-linux-gnu/python.o