From e5fbe654a4814d396eb4a535b89856e574898991 Mon Sep 17 00:00:00 2001 From: Roland Hieber Date: Tue, 8 Oct 2019 12:07:56 +0200 Subject: doc: dev/ref manual: describe the _PATCHES variable Fixes: 2e2242356f0bc72a56bc ("ptxd_make_world_patchin: allow specifying a custom patch directory") Signed-off-by: Roland Hieber Signed-off-by: Michael Olbrich --- doc/dev_manual.rst | 5 ++++- doc/ref_make_variables.inc | 10 ++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/doc/dev_manual.rst b/doc/dev_manual.rst index c37094090..29d1cbf1d 100644 --- a/doc/dev_manual.rst +++ b/doc/dev_manual.rst @@ -1265,7 +1265,10 @@ integrated into your BSP or into PTXdist. PTXdist handles patching automatically. After extracting the archive of a package, PTXdist checks for the existence of -a patch directory named like its ```` variable. +a patch directory named like its ``_PATCHES`` variable, or, if this variable +is not set, like its ```` variable. +The patch directory is then searched in all locations listed by the +``PTXDIST_PATH_PATCHES`` variable, and the first one found is used. Take an exemplary package ``foo`` with version ``1.1.0``: The variable ``FOO`` will have the value ``foo-1.1.0``, so PTXdist will look for a patch directory named ``foo-1.1.0`` in the following locations: diff --git a/doc/ref_make_variables.inc b/doc/ref_make_variables.inc index 08854c7db..fcfac83d3 100644 --- a/doc/ref_make_variables.inc +++ b/doc/ref_make_variables.inc @@ -205,6 +205,16 @@ Package Definition For local URLs (``file://`` or ``lndir://``) ``_SOURCE`` must not be set. +``_PATCHES`` + The name of the patch directory, relative to any of the paths listed in + ``PTXDIST_PATH_PATCHES`` (i.e., according to the search order described in + :ref:`patching_packages`). + If not specified, the default patch directory name is set to the value of the + ```` variable. + + This variable can be set for multiple packages that should share the same + patch stack (e.g. kernel packages). + ``_DIR`` This is the directory where the source archive is extracted. In most cases this is set to ``$(BUILDDIR)/$()``. However, if two packages -- cgit v1.2.3