mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-05-22 19:34:59 +00:00
printf implementation
This commit is contained in:
parent
cefd3d95ed
commit
551455e56e
6 changed files with 72 additions and 11 deletions
|
@ -5,6 +5,8 @@
|
|||
|
||||
#include "../Loader/Elf.h"
|
||||
#include "Libs.h"
|
||||
#include "Emulator/HLE/Libraries/LibC/libc.h"
|
||||
|
||||
|
||||
namespace HLE::Libs::LibC {
|
||||
|
||||
|
@ -86,11 +88,6 @@ static PS4_SYSV_ABI int atexit(void (*func)()) {
|
|||
}
|
||||
static PS4_SYSV_ABI void _Assert() { BREAKPOINT(); }
|
||||
|
||||
static PS4_SYSV_ABI int printf(const char* s) {
|
||||
puts(s);
|
||||
return 0; // not correct
|
||||
}
|
||||
|
||||
void LibC_Register(SymbolsResolver* sym) {
|
||||
LIB_FUNCTION("bzQExy189ZI", "libc", 1, "libc", 1, 1, init_env);
|
||||
LIB_FUNCTION("3GPpjQdAMTw", "libc", 1, "libc", 1, 1, __cxa_guard_acquire);
|
||||
|
@ -101,7 +98,7 @@ void LibC_Register(SymbolsResolver* sym) {
|
|||
LIB_FUNCTION("uMei1W9uyNo", "libc", 1, "libc", 1, 1, exit);
|
||||
LIB_FUNCTION("8G2LB+A3rzg", "libc", 1, "libc", 1, 1, atexit);
|
||||
LIB_FUNCTION("-QgqOT5u2Vk", "libc", 1, "libc", 1, 1, _Assert);
|
||||
LIB_FUNCTION("hcuQgD53UxM", "libc", 1, "libc", 1, 1, printf);
|
||||
LIB_FUNCTION("hcuQgD53UxM", "libc", 1, "libc", 1, 1, Emulator::HLE::Libraries::LibC::printf);
|
||||
|
||||
LIB_OBJ("P330P3dFF68", "libc", 1, "libc", 1, 1, &HLE::Libs::LibC::g_need_sceLibc);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue