AnyPS5 Guides

Set up AnyPS5 on Linux

Set up AnyPS5 on Linux: convert the game executable to ELF, organize runtime libraries and resources, select a Vulkan GPU and check udmabuf permissions and memory limits.

Reviewed ·

Relink and launch from the runtime folder

Choose the Linux relinker and Linux-native libraries. Linux output is ELF by default. Keep app0/ resources next to the output, put AnyPS5 libraries in libs/, and run from that directory so relative paths resolve consistently. The commands below use example paths, which you must replace with your own.

Terminal / example
chmod +x ./relinker-v0.1.2
./relinker-v0.1.2 ./source/input.elf ./runtime/app.elf
cd ./runtime
chmod +x ./app.elf
./app.elf

Check the driver’s memory route

Some Linux driver paths use dma-buf through /dev/udmabuf; NVIDIA uses a different path. A missing device, denied permission or too-small size limit can prevent a run. Identify which path your driver uses and read the current upstream udmabuf instructions before changing system settings.

Shader caches, window visibility, compositor and first-run compilation can change FPS substantially. Report whether the cache was warm, whether the window was visible and how long the sample ran. Keep menu, cutscene and gameplay measurements separate.

Runtime-loaded game modules on current main

v0.1.2 USAGE documents repeated --module-dir for game modules outside sce_module/, such as Unity Media/Modules and Media/Plugins. Pass each directory explicitly, preserve the module layout and pair the relinker with its libraries. These options do not verify a title or justify deprecated skip-module, syscall-check or lazy-binding workarounds.

Separate launch, device and memory failures

Check the log for the selected Vulkan device before comparing a community benchmark. On a machine with two GPUs, a valid Vulkan device can still be the integrated one. Current main accepts ANYPS5_GPU as a case-insensitive part of the device name and fails with a list of candidates if none match. Use the exact names printed by your build; do not assume this setting exists in an older release.

For dma-buf drivers, a permission error opening /dev/udmabuf can lead to copy-based fallback and later GPU memory failures. First check whether the device exists and whether your session has access; group changes require a new login. A size limit is a separate condition from access permission. Follow the driver-specific upstream instructions and retain the original settings for comparison instead of raising unrelated system limits for every GPU.

Check display and audio build dependencies

The full Linux source build requires SDL X11, Xext and XRandR development files, plus PipeWire, PulseAudio or ALSA development support. Debian/Ubuntu: libx11-dev, libxext-dev, libxrandr-dev; Fedora: include libXrandr-devel. Keep SDL_X11_XRANDR enabled; current configuration rejects missing refresh-query support. Fedora Threads errors may need glibc-static and libstdc++-static.

Current main prefers a suitable discrete Vulkan device. Confirm the printed device rather than assuming the laptop used the intended GPU; ANYPS5_GPU selects a case-insensitive name fragment. Keep /dev/udmabuf access checks separate from its size limit and from shader failures. A working window or audio backend is still only one part of a game test.

Linux release display support and a remaining collision

v0.1.1 was offscreen-only; #5383 is now closed after a matching v0.1.2 pair opened X11 and ran Sarah on an MX230. #5396 was closed unmerged because its extra packages were already dependencies, not the cause fix. v0.1.2 predates #5738: YNw9Xk5iNWo can abort first presentation. The cited Linux run uses the preload below; later main fixes the helper collision. This workaround is tied to that error, not general compatibility.

Terminal / example
LD_PRELOAD=libs/libSceMouse.prx ./app.elf

dma-buf permissions and size are different limits

Permission denied and an EINVAL UDMABUF_CREATE failure need different checks. In #5329 a single 147.6 MiB range exceeds that host’s 64 MiB size_limit_mb; a temporary 2048 MiB limit passes the import but does not solve the later Vulkan timeout. A run-list PR does not automatically cover an oversized single run. Inspect the host’s actual limit and failed range before changing it; the reported temporary setting resets on reboot.

Terminal / example
cat /sys/module/udmabuf/parameters/size_limit_mb

Choose the backend supported by your source build

Main added native Wayland after v0.1.2 in #3664. With the documented Wayland, xkbcommon, EGL and libdecor development files, SDL prefers Wayland when WAYLAND_DISPLAY is set. Without them it builds X11 only. SDL_VIDEODRIVER=x11 selects XWayland, but a title bundling its own SDL may reject that backend. Check the actual build and session rather than treating an offscreen window or background-window FPS as a game result.

Keep the title’s original metadata and ELF modules

Preserve app0/sce_sys/param.json from your own title, including its titleId and localized titleName. Main uses it for metadata and directory creation; do not change budgets to imitate another report. For import_audit.py --modules use original unwrapped ELF modules, plus every generated registry as positional input. Converted .guest.prx files on Windows are PE output, not those audit inputs.

Executable permissions and rebuildable shader caches

After-release main marks every generated executable executable. Browser downloads or copies may lose that mode: chmod +x each listed executable, including launchers’ child programs. Shaders are cached beside the output under shader_cache/ unless ANYPS5_SHADER_CACHE_DIR changes it. Deleting that cache triggers recompilation; a cold/warm timing difference is not itself a game fix.

Optional app0 archive on current main

Current main reads optional app0.zar beside app0/, rooted at app0. Loose files win; keep the executable, sce_module and sce_sys loose. Besides kernel read/seek/stat, reviewed main supports APR file resolution/reads, read-only fopen, access and sceNgs2ParseWaveformFile through the archive. It does not provide arbitrary archive-path operations, merged directory listing or writes. An unreadable archive stops at access. Keep a working loose-file setup and the exact build; these later additions are not established for v0.1.5.

Warm pipeline replay has its own cache

Later main records pipelines.journal and replays the newest4096 entries. Graphics retention starts1024 and grows to4096 for replay/reused evictions; APS5_PIPELINE_STORE_ENTRIES fixes the count when set. This is a count bound, not a memory budget. Replay threads default to half the CPU threads;0 records only. APS5_NO_PIPELINE_JOURNAL =1 disables it; MAX_MIB remains1024. Different GPU/driver resets the journal; warm cache is not a gameplay FPS guarantee. v0.1.3 keeps its original behavior.

Collect bounded stall evidence

Current-main APS5_PM4_RING keeps16 submissions per queue by default, up to512 dwords each; 0 disables, maximum4096. APS5_STALL_WATCHDOG_SECS defaults to0; a positive value up to86400 dumps once per stalled wait and continues waiting. It is distinct from the Windows aborting hang dump. Invalid settings stop at submission. The new TRACING reference lists diagnostic switches; tracing changes timing, so retain an ordinary control run.

Choose PlayGo answers by title

After v0.1.2, merged #6236 adds APS5_PLAYGO_UNLISTED_CHUNKS for dumps without playgo-chunk.dat and playgo-scenario.json. Unset still stops on unknown nonzero IDs. installed helps High on Life save loading; absent ends the Sifu and Demon Slayer searches. installed can make Demon Slayer allocate without end. Metadata-bearing dumps are unaffected. These are emulator observations, not console validation; preserve the exact tested build.

Larger caches can reduce performance

Current main dynamically budgets sampled textures and storage images against available device memory. Leave APS5_TEXTURE_CACHE_MIB unset unless a same-card measurement supports overriding it: oversized caches can spill to host memory and slow PCIe reads. Shader-cache current-version entries have no size cap and are not aged out; monitor free disk space. Large host-import budgets and experimental settle-floor patches are also hardware/title-specific, not universal FPS settings.

Touchpad input and dependency diagnosis

Current main pad_input.py accepts touch-left/touch-right. Default keyboard touch halves are Backspace/Tab; L2 is now bound to R/mouse X1. Import audit now follows host-library dependencies transitively and accepts literal ELF symbol names before hashed NIDs. A passing audit proves dependency discovery, not correct API behavior or gameplay. Profiling and trace buffers alter timing/memory; retain ordinary control runs.

Explicit module roots and backup files

Current main accepts a title with no standard module directory only when --module-dir is explicit; homebrew root libraries can use --module-dir . without empty placeholder folders. The CLI skips a backup ELF only beside another ELF with the same SONAME; a lone ELF backup beside a SELF still converts. Keep original relative module paths and matching runtime libraries.

Read the performance overlay in context

Post-v0.1.2 main adds F10 or ANYPS5_OVERLAY=1, with tl/tr/bl/br positions. FPS counts every present, including black/loading frames. PROFILED marks runs with GPU/draw profiling: compare against an ordinary control. GPU timings overlap and can exceed frame time; RAM excludes shared direct memory. The overlay adds a render pass, not an FPS boost. Invalid nonempty settings stop at first presentation.

Local trophies have explicit limits

Current main stores unlocks in _trophy/<userid>_<label>.txt and statistics in .stats.txt, using original trophy/UDS UCP data. Only latest uint32/uint64 statistics and simple event rules are supported. Missing data uses placeholders; icons still throw. No trophy notifications, callbacks or PSN sync. Corrupt saved records stop rather than silently reset; retain a backup when reporting a failure.

Check sparse import capability before changing kernel limits

The reviewed main documents a sparse fallback for imports above64 MiB when the device supports sparse blocks of at most64 KiB. This is a device capability condition, not proof that every oversized import succeeds. Permission, actual udmabuf limit and unsupported driver paths remain separate checks; preserve the failing build before comparing a newer main.

Later main: import tracing on Linux

Current main documents --trace-imports for Windows and Linux; it conflicts with --lazy-binding and records nothing without APS5_TRACE_CALLS. Linux prints the recent calls only on abort, not a Windows-style crash report. Output includes the global last 64 calls, the reporting thread’s last 32 from a 65536-call ring, and 32 top imports. These are diagnostic traces with overhead, not gameplay benchmarks; the v0.1.3 attached usage guide still limits this option to Windows.

Later main: module initialization boundaries

With --module-dir, reviewed main maps required modules at startup. Linux starts extra-directory modules only on explicit load with the title’s arguments. Windows starts a deferred module after its deferred dependencies with the same arguments; dependencies needed from outside those directories initialize at startup, and the first explicit load also starts remaining dependency providers best effort. macOS starts executable/module dependencies eagerly. These rules differ from older builds; converting all files alone does not prove correct initialization.

Later main: Linux default image base and patch verification

Ordinary Linux output is now ET_EXEC at0x400000 without ASLR; --linux-fixed-base selects another aligned base. Deprecated --lazy-binding keeps ET_DYN and cannot use bundled modules. A generated patch manifest records linux_base: --verify-output checks ET_EXEC offsets with that value, while ET_DYN requires no linux_base. PE/Mach-O remain refused; module entries are not verified. Do not apply this current-main behavior retrospectively to v0.1.3 or older tests.

Later main: linked resource directories

Current Linux directory listing follows a symlink inside app0 to the file/directory type, so the title can walk a linked directory. Nested links inside a linked directory targeting outside app0 keep link type: for nested trees link only top-level entries, or copy/use hard links. This supersedes the older blanket no-symlink instruction only on builds carrying this change. Preserve the original title metadata and resources.

Later main: a missing converted module is an error, not a library substitute

A title can load a module after startup. Current main reports “[module] dlopen: … was not relinked” once per file, returns a load error and lets the title continue; a later null fault may follow. Add that module directory with --module-dir and keep the generated guest module in app0. Original PS5 PRX files do not belong in Windows libs/. This does not prove every missing-module crash has the same cause.

Later main: unwrap padding limit

The SELF unwrapper refuses more than64MiB total alignment padding before allocating output. This counts padding across file-backed and empty segments, not their data bytes. Refusal preserves input and an existing output. It does not decrypt encrypted content, and it is a current-main boundary rather than a new v0.1.3 release.

Later main: map a module before starting it

Convert Unity’s extra directories with --module-dir Media/Modules --module-dir Media/Plugins, retaining originals and each printed Guest module output. Later Linux main maps needed modules at startup but starts extra-directory modules only on explicit load, with the title’s arguments. Windows/macOS initialization rules differ. Lost in Play and Coffee Talk provide bounded setup follow-ups, not a universal null-call fix; keep matching relinker/runtime builds.

Later main: a local patch advisor

suggest_patches.py requires Python3.11+, an explicit param.json, local catalog and relinker. It matches title/version and target-file hashes, then invokes --verify-patches; it never downloads or applies a patch. Multiple valid entries yield no recommendation. Hashes identify bytes, not trust or playability. Keep catalog files outside the input directory to avoid automatic patch discovery, and repeat the same module/additional-executable options during conversion.

Follow the generated module layout

Current main prints app0/<module folder>/<name>.guest.prx. Its dynamic loader explicitly chooses the converted sibling; GAME_TESTING now says keep the original beside it. Silt’s earlier2dc8e456 report removed originals to avoid its older resolver: preserve that recipe with its version. New module-parent scanning suggests --module-dir for matching unconverted modules but cannot report unreadable files. A clean scan is not proof every runtime load exists.

Check every Linux library path entry

On current main, every colon-separated --rpath entry must be nonempty. With guest modules, each entry must be absolute or start with $ORIGIN. Quote $ORIGIN in the shell so it reaches the relinker literally; trailing colons and empty middle entries are invalid. Windows separately requires a nonempty ASCII path. These conversion rules are pinned to main, not silently added to older release instructions.

Import tracing and its platform limits

Current main documents --trace-imports for Windows, Linux and macOS output; --lazy-binding remains incompatible. APS5_TRACE_CALLS selects libraries or all; unset means no recording. Linux and macOS print these records on abort, with no crash report. Conversion support or a tracing flag does not establish an official macOS runtime release. Match the documentation and library files to your actual build.

Fullscreen and two overlay pages

Current main adds F11 fullscreen and F10 cycling off → page1 → page2 → off. ANYPS5_FULLSCREEN starts at desktop resolution when nonempty and not0; it is not a game render-resolution override. ANYPS5_OVERLAY accepts only0/1/2; positions are tl/tr/bl/br. Page2 uses one-second intervals and instrumentation has overhead. Inclusive CPU phases and overlapping GPU ranges cannot be added; missing counters are omitted, not zero. System commit/limit is not process RSS; Linux reports a limit only with strict overcommit=2. Flip/present/drop/repeat counts describe different events. These main features are not established as part of unchanged v0.1.3.

Treat converted programs as ordinary host applications

Converted programs run with your host account’s permissions; conversion does not recreate the console sandbox. Keep sensitive files separate and use a restricted account or isolation when appropriate. Current main’s APS5_USB_STORAGE_PASSTHROUGH is opt-in and exposes host-mounted USB FAT/exFAT volumes writable; unset it scans no volumes and exposes no USB device. This option is not required by every game. --version prints the build identity and exits; it does not test a game. The online converter now follows CLI backup/SONAME skip rules. A destination directory that already exists is rejected before writing.

Patch catalogs: structure, file matches and runtime are different checks

Current main documents Python 3.11+ tools/validate_patch_catalog.py --catalog <directory>. It checks catalog structure, paths, hashes covered by entries and duplicate IDs, without reading game files, downloading or applying anything. Exit0 means structurally valid, including an empty catalog; exit2 means invalid. Only relinker --verify-patches checks actual target parsing and byte matches. Optional tested records distinguish verification/conversion/launch/gameplay, with passed/failed/partial results and contributor-provided evidence; the advisor does not independently confirm those claims. A higher revision does not automatically win: replace an older same-build ID instead of leaving two verified duplicates. These current-main tools are not a new official runtime release; Check the selected release documentation before using this source feature.

Keep runtime metadata and diagnose explicit input-file errors

Keep the title’s original app0/sce_sys/param.json, including titleId and localizedParameters/titleName. Main falls back to param.sfo only when JSON is absent; absent or malformed metadata can stop title/window setup. Startup creates data/, and download0/ for nonzero downloadDataSize, only from valid metadata. A named ANYPS5_INPUT_CONFIG file that is missing or unreadable is an error; invalid mapping lines name the file and line. Built-in bindings apply when neither a default input file nor an explicit setting exists. These behaviors are pinned to current main, not retroactively assigned to older reports. For launcher tests, distinguish its front end, account flow, downloaded client and actual game scene.

Preview conversion without writing output

v0.1.5 supports relinker --dry-run. Supply the intended output path. It checks conversion and prepares the outputs in memory without creating files or testing write permissions. It cannot be combined with --autorun or --verify-patches. Use a separate run to verify startup.

Output class, display and frame limits are different settings

Reviewed main documents APS5_OUTPUT_RESOLUTION=WxH: both dimensions below 3840×2160 select the 1080p VideoOut class; otherwise it reports the 2160 class. This does not force internal rendering resolution, and some games ignore it. ANYPS5_DISPLAY_INDEX chooses a connected SDL display by zero-based index. ANYPS5_FPS_LIMIT accepts 0.5–1000000 with at most three decimals; 0/empty/unset disables it. A cap cannot accelerate a slow game or exceed its output cadence. These settings are absent from v0.1.4’s usage attachment; preserve the actual tested commit.

Preserve title metadata before overriding startup answers

Main now accepts decimal ID lists such as APS5_PLAYGO_UNLISTED_CHUNKS=0,1, only when both original PlayGo metadata files are absent. Existing scenario JSON takes precedence; this cannot repair an incomplete dump. installed and absent are title-specific diagnostics, not universal fixes. Windows now starts extra-directory modules only when explicitly requested or needed transitively by modules outside extra; mapping a module is not starting it. Keep the exact source revision and test save loading separately.

Capture the host before changing runtime policy

v0.1.4 documents ANYPS5_LOG_FILE=<path>: it duplicates executable stdout/stderr to an append-only file, without filename expansion. It does not collect relinker output or separate trace files. Opening failure stops startup with status 1; there is no size limit. Reviewed main adds ANYPS5_HOST_REPORT=1 after GPU selection, including a report before a missing-feature failure. Review paths and title output before sharing logs; redaction is not a guarantee. A missing-feature list diagnoses that device/build, not whole-game compatibility.

Other reviewed-main policies remain opt-in: ANYPS5_FREE_SPACE=host checks the save volume when creating a new save; fixed is the default and console behavior is unmeasured. A default-sized 16384-block save needs 1 GiB. APS5_GAME_MODE=on/auto requests host performance mode, off by default; a request is not a measured speed gain. ANYPS5_PSN_DIALOGS=show adds a host notice while retaining the same cancellation result, not PSN access. Record each policy and keep real save/load tests separate.

Local run reports and missing milestones

v0.1.5 writes anyps5-report.json locally at supported exits. A kill, crash or abort can leave no file. Windows requires guest exit or _exit in this release, and Windows/Linux omit the loaded and started milestones. Review the file before sharing it. A submitted frame can still be black, and the report does not detect mixed library builds.

Check the game’s resource layout before renderer diagnosis

A converted executable does not guarantee a complete game layout. Astro Bot’s latest report restores missing args.txt and app0/data mapping without changing code; Sea of Stars and Smurfs reports restore files hidden in a repack. Compare with your own original title layout and preserve originals. Do not copy another title’s command line or treat promotional images, present counts or resource-audit success as gameplay validation. Version/environment details still belong to each report.

Optional Linux dependency omission has narrow conditions

Main’s --omit-unavailable-dependencies omits only an unavailable bundled dependency with no imports, no converted provider and no copy in any --rpath directory. All those directories must exist during conversion. Without the flag the dependency remains and is noted. Use it only with all system libraries already in rpath: an omitted library found later through LD_LIBRARY_PATH will not load. This is not permission to discard real imports or a universal startup fix.

List only add-ons included in your copy

Later main reads anyps5-entitlements.ini beside the executable, or the ANYPS5_ENTITLEMENTS path: one included add-on label per line, up to 16 characters; # and ; begin comments. Unlisted labels are reported not installed. Some titles wait rather than proceed without an expected add-on. A loading spinner alone does not identify missing data, and declaring a label neither supplies content nor proves a DLC test. Keep this source behavior separate from v0.1.4.

Trace the actual host module name

With --trace-imports, later main labels an import lacking a library name by the host module containing its function, such as libSceAvPlayer.native. Select that filename in APS5_TRACE_CALLS rather than a guest alias. Trace collection, a clean audit and a missing error are diagnostics; preserve actual build, platform and reached scene before claiming a fix.

Check the Linux allocator and library path

With APS5_MIMALLOC set in v0.1.5, the runtime restarts with libs/libmimalloc.so in LD_PRELOAD. Missing libraries, spaces or colons in the library path leave the system allocator active. The preload also reaches child processes. When comparing results, record the actual allocator and host memory headroom alongside FPS.

Linux converter and libraries have different minimums

Check the library build as well as the Linux converter. Current main documents glibc 2.38+ and GCC 13+ libstdc++ (GLIBCXX_3.4.31), but the published v0.1.4 and v0.1.5 prx-linux archives require glibc 2.43. A newer source-build minimum does not change those older binaries. The static relinker can start on an older system even when its runtime libraries cannot load. Check ldd --version before treating a GLIBC version error as a game failure; do not mix libraries from different builds.

Original sources

Related guides