sceKernelLoadExec fails with 8002013A on 3.52 M33

Discuss the development of new homebrew software, tools and libraries.

Moderators: cheriff, TyRaNiD

Post Reply
skillz4fun
Posts: 2
Joined: Thu Oct 04, 2007 2:36 am

sceKernelLoadExec fails with 8002013A on 3.52 M33

Post by skillz4fun »

If i call sceKernelLoadExec() in a kernel mode prx on 3.52 M33 it fails with 8002013A (Library not linked yet).

The Makefile for the prx looks like that:

Code: Select all

TARGET = helper
OBJS = main.o

PSP_FW_VERSION = 352

BUILD_PRX = 1
PRX_EXPORTS = exports.exp

USE_KERNEL_LIBC = 1
USE_KERNEL_LIBS = 1

CFLAGS = -O2 -G0 -Wall
CXXFLAGS = $(CFLAGS) -fno-exceptions -fno-rtti
ASFLAGS = $(CFLAGS)
LDFLAGS = -mno-crt0 -nostartfiles

PSPSDK=$(shell psp-config --pspsdk-path)
include $(PSPSDK)/lib/build.mak
Which library must be linked additional to it?
J.F.
Posts: 2906
Joined: Sun Feb 22, 2004 11:41 am

Post by J.F. »

You don't give nearly enough info to answer the question. What lib are you trying to load? Why are you even trying to load it? Why are you using that method of loading?
skillz4fun
Posts: 2
Joined: Thu Oct 04, 2007 2:36 am

Post by skillz4fun »

Ok.
It's a kernel prx module loaded by an user mode running application.
I need a kernel mode modul to start another EBOOT.PBP from memory stick.

my test code is:

Code: Select all

#include <pspkernel.h>
#include <psploadexec.h>

PSP_MODULE_INFO&#40;"name", 0x1006, 1, 1&#41;;
PSP_MAIN_THREAD_ATTR&#40;0&#41;;

/*
Function called by Main-Application to run another EBOOT.PBP
"i" is a test return value.
*/

int retval&#40;int * i&#41;
&#123;
	const char * tmp = "ms0&#58;/PSP/GAME/OTHER/EBOOT.PBP";

	struct SceKernelLoadExecParam EBOOTPBP;

	EBOOTPBP.args = strlen&#40;tmp&#41;+1;
	EBOOTPBP.argp = tmp;
	EBOOTPBP.key = NULL;
	EBOOTPBP.size = sizeof&#40;EBOOTPBP&#41;+strlen&#40;tmp&#41;+1;
	// "i" contains 0x8002013A after the following call&#58;
	*i = sceKernelLoadExec&#40;tmp,&EBOOTPBP&#41;;
	
	return 0;
&#125;

int module_start&#40;SceSize args, void *argp&#41;
&#123;
	return 0;
&#125;

int module_stop&#40;SceSize args, void *argp&#41;
&#123;
	return 0;
&#125;
Post Reply