Skip to content

feat(compat): add compat.robin-map 1.4.1 and compat.nanobind 3.1.0 - #933

Merged
Sunrisepeak merged 1 commit into
mcpplibs:mainfrom
Shinonome-Ryoko14:feat/compat-nanobind
Nov 30, 2026
Merged

Sunrisepeak merged 1 commit into
mcpplibs:mainfrom
Shinonome-Ryoko14:feat/compat-nanobind

Conversation

@Shinonome-Ryoko14

Copy link
Copy Markdown
Contributor

Summary

Add compat.robin-map (1.4.1) and compat.nanobind (3.1.0) along with workspace example tests.

Package Design

compat.robin-map (1.4.1, MIT)

  • Header-only Shape B package for Tessil/robin-map, exposing */include (<tsl/robin_map.h>, <tsl/robin_set.h>) with a minimal C anchor target.
  • Packaged as an independent dependency because wjakob/nanobind keeps ext/robin_map as a git submodule that is empty in GitHub release archives. Declaring compat.robin-map in deps avoids any network/submodule fetch inside install().

compat.nanobind (3.1.0, BSD-3-Clause)

  • Shape B package for wjakob/nanobind, following the same rule as compat.pybind11: no Python.h dependency at package level.
  • install() moves the extracted nanobind-<version>/ tree directly into the install directory so all descriptor paths stay version-agnostic.
  • Exposes include/ (<nanobind/nanobind.h>, <nanobind/stl/*.h>) and generates <mcpp_nanobind_combined.hpp>, which forwards to ../../src/nb_combined.cpp. Consumers include <mcpp_nanobind_combined.hpp> in exactly one translation unit compiled with their target Python SDK and ABI flags.
  • Depends on compat.robin-map = "1.4.1" for <tsl/robin_map.h>.

Notes

  • Mirror URLs: Both descriptors currently use plain upstream GitHub release archive URLs (per docs/cn-mirror.md fallback for contributors without mcpp-res write access). Maintainers can convert them to GLOBAL/CN tables without changing the sha256 checksums.

Files Changed

  • pkgs/c/compat.robin-map.lua — compat.robin-map 1.4.1 descriptor
  • pkgs/c/compat.nanobind.lua — compat.nanobind 3.1.0 descriptor
  • tests/examples/robin-map/ — smoke test exercising tsl::robin_map / tsl::robin_set
  • tests/examples/nanobind/ — embedded nanobind module test via xim:python and <mcpp_nanobind_combined.hpp>
  • mcpp.toml — register both example members in the workspace

Verification

  • Linux: descriptor lint and workspace tests (tests/examples/robin-map, tests/examples/nanobind) pass
  • Windows: native build and tests (tests/examples/robin-map, tests/examples/nanobind) pass
  • macOS: pending CI verification

@Sunrisepeak
Sunrisepeak merged commit b918e6b into mcpplibs:main Nov 30, 2026
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants