Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .github/workflows/android.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@ on:
- 'Cargo.lock'
- 'rust-toolchain.toml'
- '.cargo/**'
# Packaged into the app's assets (app/build.gradle.kts, LicenseAssets.kt)
# and compared byte for byte by LicenseAssetsTest.
- 'LICENSE'
- 'NOTICE'
pull_request:
branches: [main]
# `ready_for_review` starts the build on a PR opened as a draft; see the
Expand Down Expand Up @@ -129,6 +133,8 @@ jobs:
- 'android/**'
- 'crates/rustynes-mobile/**'
- '.github/workflows/android.yml'
- 'LICENSE'
- 'NOTICE'

# The project toolchain (rust-toolchain.toml = 1.100) plus the two shipped
# Android targets (arm64 ships; x86_64 is the emulator/CI ABI), through
Expand Down
22 changes: 21 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1353,10 +1353,30 @@ jobs:
env:
RUSTYNES_DAP_FIXTURES: ${{ runner.temp }}/dap-fixtures

# REUSE 3.3 compliance (2026-11-15): every tracked file must state its
# copyright holder and licence, in its own SPDX header or in REUSE.toml, and
# every licence named must have its text under LICENSES/. Deliberately NOT
# gated on `changes`: a docs-only PR (a new .md, a screenshot) is exactly the
# change that can add an unlabelled file, so this runs on every event.
# The action runs `reuse lint` in the `fsfe/reuse:6` image; the local
# equivalent is `uvx reuse lint` (6.3.0 when this job was added).
reuse:
name: reuse lint (REUSE 3.3)
runs-on: ubuntu-26.04
# Typical: ~30 s (image pull + lint of ~4,100 files). Bounded so a hung
# job cannot hold the concurrency group -- see the block comment above
# `concurrency`.
timeout-minutes: 20
steps:
- uses: actions/checkout@v7
with:
persist-credentials: false
- uses: fsfe/reuse-action@v6

ci-success:
name: CI success
if: ${{ always() }}
needs: [changes, setup, lint, test, full-build, test-roms, no_std, wasm, libretro-cross, bench, fuzz, coverage, dap-fixtures]
needs: [changes, setup, lint, test, full-build, test-roms, no_std, wasm, libretro-cross, bench, fuzz, coverage, dap-fixtures, reuse]
runs-on: ubuntu-26.04
# Typical: instant. Bounded so a hung job cannot hold the
# concurrency group -- see the block comment above `concurrency`.
Expand Down
19 changes: 19 additions & 0 deletions .github/workflows/ios.yml
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,25 @@ jobs:
CODE_SIGNING_ALLOWED=NO \
| tee xcodebuild.log

# The app must carry the repository-root LICENSE and NOTICE (the GPL text
# and the MIT / ISC notices of the code the core derives from), which
# project.yml lists as resources by `../` path with an explicit
# `buildPhase` (XcodeGen maps no phase to an extensionless file). Checked
# in the built bundle, so a resource-phase regression fails here, as
# Android's LicenseAssetsTest and web.yml's check do for theirs
# (Antigravity on PR #664).
- name: The app bundle carries LICENSE and NOTICE
working-directory: ios
run: |
set -euo pipefail
app=$(find build/DerivedData/Build/Products -maxdepth 2 -type d -name '*.app' | head -n 1)
test -n "$app" || { echo "::error::no .app under build/DerivedData/Build/Products"; exit 1; }
for f in LICENSE NOTICE; do
test -s "$app/$f" || { echo "::error::$app/$f is missing or empty"; exit 1; }
cmp "$app/$f" "../$f" || { echo "::error::$app/$f differs from the repository's $f"; exit 1; }
done
echo "ok: $app carries LICENSE and NOTICE, identical to the repository's"

- name: Upload the xcodebuild log
if: ${{ failure() }}
uses: actions/upload-artifact@v7
Expand Down
27 changes: 26 additions & 1 deletion .github/workflows/web.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ on:
- "mkdocs.yml"
- "PRIVACY.md"
- "scripts/render_privacy.py"
- "LICENSE"
- "NOTICE"
pull_request:
branches: [main]
# `ready_for_review` runs the build on a PR opened as a draft; see the
Expand All @@ -57,6 +59,8 @@ on:
- "mkdocs.yml"
- "PRIVACY.md"
- "scripts/render_privacy.py"
- "LICENSE"
- "NOTICE"
workflow_dispatch:

# Read-only by default. `pages: write` and `id-token: write` are granted per
Expand Down Expand Up @@ -217,7 +221,16 @@ jobs:
# Python-Markdown, installed above as a dependency of MkDocs.
run: python3 scripts/render_privacy.py PRIVACY.md privacy-site/privacy/index.html

- name: Assemble the Pages site (demo at /, rustdoc at /api/, handbook at /docs/, policy at /privacy/)
# Runs on PRs too, unlike the assembly below: a PR that touches LICENSE or
# NOTICE (both are trigger paths) must fail here if it empties or removes
# one, not only after it merges (Antigravity on PR #664).
- name: LICENSE and NOTICE are present and non-empty
run: |
for f in LICENSE NOTICE; do
test -s "$f" || { echo "::error::$f is missing or empty"; exit 1; }
done

- name: Assemble the Pages site (demo at /, rustdoc at /api/, handbook at /docs/, policy at /privacy/, LICENSE.txt + NOTICE.txt at /)
if: env.IS_PR != 'true'
run: |
set -euo pipefail
Expand All @@ -227,6 +240,18 @@ jobs:
cp -r target/doc/. _site/api/
cp -r mkdocs-site/. _site/docs/
cp -r privacy-site/. _site/
# The repository-root LICENSE (GPL-3.0 text) and NOTICE (third-party
# attributions, including the MIT and ISC notices of the code the
# core derives from), copied at build time so the site that serves
# the wasm build of that core carries them, as the desktop archives
# do (release.yml). The `.txt` names make Pages serve them as
# text/plain, which a browser displays; an extensionless file is
# served as a download. The privacy page and the handbook footer
# link to them; an empty or missing file fails the deploy.
for f in LICENSE NOTICE; do
test -s "$f" || { echo "::error::$f is missing or empty"; exit 1; }
cp "$f" "_site/$f.txt"
done
# rustdoc emits no root index for a multi-crate workspace; add a
# redirect to the main library facade so /api/ lands somewhere useful.
cat > _site/api/index.html <<'HTML'
Expand Down
6 changes: 5 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,8 @@ artifacts/

# --- ROMs & media (copyright) ---
# The broad `*.nes`/`*.fds` rules ignore ALL ROMs; re-include the committable
# CC0 / public-domain suites under tests/roms/, then HARD-exclude the commercial
# test-ROM suites under tests/roms/ (licences per file in REUSE.toml and
# tests/roms/LICENSES.md), then HARD-exclude the commercial
# dumps + the large fetched clone (NEVER committed — Nintendo copyright).
*.nes
*.fds
Expand Down Expand Up @@ -416,3 +417,6 @@ tests/roms/**/*.nl
# MkDocs Material's social-card and privacy plugins write their download/render
# cache here on every local `mkdocs build` (web.yml builds the handbook in CI).
/.cache/

