Skip to content

Add pantor/ruckig LLAR Formula (v0.17.3) - #115

Open
fennoai[bot] wants to merge 1 commit into
mainfrom
fennoai/issue-20-1785407796
Open

Add pantor/ruckig LLAR Formula (v0.17.3)#115
fennoai[bot] wants to merge 1 commit into
mainfrom
fennoai/issue-20-1785407796

Conversation

@fennoai

@fennoai fennoai Bot commented Jul 30, 2026

Copy link
Copy Markdown

Summary

Translates the Conan Center ruckig recipe into an idiomatic LLAR Formula, adding pantor/ruckig to llarhub. Resolves #20.

Source contract

  • Conan recipe folder all serves a single version, 0.17.3 → upstream tag v0.17.3.
  • Build system: CMake (min 3.15), C++20. No external dependencies — the optional cloud client bundles vendored third_party headers rather than pulling packages.
  • Conan disables BUILD_EXAMPLES, BUILD_TESTS, BUILD_PYTHON_MODULE, BUILD_CLOUD_CLIENT; the community core installs libruckig + include/ruckig, and consumers link ruckig::ruckig.

Files

  • pantor/ruckig/versions.json — module path, no static deps.
  • pantor/ruckig/Ruckig_cmp.gox — semver comparator for the v-prefixed tags.
  • pantor/ruckig/v0.17.3/Ruckig_llar.gox
    • onBuild: CMake helper builds the core static library (BUILD_SHARED_LIBS=OFF, CMAKE_POSITION_INDEPENDENT_CODE=ON, matching the Conan default shared=False), disabling examples/tests/python/cloud-client to match the recipe, and installs the full public interface (headers, libruckig.a, CMake config package). Metadata -lruckig.
    • onTest: reproduces the Conan test_package consumer (single-DoF trajectory update) via find_package(ruckig CONFIG) in an independent build tree, so verification works on both cache miss and cache hit.

Design notes: kept the CMake config package installed (Conan strips lib/cmake) so the consumer can find_package(ruckig) exactly like the Conan test. shared/fPIC options were not surfaced as matrix options — they don't change the installed consumer interface for this build, so the canonical static core is produced (per the "translate only output-affecting options" guidance).

Validation

Run against the exact upstream tag for Conan 0.17.3:

llar test -v ./pantor/ruckig@v0.17.3
  • ✅ Fresh build + install + consumer test → Ruckig update result: 0, metadata -lruckig.
  • ✅ Re-run: cache-hit onTest (onBuild skipped, consumer still builds/runs against cached install).
  • ✅ Explicit host matrix --os linux --arch amd64.
  • llar make ./pantor/ruckig@v0.17.3 emits -lruckig.

Single Formula range (fromVer "v0.17.3") since the recipe folder serves only 0.17.3; no additional version thresholds claimed.

Translate the Conan Center `ruckig` recipe into an idiomatic LLAR Formula.

- versions.json: module path pantor/ruckig, no external deps (the cloud
  client is disabled, so the vendored third_party headers are not built).
- Ruckig_cmp.gox: semver comparator for the v-prefixed tags.
- v0.17.3/Ruckig_llar.gox:
  - onBuild uses the CMake helper to build the core static library,
    disabling examples, tests, the Python module and the cloud client
    (mirrors the Conan recipe) and installing the full public interface
    (headers, libruckig.a, CMake config); metadata "-lruckig".
  - onTest reproduces the Conan test_package consumer in an independent
    build tree so it works on both cache miss and cache hit.

Verified with `llar test -v ./pantor/ruckig@v0.17.3` (fresh build + test,
cache-hit test, and explicit --os linux --arch amd64).

Closes #20

Co-authored-by: fennoai[bot] <231223108+fennoai[bot]@users.noreply.github.com>
Co-authored-by: MeteorsLiu <17515813+MeteorsLiu@users.noreply.github.com>

@fennoai fennoai Bot left a comment

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review: Add pantor/ruckig LLAR Formula (v0.17.3)

Solid, well-scoped Formula. Verified against the LLAR DSL spec (.claude/skills/write-formula/references/llar-formula.md) and the reference madler/zlib Formula:

  • versions.json.path, id, directory path, fromVer "v0.17.3", and the Ruckig filename stems all agree with the layout rules.
  • Error handling is correct: os.mkdirAll(...)! / os.writeFile(...)! use the required-error form; CMake configure/build/install are called without result assignment; exec at the end of onTest is followed by an immediate lastErr check.
  • onTest builds in a separate tree (_testconsumer/_build) from onBuild (_build), so it is cache-hit safe, and it does not mutate metadata.
  • Empty deps: {} with no onRequire is correct given the cloud client / Python module / tests / examples are all disabled — the core static lib pulls in no external dependency.
  • semver.compare (lowercase) is a valid XGo alias for semver.Compare; not a bug.
  • Security and performance passes found nothing noteworthy: the network cloud client is correctly disabled (BUILD_CLOUD_CLIENT=OFF), and no shell/injection or unsafe-path concerns exist.

One substantive finding on the emitted metadata — see the inline comment.

c.install

// Consumers link the installed "ruckig" library (target ruckig::ruckig).
ctx.setMetadata "-lruckig"

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The metadata is a bare -lruckig, which omits the install-directory search paths. Upstream installs headers to include/ruckig and the archive to lib/, so a consumer given only -lruckig has no -I<installDir>/include or -L<installDir>/lib and cannot locate <ruckig/ruckig.hpp> or the archive. The spec's Metadata section says to include install-directory paths when consumers need them.

This gap is not caught by onTest: the consumer there uses find_package(ruckig REQUIRED CONFIG) via tc.use installDir (CMAKE_PREFIX_PATH), so it never exercises the metadata string.

Also note the comment on the line above describes the CMake target (ruckig::ruckig), but the metadata emitted is a raw linker flag — different consumer contracts. Consider deriving the metadata from the installed CMake config (or otherwise including -I/-L paths) so raw-metadata consumers can compile and link.

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.

Translate Conan Center ruckig recipe to LLAR

0 participants