refactor: Migrate global hash inputs to resolution knowledge (#13525)
## Intent
Finish migrating resolution **consumers**: root/global external
fingerprints and the missing-lockfile global-file fallback must come
from resolution state / definition sources, matching task hashing—not
`PackageInfo` closures or singleton lockfile object checks.
**Stack:** layer 3 / 5. Base = layer 2 (prune).
## Changes
- Root external hash from resolution fingerprint cache (`//`)
- Unavailable JS resolution → hash definition sources + root
`package.json`
- Remove owned singleton lockfile reads from global-hash collection
## Out of scope
Task contracts (Phase 5), deleting legacy fields (next layer).
## Testing
- `cargo test -p turborepo-task-hash --lib`
- `cargo test -p turborepo-repository --lib
javascript_resolution_distinguishes_resolved_empty_from_unavailable`
- `cargo clippy -p turborepo-repository -p turborepo-task-hash -p
turborepo-lib --all-targets -- -D warnings`
Closes TURBO-5813.
---------
Co-authored-by: Cursor Agent <cursoragent@cursor.com>
Co-authored-by: Anthony Shew <anthonyshew@users.noreply.github.com>