Sorry, something went wrong.
|
Example: ./configure --prefix ~/prefix
make
make install COMPILEALL_OPTS="--hardlink-dupes -j4"
Output: (...)
PYTHONPATH=/home/vstinner/prefix/lib/python3.12 \
./python -E -Wi /home/vstinner/prefix/lib/python3.12/compileall.py \
-o 0 -o 1 -o 2 --hardlink-dupes -j4 -d /home/vstinner/prefix/lib/python3.12/site-packages -f \
-x badsyntax /home/vstinner/prefix/lib/python3.12/site-packages
(...)
compileall is called with options: -o 0 -o 1 -o 2 --hardlink-dupes -j4:
|
Sorry, something went wrong.
|
I tested again to double check. Ah, in fact compileall is called two times: once for Lib/, once for site-packages: (...)
PYTHONPATH=/home/vstinner/prefix/lib/python3.12 \
./python -E -Wi /home/vstinner/prefix/lib/python3.12/compileall.py \
-o 0 -o 1 -o 2 --hardlink-dupes -j4 -d /home/vstinner/prefix/lib/python3.12 -f \
-x 'bad_coding|badsyntax|site-packages|test/test_lib2to3/data' \
/home/vstinner/prefix/lib/python3.12
Listing '/home/vstinner/prefix/lib/python3.12'...
(...)
PYTHONPATH=/home/vstinner/prefix/lib/python3.12 \
./python -E -Wi /home/vstinner/prefix/lib/python3.12/compileall.py \
-o 0 -o 1 -o 2 --hardlink-dupes -j4 -d /home/vstinner/prefix/lib/python3.12/site-packages -f \
-x badsyntax /home/vstinner/prefix/lib/python3.12/site-packages
Listing '/home/vstinner/prefix/lib/python3.12/site-packages'...
(...)
|
Sorry, something went wrong.
|
This is an improvement, thanks! OTOH we would probably also like an opinion to disable this entirely and do it ourselves. |
Sorry, something went wrong.
|
Merged, thanks for the review! |
Sorry, something went wrong.
|
OTOH we would probably also like an opinion to disable this entirely and do it ourselves. That can be a separated option. IMO this change alone is already an enhancement ;-) |
Sorry, something went wrong.
Add COMPILEALL_OPTS variable in Makefile to override compileall options (default: -j0) in "make install". Merge also the 3 compileall commands into a single command building PYC files for the 3 optimization levels (0, 1, 2).