git: 82930d2795ec - main - misc/py-mcp: Add new port

From: Nicola Vitale <nivit_at_FreeBSD.org>
Date: Tue, 18 Mar 2025 09:47:56 UTC
The branch main has been updated by nivit:

URL: https://cgit.FreeBSD.org/ports/commit/?id=82930d2795ec9527f4577e20055ffe57287a8f00

commit 82930d2795ec9527f4577e20055ffe57287a8f00
Author:     Nicola Vitale <nivit@FreeBSD.org>
AuthorDate: 2025-03-18 09:46:33 +0000
Commit:     Nicola Vitale <nivit@FreeBSD.org>
CommitDate: 2025-03-18 09:46:33 +0000

    misc/py-mcp: Add new port
    
    The Model Context Protocol allows applications to provide context for LLMs in a
    standardized way, separating the concerns of providing context from the actual
    LLM interaction. This Python SDK implements the full MCP specification, making
    it easy to:
    
      - Build MCP clients that can connect to any MCP server
      - Create MCP servers that expose resources, prompts and tools
      - Use standard transports like stdio and SSE
      - Handle all MCP protocol messages and lifecycle events
    
    https://pypi.python.org/pypi/mcp
---
 misc/Makefile         |  1 +
 misc/py-mcp/Makefile  | 29 +++++++++++++++++++++++++++++
 misc/py-mcp/distinfo  |  3 +++
 misc/py-mcp/pkg-descr |  9 +++++++++
 4 files changed, 42 insertions(+)

diff --git a/misc/Makefile b/misc/Makefile
index a17dc3760ade..db13a25eb2ae 100644
--- a/misc/Makefile
+++ b/misc/Makefile
@@ -459,6 +459,7 @@
     SUBDIR += py-llm
     SUBDIR += py-llm-claude-3
     SUBDIR += py-log_symbols
+    SUBDIR += py-mcp
     SUBDIR += py-mffpy
     SUBDIR += py-mixpanel
     SUBDIR += py-mmcv
diff --git a/misc/py-mcp/Makefile b/misc/py-mcp/Makefile
new file mode 100644
index 000000000000..011a7d038ac0
--- /dev/null
+++ b/misc/py-mcp/Makefile
@@ -0,0 +1,29 @@
+PORTNAME=	mcp
+DISTVERSION=	1.3.0
+CATEGORIES=	misc python
+MASTER_SITES=	PYPI
+PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
+
+MAINTAINER=	nivit@FreeBSD.org
+COMMENT=	Python implementation of the Model Context Protocol (MCP)
+WWW=		https://pypi.python.org/pypi/mcp
+
+LICENSE=	MIT
+LICENSE_FILE=	${WRKSRC}/LICENSE
+
+BUILD_DEPENDS=	${PYTHON_PKGNAMEPREFIX}hatchling>=1.27.0:devel/py-hatchling@${PY_FLAVOR}
+RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}anyio>=4.5:devel/py-anyio@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}httpx-sse>=0.4:www/py-httpx-sse@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}httpx>=0.28.1:www/py-httpx@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pydantic-settings>=2.6.0:devel/py-pydantic-settings@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pydantic2>=2.10.6_2:devel/py-pydantic2@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}sse-starlette>=2.2.0:www/py-sse-starlette@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}starlette>=0.45.3:www/py-starlette@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}uvicorn>=0.34.0:www/py-uvicorn@${PY_FLAVOR}
+
+USES=		python
+USE_PYTHON=	autoplist pep517
+
+NO_ARCH=	yes
+
+.include <bsd.port.mk>
diff --git a/misc/py-mcp/distinfo b/misc/py-mcp/distinfo
new file mode 100644
index 000000000000..1344f0c506e4
--- /dev/null
+++ b/misc/py-mcp/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1741774341
+SHA256 (mcp-1.3.0.tar.gz) = f409ae4482ce9d53e7ac03f3f7808bcab735bdfc0fba937453782efb43882d45
+SIZE (mcp-1.3.0.tar.gz) = 150235
diff --git a/misc/py-mcp/pkg-descr b/misc/py-mcp/pkg-descr
new file mode 100644
index 000000000000..57e581ef5a05
--- /dev/null
+++ b/misc/py-mcp/pkg-descr
@@ -0,0 +1,9 @@
+The Model Context Protocol allows applications to provide context for LLMs in a
+standardized way, separating the concerns of providing context from the actual
+LLM interaction. This Python SDK implements the full MCP specification, making
+it easy to:
+
+  - Build MCP clients that can connect to any MCP server
+  - Create MCP servers that expose resources, prompts and tools
+  - Use standard transports like stdio and SSE
+  - Handle all MCP protocol messages and lifecycle events