mirror of
https://github.com/wiiu-env/wut.git
synced 2025-01-10 00:09:24 +01:00
ee3bb10df4
- Added wut_rules and wut/rpx/rpl.specs to share/ - Replaced wut's CMake-based buildsystem with a standard Makefile - Conflated all wut libraries into a single libwut.a library - wut's old buildsystems (CMake & plain make) are broken as a result, this will be fixed in the future - Docs, tests and samples are not buildable either at the moment - wutcrt/wutnewlib: - RPX start function is __rpx_start, while RPL is __rpl_start - __init/fini_wut_* functions are no longer weak - __init_wut/__fini_wut are instead weak - Removed _exit implementation - exit syscall now points to _Exit instead of pointing to itself - wutstdc++: - Renamed .cc files to .cpp - Temporarily disabled, due to an issue that will be addressed shortly - wutdevoptab: - Fixed uninitialized variable warnings in __wut_fs_read/write
35 lines
459 B
ArmAsm
35 lines
459 B
ArmAsm
.extern main
|
|
.extern exit
|
|
.extern __init_wut
|
|
.extern __fini_wut
|
|
|
|
.global __rpl_start
|
|
__rpl_start:
|
|
stwu 1, -0x14(1)
|
|
mflr 0
|
|
stw 0, 0x18(1)
|
|
stw 3, 0xC(1)
|
|
stw 4, 0x10(1)
|
|
cmpwi 3, 2
|
|
beq unload
|
|
|
|
load:
|
|
# Load
|
|
bl __init_wut
|
|
bl __eabi
|
|
lwz 3, 0xC(1)
|
|
lwz 4, 0x10(1)
|
|
bl rpl_entry
|
|
addi 1, 1, 0x14
|
|
blr
|
|
|
|
unload:
|
|
# Handle unload
|
|
lwz 3, 0xC(1)
|
|
lwz 4, 0x10(1)
|
|
bl rpl_entry
|
|
bl __fini_wut
|
|
addi 1, 1, 0x14
|
|
b exit
|
|
|