[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Minios-devel] [UNIKRAFT/PYTHON3 PATCH 11/12] Makefile.uk: Add rule for creating root filesystem
The Python interpreter needs a filesystem where to keep its libraries. This patch creates a Python virtual environment and installs the Python 3 standard library in /lib/python3.7 directory. For creating the filesystem the following command has to be run: $ make python-rootfs path=<directory> Signed-off-by: Costin Lupu <costin.lupu@xxxxxxxxx> --- Makefile.uk | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/Makefile.uk b/Makefile.uk index 8fbc37c..27eaba5 100644 --- a/Makefile.uk +++ b/Makefile.uk @@ -450,3 +450,24 @@ LIBPYTHON3_PREPARED_DEPS = \ $(LIBPYTHON3_BUILD)/.prepared: $(LIBPYTHON3_PREPARED_DEPS) UK_PREPARE += $(LIBPYTHON3_BUILD)/.prepared + +################################################################################ +# Root filesystem +################################################################################ + +# Build root filesystem for Python interpreter +PYTHON_ROOTFS = $(APP_BASE)/$(path) + +# Create virtual environment +$(PYTHON_ROOTFS)/.keep: + python3 -m venv $(PYTHON_ROOTFS) && touch $@ + +# Configure origin +$(LIBPYTHON3_SRC)/config.status: + cd $(LIBPYTHON3_SRC) && ./configure --prefix=$(shell realpath $(APP_BASE)/$(path)) + +# Install Python standard library into virtual environment +.PHONY: python-rootfs +python-rootfs: $(PYTHON_ROOTFS)/.keep $(LIBPYTHON3_SRC)/config.status + cd $(LIBPYTHON3_SRC) && make libinstall + cp $(LIBPYTHON3_BASE)/_sysconfigdata.py $(PYTHON_ROOTFS)/lib/python3.7/ -- 2.20.1 _______________________________________________ Minios-devel mailing list Minios-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/minios-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |