[GH-ISSUE #979] Failed to compile on aarch64 #298

Closed
opened 2026-02-27 21:05:35 +03:00 by kerem · 5 comments
Owner

Originally created by @xoureldeen on GitHub (Sep 19, 2024).
Original GitHub issue: https://github.com/shadps4-emu/shadPS4/issues/979

i used this lines to build

  1. cmake -S . -B build/ -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++
  2. cmake --build . --config Release --parallel

and i got this
[ 89%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/recompiler.cpp.o [ 89%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_atomic.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_barriers.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_bitwise_conversion.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_composite.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_context_get_set.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_convert.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_floating_point.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_image.cpp.o /root/shadPS4/src/core/signals.cpp:62:2: error: "Missing IS_WRITE_ERROR() implementation for target OS and CPU architecture." 62 | #error "Missing IS_WRITE_ERROR() implementation for target OS and CPU architecture." | ^ /root/shadPS4/src/core/signals.cpp:93:26: error: use of undeclared identifier 'CODE_ADDRESS' 93 | auto* code_address = CODE_ADDRESS(ctx); | ^ /root/shadPS4/src/core/signals.cpp:98:35: error: use of undeclared identifier 'IS_WRITE_ERROR' 98 | if (const bool is_write = IS_WRITE_ERROR(ctx); | ^ 3 errors generated. gmake[2]: *** [CMakeFiles/shadps4.dir/build.make:1476: CMakeFiles/shadps4.dir/src/core/signals.cpp.o] Error 1 gmake[2]: *** Waiting for unfinished jobs....

Originally created by @xoureldeen on GitHub (Sep 19, 2024). Original GitHub issue: https://github.com/shadps4-emu/shadPS4/issues/979 i used this lines to build 1. cmake -S . -B build/ -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ 2. cmake --build . --config Release --parallel and i got this `[ 89%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/recompiler.cpp.o [ 89%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_atomic.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_barriers.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_bitwise_conversion.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_composite.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_context_get_set.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_convert.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_floating_point.cpp.o [ 90%] Building CXX object CMakeFiles/shadps4.dir/src/shader_recompiler/backend/spirv/emit_spirv_image.cpp.o /root/shadPS4/src/core/signals.cpp:62:2: error: "Missing IS_WRITE_ERROR() implementation for target OS and CPU architecture." 62 | #error "Missing IS_WRITE_ERROR() implementation for target OS and CPU architecture." | ^ /root/shadPS4/src/core/signals.cpp:93:26: error: use of undeclared identifier 'CODE_ADDRESS' 93 | auto* code_address = CODE_ADDRESS(ctx); | ^ /root/shadPS4/src/core/signals.cpp:98:35: error: use of undeclared identifier 'IS_WRITE_ERROR' 98 | if (const bool is_write = IS_WRITE_ERROR(ctx); | ^ 3 errors generated. gmake[2]: *** [CMakeFiles/shadps4.dir/build.make:1476: CMakeFiles/shadps4.dir/src/core/signals.cpp.o] Error 1 gmake[2]: *** Waiting for unfinished jobs.... `
kerem closed this issue 2026-02-27 21:05:35 +03:00
Author
Owner

@squidbus commented on GitHub (Sep 19, 2024):

  • If this is Linux there's some parts that are not yet implemented to compile on Linux ARM64.
  • Regardless, the emulator does not function at all on ARM64 yet. There's an experimental branch to embed and use Box64 on macOS but nothing other than that. You should run the x86_64 version under a translation layer instead.
<!-- gh-comment-id:2359938213 --> @squidbus commented on GitHub (Sep 19, 2024): * If this is Linux there's some parts that are not yet implemented to compile on Linux ARM64. * Regardless, the emulator does not function at all on ARM64 yet. There's an experimental branch to embed and use Box64 on macOS but nothing other than that. You should run the x86_64 version under a translation layer instead.
Author
Owner

@xoureldeen commented on GitHub (Sep 19, 2024):

  • If this is Linux there's some parts that are not yet implemented to compile on Linux ARM64.
  • Regardless, the emulator does not function at all on ARM64 yet. There's an experimental branch to embed and use Box64 on macOS but nothing other than that. You should run the x86_64 version under a translation layer instead.

Thanks for replying, i tried fex rootfs and when i run qt version it crashes my x11 display, and cli one always i get this
root@localhost:# ./shadps4 /storage/emulated/0/Download/UP4433-CUSA00744_00-MINECRAFTPS40000-A0100-V0102.pkg
terminate called after throwing an instance of 'std::bad_alloc' what(): std::bad_alloc
Aborted root@localhost:
#

i tried elf and EBOOT.BIN
from ps4/ps3 dumped games
nothing work

<!-- gh-comment-id:2360638748 --> @xoureldeen commented on GitHub (Sep 19, 2024): > * If this is Linux there's some parts that are not yet implemented to compile on Linux ARM64. > * Regardless, the emulator does not function at all on ARM64 yet. There's an experimental branch to embed and use Box64 on macOS but nothing other than that. You should run the x86_64 version under a translation layer instead. Thanks for replying, i tried fex rootfs and when i run qt version it crashes my x11 display, and cli one always i get this root@localhost:~# ./shadps4 /storage/emulated/0/Download/UP4433-CUSA00744_00-MINECRAFTPS40000-A0100-V0102.pkg terminate called after throwing an instance of 'std::bad_alloc' what(): std::bad_alloc Aborted root@localhost:~# i tried elf and EBOOT.BIN from ps4/ps3 dumped games nothing work
Author
Owner

@squidbus commented on GitHub (Sep 19, 2024):

No idea if it works under FEX, but there's definitely no ARM64 native support yet.

<!-- gh-comment-id:2360645973 --> @squidbus commented on GitHub (Sep 19, 2024): No idea if it works under FEX, but there's definitely no ARM64 native support yet.
Author
Owner

@xoureldeen commented on GitHub (Sep 21, 2024):

sorry for annoying, what the cause of this error
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'
Saving new configuration file /root/squashfs-root/user/config.toml
[Loader] emulator.cpp:Emulator:52: Starting shadps4 emulator v0.2.0
[Loader] emulator.cpp:Emulator:53: Revision da9b26fa1e
[Loader] emulator.cpp:Emulator:54: Branch main
[Loader] emulator.cpp:Emulator:55: Description da9b26f
[Kernel.Vmm] address_space.cpp:Impl:313: mmap failed: Cannot allocate memory
terminate called after throwing an instance of 'std::bad_alloc'
what(): std::bad_alloc
Aborted

<!-- gh-comment-id:2365168544 --> @xoureldeen commented on GitHub (Sep 21, 2024): sorry for annoying, what the cause of this error QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root' Saving new configuration file /root/squashfs-root/user/config.toml [Loader] <Info> emulator.cpp:Emulator:52: Starting shadps4 emulator v0.2.0 [Loader] <Info> emulator.cpp:Emulator:53: Revision da9b26fa1e0a4b9e34dd9f08e7632676c7bfee9a [Loader] <Info> emulator.cpp:Emulator:54: Branch main [Loader] <Info> emulator.cpp:Emulator:55: Description da9b26f [Kernel.Vmm] <Critical> address_space.cpp:Impl:313: mmap failed: Cannot allocate memory terminate called after throwing an instance of 'std::bad_alloc' what(): std::bad_alloc Aborted
Author
Owner

@Hermiten commented on GitHub (Oct 1, 2024):

I'm closing this issue because this is not planned for now.
Concerning the last issue, you can search on the issues or open a new one.
Thanks you

<!-- gh-comment-id:2387084726 --> @Hermiten commented on GitHub (Oct 1, 2024): I'm closing this issue because this is not planned for now. Concerning the last issue, you can search on the issues or open a new one. Thanks you
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/shadPS4#298
No description provided.