mirror of
https://github.com/Thesola10/umd-livepatch.git
synced 2025-04-19 22:13:22 +00:00
tout cramer pour repartir sur des bases saines
This commit is contained in:
parent
bb4e6c7df6
commit
500cefcb69
3
.envrc
3
.envrc
@ -2,4 +2,7 @@ if ! has box_direnv_version || ! box_direnv_version 0.1.0; then
|
|||||||
source_url "https://raw.githubusercontent.com/thesola10/box-direnv/0.1.0/direnvrc" "sha256-pznp4/w7UzNAqreaLuGgq4/CTFjMedC376xnIWr5s+U="
|
source_url "https://raw.githubusercontent.com/thesola10/box-direnv/0.1.0/direnvrc" "sha256-pznp4/w7UzNAqreaLuGgq4/CTFjMedC376xnIWr5s+U="
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
source .env
|
||||||
|
export ARKROOT
|
||||||
|
|
||||||
use distrobox
|
use distrobox
|
||||||
|
39
Makefile
39
Makefile
@ -1,14 +1,33 @@
|
|||||||
TARGET = xdelta_umd
|
TARGET = umd_livepatch
|
||||||
OBJS = main.o
|
C_OBJS = main.o
|
||||||
LIBS =
|
OBJS = $(C_OBJS) imports.o
|
||||||
CFLAGS = -O2 -G0 -Wall -std=c99 -DCUSTOM_PATH
|
all: $(TARGET).prx
|
||||||
# -DKPRINTF_ENABLED
|
INCDIR = $(ARKROOT)/common/include $(ARKROOT)/core/systemctrl/include
|
||||||
CXXFLAGS = $(CFLAGS)
|
CFLAGS = -std=c99 -Os -G0 -Wall
|
||||||
ASFLAGS = $(CFLAGS)
|
|
||||||
|
|
||||||
USE_KERNEL_LIBC = 1
|
ifdef DEBUG
|
||||||
|
CFLAGS += -DDEBUG=$(DEBUG)
|
||||||
|
endif
|
||||||
|
|
||||||
|
LDFLAGS = -nostartfiles -L .
|
||||||
|
LIBS = -lpspsystemctrl_kernel
|
||||||
|
|
||||||
|
PSP_FW_VERSION = 660
|
||||||
|
|
||||||
|
PRX_EXPORTS = exports.exp
|
||||||
|
|
||||||
|
BUILD_PRX=1
|
||||||
USE_KERNEL_LIBS=1
|
USE_KERNEL_LIBS=1
|
||||||
|
USE_KERNEL_LIBC=1
|
||||||
|
|
||||||
PSP_FW_VERSION = 500
|
include $(ARKROOT)/common/make/global.mak
|
||||||
PSPSDK = $(shell psp-config --pspsdk-path)
|
PSPSDK = $(shell psp-config --pspsdk-path)
|
||||||
include $(PSPSDK)/lib/build_prx.mak
|
|
||||||
|
libpspsystemctrl_kernel.a:
|
||||||
|
$(MAKE) -C $(ARKROOT)/libs/SystemCtrlForKernel
|
||||||
|
cp $(ARKROOT)/libs/SystemCtrlForKernel/libpspsystemctrl_kernel.a .
|
||||||
|
|
||||||
|
$(TARGET).prx:: libpspsystemctrl_kernel.a
|
||||||
|
|
||||||
|
include $(PSPSDK)/lib/build.mak
|
||||||
|
include $(ARKROOT)/common/make/beauty.mak
|
||||||
|
22
exports.exp
Normal file
22
exports.exp
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
# Define the exports for the prx
|
||||||
|
PSP_BEGIN_EXPORTS
|
||||||
|
|
||||||
|
PSP_EXPORT_START(syslib, 0, 0x8000)
|
||||||
|
PSP_EXPORT_FUNC_HASH(module_start)
|
||||||
|
PSP_EXPORT_FUNC_HASH(module_stop)
|
||||||
|
PSP_EXPORT_VAR_HASH(module_info)
|
||||||
|
PSP_EXPORT_END
|
||||||
|
|
||||||
|
# Voluntary collision with Inferno to prevent conflicts
|
||||||
|
PSP_EXPORT_START(inferno_driver, 0x0011, 0x0001)
|
||||||
|
# inferno_driver_CF8299BE
|
||||||
|
PSP_EXPORT_FUNC(infernoSetDiscType)
|
||||||
|
# inferno_driver_C0736FD6
|
||||||
|
PSP_EXPORT_FUNC(infernoCacheSetPolicy)
|
||||||
|
# inferno_driver_8CDE7F95
|
||||||
|
PSP_EXPORT_FUNC(infernoCacheInit)
|
||||||
|
# inferno_driver_B6522E93
|
||||||
|
PSP_EXPORT_FUNC(infernoSetUmdDelay)
|
||||||
|
PSP_EXPORT_END
|
||||||
|
|
||||||
|
PSP_END_EXPORTS
|
9
imports.S
Normal file
9
imports.S
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
.set noreorder
|
||||||
|
|
||||||
|
#include "pspstub.s"
|
||||||
|
|
||||||
|
STUB_START "SysMemForKernel",0x00000011,0x00050005
|
||||||
|
STUB_FUNC 0xC7E57B9C,sceKernelSetQTGP3
|
||||||
|
STUB_FUNC 0xFC114573,sceKernelGetCompiledSdkVersion
|
||||||
|
STUB_FUNC 0xCF4DE78C,sceKernelGetUIDcontrolBlock
|
||||||
|
STUB_END
|
11
main.c
11
main.c
@ -29,4 +29,15 @@ int module_start(SceSize argc, void *argp)
|
|||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int module_stop(void)
|
||||||
|
{
|
||||||
|
Kprintf("Unloading UMD Livepatch.");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void infernoSetDiscType(void) {}
|
||||||
|
void infernoCacheSetPolicy(void) {}
|
||||||
|
void infernoCacheInit(void) {}
|
||||||
|
void infernoSetUmdDelay(void) {}
|
||||||
|
|
||||||
// vim: ft=c.doxygen
|
// vim: ft=c.doxygen
|
||||||
|
Loading…
x
Reference in New Issue
Block a user