Loading userspace PSP2 VELFs.
psp2cldr runs directly on arm32v7-linux
and thus also on aarch64
with CONFIG_COMPAT
kernels.
virt
platform with smp=4
and 4G
memory
Memory leak is under investigation #2.
arm-none-linux-gnueabihf
Make sure to use a recent release of qemu-arm
. (for the record, qemu-arm version 2.11.1
is not one of them).
Tested with qemu-arm version 6.1.0 (qemu-6.1.0-10.fc35)
.
via Docker
Memory leak is under investigation #2.
- Recommended, comes with a working CMake, GCC 10/11.
- CMake 3.16 has a bug that renders it unusable on armhf, you can either cross-compile (GNU Toolchain for the A-profile Architecture), build CMake 3.18 from source, or use the Kitware APT Repository (*had no luck though).
- Demonstrates we could run natively on
aarch64
.
psp2cldr also runs directly on arm64-windows
(not arm-uwp
) when compiled for the ARM
target (e.g., amd64_arm
, x86_arm
, arm64_arm
).
MSVC Redistributable for ARM
seems to be missing on arm64-windows
#4. Extracted runtime libraries can be found here.
- Display information of the supplied VELF
psp2cldr --readelf XXX.velf
- Load ELFs, and optionally VELFs (see usage via
psp2cldr -h
)
See Guide
See Sample
See psp2cldr Newlib OS Support Reference Implementation
psp2cldr provides a mechanism to load supplementary ELFs into the address space of the target. DT_NEEDED
tag is respected.
Supplementary ELFs need to be built for the target platform. A custom toolchain has been assembled to permit C
(newlib
pthread-embedded
) and C
library usages.
arm-vita-eabi-g -shared a.cc -o supp_elf.so
The following libraries need to be loaded from the toolchain,
libc.so
libm.so
libpthread.so
libgcc_s.so
libstdc .so
- Only
e_type == ET_SCE_RELEXEC
is supported, partly because in native mode we cannot enforce the binary to be loaded at an exact location. - Only relocation type
0
and1
are implemented. User VELFs tend to not use types2
to9
.
Installed automatically if not found
See Dockerfile
MIT