Skip to content

Add a minimal freestanding object example #663

Closed

Description

@LunaStev

Why

Wave documents freestanding targets and can emit freestanding object files, but examples/ does not contain a minimal example dedicated to that workflow. Existing freestanding coverage lives in the test corpus and is intentionally much more complex than a first example should be.

Scope

Add a small freestanding Wave example that can be compiled to an object file with an existing *-unknown-none-elf target.

The example should:

  • avoid hosted runtime, libc, filesystem, network, and standard output dependencies;
  • contain a small deterministic function or data transformation that is meaningful when emitted as an object;
  • document the exact wavec build --freestanding --emit=obj --target ... command;
  • optionally document a standard object-inspection command when the required LLVM/binutils tool is already available.

Do not add startup code, a linker script, boot logic, or QEMU execution. The broader freestanding startup and system-smoke work remains tracked separately, including #371 for RISC-V.

Completion criteria

  • The source passes wavec check for the selected freestanding target.
  • The documented command emits a relocatable object successfully.
  • The example has no accidental hosted or libc dependency.
  • Its README or examples index explains that object emission is the end of this example's scope.
  • Existing freestanding test cases and startup work remain unchanged.

Activity

  1. added
    documentation
    good first issue
    needs testing
    on Sep 15, 2026
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

    documentationgood first issueneeds testing

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions