Skip to content

Downstream Linux hosts hand-copy the system source list; ship a single includable manifest #234

Closed

Description

@turinglambdaai

Problem

Every downstream product's Linux CMakeLists.txt hand-copies the
${RIVET_ROOT}/platform/linux/system/*.cpp file list from
platform/linux/host/CMakeLists.txt. When rivet adds a file, every
downstream copy goes stale silently until the link fails.

This has now bitten twice in taskly alone:

Proposal

Ship a single manifest, e.g. platform/linux/rivet_linux_sources.cmake:

set(RIVET_LINUX_SYSTEM_SOURCES
  "${RIVET_ROOT}/platform/linux/system/autostart.cpp"
  ...
)

platform/linux/host/CMakeLists.txt consumes the same variable, and
downstream hosts include() it instead of copying. New rivet source
files then reach every downstream build with zero coordination.

Notes

  • taskly currently pins rivet.git#v0.8.1, so it cannot simply add the
    two new files yet — the fix and the pin bump have to travel together.
  • The hand-rolled list exists because downstream hosts embed rivet
    sources directly into their own executable; the manifest must keep
    that model (no added library target, just the variable).

Activity

  1. turinglambdaai commented on Oct 13, 2026

    @turinglambdaai
    OwnerAuthor

    Implemented on main in 13ae88b:

    • platform/linux/rivet_linux_sources.cmake — the single includable manifest (RIVET_LINUX_PLATFORM_SOURCES + RIVET_LINUX_INCLUDE_DIRS), with include_guard(GLOBAL) and a usage contract in the header comment.
    • platform/linux/host/CMakeLists.txt now include()s the fragment instead of carrying its own copy.
    • tests/linux-sources-fragment.rkt — the anti-drift guard: every *.cpp the fragment lists must exist in the package (a rename/deletion must touch the fragment in the same commit), and the host template must not grow a private copy of the list again.

    Verified in script mode (14 sources / 4 include dirs, all files exist) and by the guard test. Downstream migration is one line per repo — include("${RIVET_ROOT}/platform/linux/rivet_linux_sources.cmake") and ${RIVET_LINUX_PLATFORM_SOURCES} in add_executable — but downstreams should switch only after the catalog serves this commit, so their explicit lists stay correct in the meantime (taskly/syncpilot/fulcrum/brainfuel/payback/movebit/keyward all got the missing sources added explicitly today; taskly as the benchmark should switch first, per its own note).

  2. turinglambdaai commented on Oct 13, 2026

    @turinglambdaai
    OwnerAuthor

    Shipped in Rivet 0.11.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions