Skip to content

Commit 6317c8f

Browse files
ErniGHczoidodanimtbAbrilRBS
authored
From Zero to Package in Seconds: the new Conan MCP (#298)
* conan-mpc-blog * Update _posts/2025-11-01-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Carlos Zoido <mrgalleta@gmail.com> * Update _posts/2025-11-01-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Carlos Zoido <mrgalleta@gmail.com> * Update _posts/2025-11-01-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Daniel <danimanzaneque@gmail.com> * Update _posts/2025-11-01-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Daniel <danimanzaneque@gmail.com> * Update _posts/2025-11-01-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Daniel <danimanzaneque@gmail.com> * Update _posts/2025-11-01-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Carlos Zoido <mrgalleta@gmail.com> * Update _posts/2025-11-01-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Carlos Zoido <mrgalleta@gmail.com> * Update _posts/2025-11-01-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Daniel <danimanzaneque@gmail.com> * reviews with new videos * Update _posts/2025-11-01-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Abril Rincón Blanco <5364255+AbrilRBS@users.noreply.github.com> * Update _posts/2025-11-01-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Abril Rincón Blanco <5364255+AbrilRBS@users.noreply.github.com> * Update _posts/2025-11-01-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Abril Rincón Blanco <5364255+AbrilRBS@users.noreply.github.com> * Apply suggestion from @ErniGH * armv and gif * killer features first * assumes uv * change date * Update _posts/2025-12-04-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Carlos Zoido <mrgalleta@gmail.com> * Update _posts/2025-12-04-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Carlos Zoido <mrgalleta@gmail.com> * Update _posts/2025-12-04-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Carlos Zoido <mrgalleta@gmail.com> * Update _posts/2025-12-04-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Carlos Zoido <mrgalleta@gmail.com> * wip * Update _posts/2025-12-04-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Carlos Zoido <mrgalleta@gmail.com> * Update _posts/2025-12-04-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Carlos Zoido <mrgalleta@gmail.com> * Update _posts/2025-12-04-From-Zero-to-Package-in-Seconds-the-new-Conan-MCP.markdown Co-authored-by: Carlos Zoido <mrgalleta@gmail.com> * the Conan MCP *Server* Co-authored-by: Carlos Zoido <mrgalleta@gmail.com> --------- Co-authored-by: Carlos Zoido <mrgalleta@gmail.com> Co-authored-by: Daniel <danimanzaneque@gmail.com> Co-authored-by: Abril Rincón Blanco <5364255+AbrilRBS@users.noreply.github.com>
1 parent dcfdff0 commit 6317c8f

File tree

5 files changed

+127
-0
lines changed

5 files changed

+127
-0
lines changed
Lines changed: 127 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,127 @@
1+
---
2+
layout: post
3+
comments: false
4+
title: "From Zero to Package in Seconds: the new Conan MCP Server"
5+
description: "The integration of Conan with the MCP server offers several compelling advantages, particularly for developers working with C and C++ dependencies"
6+
meta_title: "From Zero to Package in Seconds: the new Conan MCP Server"
7+
categories: [MCP, AI, GPT, conan, conan-mcp]
8+
---
9+
10+
MCP (Model Context Protocol) is an [open-source standard](https://modelcontextprotocol.io/docs/getting-started/intro) that allows language models and AI applications like ChatGPT,
11+
Claude, or Grok to connect with other systems, enabling them to access data sources such as local files or databases,
12+
workflows like specific prompts, and tools, such as, in our case, the Conan client.
13+
14+
15+
## Why should I use it?
16+
The Conan MCP Server offers several compelling advantages, particularly for developers working
17+
with C and C++ dependencies and AI development tools:
18+
19+
### Enhanced Automation and Efficiency
20+
* **Easier Packaging Workflow**: The MCP server allows the language model to run Conan commands directly. This makes it
21+
possible to generate the basic structure of a C++ project, add dependencies in natural language, and prepare the project by
22+
installing the Conan dependencies it needs.
23+
It can also run security scans on your dependencies and list their declared licenses. All of this happens through simple natural
24+
language prompts, using your preferred LLM.
25+
* **Reduced Context Switching**: Developers no longer need to jump between their development environment, command line,
26+
and documentation to manage dependencies. The AI acts as an intelligent intermediary, handling complex Conan tasks
27+
in the background.
28+
29+
### Easy Dependency Management and Auditing
30+
* **Natural Language Package Search**: Thanks to the Conan MCP Server, you can search for the exact package you need from your
31+
remotes by specifying the operating system, architecture, compiled binary options, or even complex version range
32+
filters, all without resorting to command line syntax.
33+
* **Simplified Dependency Definition**: Leveraging the power of natural language processing through MCP, developers can
34+
define their required C/C++ dependencies without needing to memorize specific Conan syntax for creating recipe files.
35+
For instance, a simple request like "I need the latest version of Boost for my project,
36+
compiled with C++17 support" is translated by the AI agent into the necessary Conan commands and configuration.
37+
* **Proactive Auditing and Security**: The AI agent can proactively audit dependencies as they are installed, automatically
38+
checking for known vulnerabilities (CVEs) and verifying license compliance against project policies, giving immediate
39+
feedback in natural language.
40+
41+
## Let’s dive into real examples
42+
### Bootstrapping new Conan projects
43+
Let’s move on to one of the highlights of the MCP server: initial project setup using prompts. Suppose we want to start a project of a library
44+
that uses CMake, with dependencies on fmt and OpenSSL. We can let Conan MCP create the entire project scaffolding and
45+
install the dependencies.
46+
{% highlight bash %}
47+
Create a project for a CMake library using Conan, with dependencies on the
48+
latest versions of fmt and OpenSSL. Install the dependencies of the project.
49+
{% endhighlight %}
50+
<div style="text-align: center;">
51+
<img src="{{ site.baseurl }}/assets/post_images/2025-12-04/gif3-Create-project-x6.gif"
52+
alt="Create project gif example"/>
53+
</div>
54+
<br>
55+
56+
### Auditing project and checking licenses
57+
One of the most powerful features is how easily the Conan MCP server helps you check vulnerabilities and list dependency licenses. Using the previous
58+
project as a base, let’s ask the language model to ensure that the resolved versions have no vulnerabilities and that
59+
all the licenses used by our dependencies are suitable for commercial use.
60+
{% highlight bash %}
61+
Ensure my project’s third-party libraries are secure and licensed for commercial use.
62+
{% endhighlight %}
63+
<div style="text-align: center;">
64+
<img src="{{ site.baseurl }}/assets/post_images/2025-12-04/gif4-Verify-x10.gif"
65+
alt="Verify project gif example"/>
66+
</div>
67+
<br>
68+
69+
### Listing packages
70+
Let’s see a simpler one: we’re going to try to search for the compiled packages on ConanCenter for a library,
71+
such as zlib, with some options, including the architecture being arm and the shared option set to false, and have it tell
72+
us which versions we have packages for.
73+
{% highlight bash %}
74+
Tell me which versions of zlib packages are available with armv8 architecture and statically linked
75+
{% endhighlight %}
76+
<div style="text-align: center;">
77+
<img src="{{ site.baseurl }}/assets/post_images/2025-12-04/gif1-List-versions-x6.gif"
78+
alt="List versions gif example"/>
79+
</div>
80+
<br>
81+
82+
### Manage existing profiles
83+
The Conan MCP Server can also access the list of profiles and is able to query it, so that, for example, if you want to check which
84+
C++ version my Windows profile with MSVC 193 is configured for, you can simply ask:
85+
{% highlight bash %}
86+
Check my Conan profiles and tell me which cppstd is configured in the Windows profile that uses compiler version 193.
87+
{% endhighlight %}
88+
<div style="text-align: center;">
89+
<img src="{{ site.baseurl }}/assets/post_images/2025-12-04/gif2-profile-x6.gif"
90+
alt="Search profile gif example"/>
91+
</div>
92+
<br>
93+
It will list the profiles using a `conan profile list` command and then use `conan profile show` with the selected profile
94+
to obtain the required information. For this type of functionality to work correctly, we recommend maintaining a proper
95+
order when naming your Conan profiles.
96+
97+
## Installing the Conan MCP Server
98+
To install the Conan MCP Server, the first thing you need is an MCP client. You can use for example LibreChat or
99+
Cursor. Then, simply add to your MCP configuration.
100+
This assumes you have `uv` installed on your machine. `uv` has become a common way to run MCP servers. You can find installation instructions here: [uv installation guide](https://docs.astral.sh/uv/getting-started/installation/).
101+
{% highlight bash %}
102+
{
103+
"mcpServers": {
104+
"conan": {
105+
"command": "uvx",
106+
"args": ["conan-mcp"]
107+
}
108+
}
109+
}
110+
{% endhighlight %}
111+
112+
## What is next?
113+
The Conan MCP Server is still in an early stage, with a strong focus on the most critical developer workflows, and we are gradually
114+
expanding support for more Conan features. We would love to hear your feedback about what you are missing or which
115+
workflows you would like to see supported next.
116+
117+
We have prioritized the features most critical for the developer workflow: powerful **package search** and filtering,
118+
seamless **project creation** and dependency installation, profile checking, and the most essential: **vulnerability
119+
scanning and license listing**.
120+
121+
We would love to hear your ideas. Feel free to share your thoughts in our [repository](https://github.com/conan-io/conan-mcp)!
122+
If you have any suggestions for new features you would like to see addressed by the Conan MCP Server, or even if you wish to
123+
contribute code to the project, don't hesitate to do so!
124+
Your feedback and contributions are invaluable in shaping the future of this tool.
125+
126+
Happy prompting with the Conan MCP Server!
127+
2.92 MB
Loading
3.5 MB
Loading
25.3 MB
Loading
6.09 MB
Loading

0 commit comments

Comments
 (0)