# Third-party Alliance Memory SDRAM datasheets, marked "Confidential": kept on disk only, never redistributed (see ref-docs/2026-11-15-sdram-datasheet-sources.md).
/ref-docs/Datasheets/*.pdf
2 changes: 1 addition & 1 deletion AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ These cross-cutting decisions span multiple files. Reading individual chip docs
- `docs/` — implementation specs. These are the **spec**, not history: update them in the same PR as the code change. Per-subsystem files (`cpu-6502.md`, `ppu-2c02.md`, `apu-2a03.md`, `mappers.md`, `cartridge-format.md`, `scheduler.md`) + cross-cutting (`architecture.md`, `testing-strategy.md`, `performance.md`, `frontend.md`, `compatibility.md`). `docs/STATUS.md` is the **single source of truth** for per-suite pass counts, the mapper matrix, and version policy. `docs/adr/` holds Michael-Nygard-format ADRs.
- `ref-docs/` — immutable hardware + emulation reference (60+ source research report). Updates go in dated supplemental files.
- `to-dos/ROADMAP.md` → phase/sprint files — tickets with stable IDs `T-PS-NNN`. Reference in commits.
- `tests/roms/` — CC0 / public-domain test ROMs (committed). `tests/roms/external/` — your own commercial dumps (gitignored).
- `tests/roms/` — third-party test ROMs (committed; per-file licences in `REUSE.toml` and `tests/roms/LICENSES.md`, many with no licence stated). `tests/roms/external/` — your own commercial dumps (gitignored).
- `tests/golden/` / `screenshots/` — reference framebuffers, audio, and the visual baseline corpus (committed). `tests/captures/` — current-run output (gitignored).

**Never commit commercial Nintendo ROMs.**
Expand Down
32 changes: 32 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,38 @@ cycle-accurate core later replaced.

### Changed

- **The Android and iOS apps and the web site carry the licence and the
third-party notices.** The desktop archives always shipped `LICENSE` and
`NOTICE`; the apps and the site did not, although they run the same core,
whose MIT- and ISC-licensed derived code requires its notices in every
copy. Android packs both files into the APK at build time (a Gradle task
copies them from the repository root, so no second copy can drift, and a
JVM test checks the merged assets) and shows them from About ("Open-source
licenses"); iOS bundles them as resources from the root and shows them from
About; the web site publishes `LICENSE.txt` and `NOTICE.txt`, linked from
the demo page, the privacy page and every handbook page. ares is now
recorded as ISC (it was misnamed BSD-2-Clause / Apache-2.0), with its notice
in `NOTICE`, and Bisqwit's NTSC filter names its author, Joel Yliluoma.
The libretro core, built by the libretro buildbot, still ships without
them (`T-LIBRETRO-NOTICES`).
- **The tree is REUSE 3.3 compliant** (<https://reuse.software/spec-3.3/>).
A root `REUSE.toml` states the copyright holder and licence of every file
(first-party work: `2025-2026 DoubleGate`, GPL-3.0-or-later), adds the
upstream holders NOTICE names to the 37 `// Provenance:` files and the
vendored code, and `LICENSES/` holds every licence text used, including
three `LicenseRef-` texts: `NoStatedLicense` (blargg, kevtris and the
`christopherpow/nes-test-roms` ROMs, the "Nes Controller" font),
`ThirdPartyGameImagery` (screenshots of commercial games) and
`bbbradsmith-permissive`. A new `reuse` CI job runs `reuse lint` on every
event; check locally with `uvx reuse lint`. The claim that blargg's and
kevtris's suites and the aggregator ROMs are public domain is corrected in
`tests/roms/LICENSES.md`, `NOTICE`, the per-directory READMEs and
`docs/originality-and-provenance.md` section 7: no dedication or licence was
found. The three Alliance Memory SDRAM datasheets (marked "Confidential")
are no longer tracked; `ref-docs/2026-11-15-sdram-datasheet-sources.md`
gives their public download locations. The iOS store copyright line no
longer says "MIT OR Apache-2.0".

- **Rust 1.100.0** (from 1.99.1), with the libretro buildbot on the same
release (`.gitlab-ci.yml`), the workspace `rust-version`, the two
standalone manifests, the Worker image's base and the comments that name
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ Maintainers aim to review within 3–14 days; at least one approval and green CI

## Test ROM Legalities

The repository ships test ROMs (`tests/roms/`) that are individually CC0 or public-domain; do not add ROMs unless their license is explicitly documented in `tests/roms/LICENSES.md`. **Never commit commercial Nintendo ROMs.** Place them in `tests/roms/external/` (gitignored) for local oracle testing.
The repository ships third-party test ROMs (`tests/roms/`); their licences, or the fact that their authors stated none, are recorded per file in `REUSE.toml` and `tests/roms/LICENSES.md`. Do not add a ROM unless its author and license are documented in `tests/roms/LICENSES.md` and given a `REUSE.toml` annotation (the `reuse` CI job fails on an unlabelled file there). **Never commit commercial Nintendo ROMs.** Place them in `tests/roms/external/` (gitignored) for local oracle testing.

## Getting Help

Expand Down
1 change: 1 addition & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading