MCP Server for GNU Make
Project description
mcp-server-make
MCP Server for GNU Make - providing controlled and secure access to Make systems from LLMs.
Features
Resources
make://current/makefile- Access current Makefile content securelymake://targets- List available Make targets with documentation
Tools
list-targets: List available Make targets- Returns target names and documentation
- Optional pattern filtering for searching targets
run-target: Execute Make targets safely- Required: target name
- Optional: timeout (1-3600 seconds, default 300)
Quick Start
Prerequisites
- Python 3.12+
- GNU Make
- pip or uv package manager
Installation
Using uv (recommended):
uvx mcp-server-make
Using pip:
pip install mcp-server-make
Claude Desktop Integration
Add to your Claude Desktop configuration:
MacOS:
nano ~/Library/Application\ Support/Claude/claude_desktop_config.json
Windows:
notepad %APPDATA%\Claude\claude_desktop_config.json
Add configuration:
{
"mcpServers": {
"mcp-server-make": {
"command": "uv",
"args": [
"--directory",
"/path/to/server",
"run",
"mcp-server-make",
"--makefile-dir", "/path/to/project"
]
}
}
}
--directory: Path to the installed mcp-server-make package--makefile-dir: Directory containing the Makefile to manage
Restart Claude Desktop to activate the Make server.
Usage Examples
List Available Targets
I see you have a Makefile. Can you list the available targets?
View Target Documentation
What does the 'build' target do?
Run Tests
Please run the test target with a 2 minute timeout.
View Makefile
Show me the current Makefile content.
Development
Local Development Setup
# Clone repository
git clone https://github.com/wrale/mcp-server-make
cd mcp-server-make
# Create virtual environment
uv venv
source .venv/bin/activate # Unix/MacOS
.venv\Scripts\activate # Windows
# Install dependencies
make dev-setup
# Run tests and checks
make check
Testing with MCP Inspector
Test the server using the MCP Inspector:
npx @modelcontextprotocol/inspector uv --directory /path/to/mcp-server-make run mcp-server-make --makefile-dir /path/to/project
Security Features
Version 0.1.5 implements several security controls:
- Path validation and directory boundary enforcement
- Target name sanitization and command validation
- Resource and timeout limits for command execution
- Restricted environment access and cleanup
- Error isolation and safe propagation
Behavior Details
Resource Access
- Makefile content is read-only and validated
- Target listing includes names and documentation
- Full path validation prevents traversal attacks
- Resources require proper make:// URIs
Tool Execution
- Targets are sanitized and validated
- Execution occurs in controlled environment
- Timeouts prevent infinite execution
- Clear error messages for failures
- Resource cleanup after execution
Error Handling
- Type-safe error propagation
- Context-aware error messages
- Clean error isolation
- No error leakage
Known Limitations
Version 0.1.5 has the following scope limitations:
- Read-only Makefile access
- Single Makefile per working directory
- No support for include directives
- Basic target pattern matching only
- No variable expansion in documentation
Contributing
- Fork the repository
- Create a feature branch
- Add tests for new features
- Ensure all checks pass (
make check) - Submit a pull request
License
MIT - See LICENSE file for details.
Support
- GitHub Issues: Bug reports and feature requests
- GitHub Discussions: Questions and community help
Version History
0.1.5
- Version bump
- Added workflow status badges
- Bug fixes and improvements
0.1.0
- Initial stable release
- Basic Makefile access and target execution
- Core security controls
- Claude Desktop integration
- Configurable Makefile directory
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file mcp_server_make-0.1.5.tar.gz.
File metadata
- Download URL: mcp_server_make-0.1.5.tar.gz
- Upload date:
- Size: 7.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.0.1 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3685349beb264e37ae7e7842aaa4ff79889ab3c440890ad1afb034c6066c9a0d
|
|
| MD5 |
bcc5e04212d65a48807de42fca3600e2
|
|
| BLAKE2b-256 |
e7346cfc1efc5d1567bccc53d49f6b0b7399c574b8b51e6d994588334766aa6c
|
Provenance
The following attestation bundles were made for mcp_server_make-0.1.5.tar.gz:
Publisher:
release.yml on wrale/mcp-server-make
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mcp_server_make-0.1.5.tar.gz -
Subject digest:
3685349beb264e37ae7e7842aaa4ff79889ab3c440890ad1afb034c6066c9a0d - Sigstore transparency entry: 156159934
- Sigstore integration time:
-
Permalink:
wrale/mcp-server-make@dda24dff22999a62faf90ce255edf96fbf004fb7 -
Branch / Tag:
refs/tags/v0.1.5 - Owner: https://github.com/wrale
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@dda24dff22999a62faf90ce255edf96fbf004fb7 -
Trigger Event:
release
-
Statement type:
File details
Details for the file mcp_server_make-0.1.5-py3-none-any.whl.
File metadata
- Download URL: mcp_server_make-0.1.5-py3-none-any.whl
- Upload date:
- Size: 10.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.0.1 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1d9322efe9e9897e2fa29297b1d7ab368e854650794fb979a4f798adffade9ff
|
|
| MD5 |
743f0654845999316c5e67d227bc366b
|
|
| BLAKE2b-256 |
0eea8c816079e1d560d4d05c0ea81b0fd84ae9ddfaed3d1253990051c016a04e
|
Provenance
The following attestation bundles were made for mcp_server_make-0.1.5-py3-none-any.whl:
Publisher:
release.yml on wrale/mcp-server-make
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mcp_server_make-0.1.5-py3-none-any.whl -
Subject digest:
1d9322efe9e9897e2fa29297b1d7ab368e854650794fb979a4f798adffade9ff - Sigstore transparency entry: 156159935
- Sigstore integration time:
-
Permalink:
wrale/mcp-server-make@dda24dff22999a62faf90ce255edf96fbf004fb7 -
Branch / Tag:
refs/tags/v0.1.5 - Owner: https://github.com/wrale
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@dda24dff22999a62faf90ce255edf96fbf004fb7 -
Trigger Event:
release
-
Statement type: