Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Add a test package and docs for the "C/C++ lib with optional Python bindings" use case

未关闭
#744 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
3/5
预计耗时
1-2 天
新手友好度
45/100
Issue 类型
文档
描述清晰度
基本清楚
活跃度
停滞
技术栈
c, cpp, python

调研方向

先从链接的 pull request 讨论和 issue 中描述的项目布局开始,然后检查现有的测试包和文档,了解相关用例。添加一个测试包,用于覆盖子目录中的带有 Python bindings 的 C/C++ 库,并提供有关布局和 sdist 处理的指导。完成的标准是:该包的测试能够构建并链接顶层库,且文档化的工作流清晰明确。

由索引模型根据 Issue 内容生成。

描述

documentation tests

This follows up on the discussion at https://github.com/mesonbuild/meson-python/pull/728#discussion_r2069077299. The use case is multi-language projects, like the Arrow projects, where the root of the repo contains a core C/C++ library and bindings for Python (and perhaps other languages) are present in sub-directories. This is a fairly common layout:

meson.build
src/
    <some_c_sources>
    meson.build
python/
    <some_python_sources>
    pyproject.toml
    meson.build

The challenge here is to get the top-level library built and linked against. The idea in the linked discussion is to add:

python/
    dist_script.py  # replaces symlink with a copy for sdist generation
    subprojects/
        <symlink with content `../..`>

We've seen other people struggle with this puzzle when trying to adopt meson-python, e.g. in https://github.com/mesonbuild/meson-python/discussions/674. It would be good to have a test package for this project structure, and a bit of documentation to point out how this can be handled.

主要语言
Python
星标
180
派生
93
平均合并
20 小时 58 分钟
30 天内合并 PR
22

环境准备

这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

mesonbuild/meson-python 的其他 Issue

查看 mesonbuild/meson-python 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。