Skip to content

Commit 674f9cd

Browse files
committed
Fix and clarify description of self.folders.subproject
The old documentation was wrong, as the subproject is not required to be the folder, where the `conanfile.py` is located. An example, where this is not the case, can be found here: https://docs.conan.io/2/examples/conanfile/layout/conanfile_in_subfolder.html
1 parent 29e8a3d commit 674f9cd

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

reference/conanfile/methods/layout.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,9 @@ self.folders
3939
**self.folders.root**.
4040

4141
- **self.folders.subproject** (Defaulted to ``None``): Specifies a subfolder where the
42-
``conanfile.py`` is relative to the project root. This is particularly useful for
43-
:ref:`layouts with multiple subprojects<examples_conanfile_layout_multiple_subprojects>`
42+
project is contained relative to ``self.folders.root``. This is particularly useful for
43+
:ref:`layouts with multiple subprojects<examples_conanfile_layout_multiple_subprojects>`.
44+
Most of the layout (e.g. source and build folder) is relocated inside this folder.
4445

4546
- **self.folders.build_folder_vars** (Defaulted to ``None``): Use settings, options and/or
4647
``self.name`` and ``self.version`` to produce a different build folder and different CMake presets names.

0 commit comments

Comments
 (0)