Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

options patterns clarifications #3720

Merged
merged 1 commit into from
May 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion reference/commands/graph/explain.rst
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ In the same way, it can report when a package has a different option value and t

.. code-block:: text

$conan graph explain --requires=lib/1.0.0 -o shared=True --format=json
$conan graph explain --requires=lib/1.0.0 -o lib/*:shared=True --format=json
...
{
"closest_binaries": {
Expand Down
6 changes: 3 additions & 3 deletions reference/config_files/profiles.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ They have this structure:
os=Macos

[options]
MyLib:shared=True
mylib/*:shared=True

[tool_requires]
tool1/0.1@user/channel
Expand Down Expand Up @@ -204,8 +204,8 @@ List of options available from your recipe and its dependencies:
:caption: *myprofile*

[options]
my_pkg_option=True
shared=True
mypkg/*:my_pkg_option=True
*:shared=True


.. _reference_config_files_profiles_tool_requires:
Expand Down
12 changes: 11 additions & 1 deletion tutorial/consuming_packages/different_configurations.rst
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,17 @@ using the ``--options`` argument. To do so, please run:

Doing this, Conan will install the *Zlib* shared libraries, generate the files to build with
them and, also the necessary files to locate those dynamic libraries when running the
application. Let's build the application again after configuring it to link *Zlib* as a
application.

.. note::

Options are defined per-package. In this case we were defining that we wanted that specific
version of zlib/1.2.11 as a shared library. If we had other dependencies and we want all of
our dependencies (whenever possible) as shared libraries, we would use ``-o *:shared=True``,
with the ``*`` pattern that matches all package references.


Let's build the application again after configuring it to link *Zlib* as a
shared library:

.. code-block:: bash
Expand Down