From 9749744481352f1d1fdc62a6a3275496b3deb6e6 Mon Sep 17 00:00:00 2001 From: Bruce Dubbs Date: Sun, 17 Apr 2022 23:08:16 -0500 Subject: Use pip3 to install Python modules and programs meson, Markupsafe, and Jinja2 --- chapter08/jinja2.xml | 12 +++++++++--- chapter08/markupsafe.xml | 11 +++++------ chapter08/meson.xml | 29 +++++++++++++++-------------- 3 files changed, 29 insertions(+), 23 deletions(-) (limited to 'chapter08') diff --git a/chapter08/jinja2.xml b/chapter08/jinja2.xml index 3ac2bdb41..6548dff8b 100644 --- a/chapter08/jinja2.xml +++ b/chapter08/jinja2.xml @@ -40,9 +40,13 @@ Installation of Jinja2 + Build the package: + +pip3 wheel -w dist --no-build-isolation --no-deps $PWD + Install the package: -python3 setup.py install --optimize=1 +pip3 install --no-index --find-links dist Jinja2 @@ -50,10 +54,12 @@ Contents of Jinja2 - Installed directories + Installed directory - /usr/lib/python&python-minor;/site-packages/Jinja2-&jinja2-version;-py&python-minor;.egg + + /usr/lib/python&python-minor;/site-packages/Jinja2-&jinja2-version;.dist-info + diff --git a/chapter08/markupsafe.xml b/chapter08/markupsafe.xml index 32aa9e8b5..322ec2730 100644 --- a/chapter08/markupsafe.xml +++ b/chapter08/markupsafe.xml @@ -42,13 +42,13 @@ Compile MarkupSafe with the following command: -python3 setup.py build +pip3 wheel -w dist --no-build-isolation --no-deps $PWD This package does not come with a test suite. Install the package: -python3 setup.py install --optimize=1 +pip3 install --no-index --find-links dist Markupsafe @@ -59,10 +59,9 @@ Installed directory - - /usr/lib/python&python-minor;/site-packages/MarkupSafe-&markupsafe-version;-py&python-minor;-linux-<arch>.egg + + /usr/lib/python&python-minor;/site-packages/MarkupSafe-&markupsafe-version;.dist-info + diff --git a/chapter08/meson.xml b/chapter08/meson.xml index ffd4153b0..91b4b61bc 100644 --- a/chapter08/meson.xml +++ b/chapter08/meson.xml @@ -54,14 +54,13 @@ --> Compile Meson with the following command: -python3 setup.py build +pip3 wheel -w dist --no-build-isolation --no-deps $PWD The test suite requires some packages out of the scope of LFS. Install the package: -python3 setup.py install --root=dest -cp -rv dest/* / +pip3 install --no-index --find-links dist meson install -vDm644 data/shell-completions/bash/meson /usr/share/bash-completion/completions/meson install -vDm644 data/shell-completions/zsh/_meson /usr/share/zsh/site-functions/_meson @@ -69,14 +68,16 @@ install -vDm644 data/shell-completions/zsh/_meson /usr/share/zsh/site-functions/ The meaning of the install parameters: - --root=dest + -w dist - By default python3 setup.py install - installs various files (such as man pages) into Python Eggs. - With a specified root location, setup.py installs - these files into a standard hierarchy. Then the hierarchy - can just be copied to the standard location. - + Put the created wheels into the `dist` directory. + + + + + --find-links dist + + Install wheels from the 'dist' directory. @@ -92,10 +93,10 @@ install -vDm644 data/shell-completions/zsh/_meson /usr/share/zsh/site-functions/ meson - - /usr/lib/python&python-minor;/site-packages/meson-&meson-version;-py&python-minor;.egg-info and /usr/lib/python&python-minor;/site-packages/mesonbuild + + /usr/lib/python&python-minor;/site-packages/meson-&meson-version;.dist-info and + /usr/lib/python&python-minor;/site-packages/mesonbuild + -- cgit v1.2.3-54-g00ecf