[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Minios-devel] [UNIKRAFT/PYTHON3 PATCH v3 11/14] Makefile.uk: Add rule for creating root filesystem
Hi Costin, It might be good to create the directory if one is not there, that would be more user friendly (the README.md is a bit vague about this). -- Felipe On 23.09.19, 11:59, "Costin Lupu" <costin.lupu@xxxxxxxxx> wrote: 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 dc6e4ad..8bc3acd 100644 --- a/Makefile.uk +++ b/Makefile.uk @@ -464,3 +464,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 |