diff --git a/src/doc/en/installation/meson.rst b/src/doc/en/installation/meson.rst index e0051dbbf68..e900003f151 100644 --- a/src/doc/en/installation/meson.rst +++ b/src/doc/en/installation/meson.rst @@ -88,12 +88,13 @@ To configure the project, we need to run the following command: $ meson setup builddir --prefix=$PWD/build-install This will create a build directory ``builddir`` that will hold the build artifacts. -The ``--prefix`` option specifies the directory where the Sage will be installed. +The ``--prefix`` option specifies the directory where the Sage will be installed, +and can be omitted when ``pip`` is used to install as explained below. -If pip is used as above, ``builddir`` is set to be +If pip is used as above with ``--editable``, ``builddir`` is set to be ``build/cp[Python major version][Python minor version]``, such as ``build/cp311``. -``--prefix=`` can be left unspecified, when conda is used then meson will -install to the conda environment e.g. ``$HOME/miniforge3/envs/sage-dev/``. +``--prefix=`` can be left unspecified, the installation directory can be specified +later with ``DESTDIR`` as explained below. To compile the project, run the following command: @@ -117,7 +118,8 @@ Usually, this directory is not on your Python path, so you have to use: When editable install is used, it is not necessary to reinstall after each compilation. -Alternatively, we can still use pip to install: +Alternatively, we can still use pip to install (which does not require specifying +``--prefix`` in advance and automatically works with conda environment): .. CODE-BLOCK:: shell-session @@ -144,6 +146,7 @@ Miscellaneous tips The environment variable ``MESONPY_EDITABLE_VERBOSE=1`` can be set while running ``./sage``, so that when Cython files are recompiled a message is printed out. +See ``_. If a new ``.pyx`` file is added, it need to be added to ``meson.build`` file in the containing directory.