Discuss the development of new homebrew software, tools and libraries.
Moderators: cheriff , TyRaNiD
b-k24
Posts: 6 Joined: Sun Oct 26, 2008 1:45 am
Post
by b-k24 » Sun Oct 26, 2008 2:15 am
so i redid my pc coz itz vid driver got corrupted so i reinstalled the osilb pspdev kit and tried to compile my soucre didnt work thought it was a problem with my code so i decide to compile a simple hello world code by psdonkey but it still wouldnt compile a simple hello world source it gave me this...
//OSlib header file
#include <oslib/oslib.h>
//callbacks
PSP_MODULE_INFO("OSLib Sample", 0, 1, 1);
PSP_MAIN_THREAD_ATTR(THREAD_ATTR_USER | THREAD_ATTR_VFPU);
int main()
{
//Initialization of the Oslib library
oslInit(0);
//Initialization of the graphics mode
oslInitGfx(OSL_PF_8888, 0);
//Initialization of the text console
oslInitConsole();
//Print on the screen this text
oslPrintf("Hello World");
//Wait for a button to be pressed
oslWaitKey();
//terminate the program
oslEndGfx();
oslQuit();
return 0;
}
Onii
Posts: 40 Joined: Sun Oct 05, 2008 1:07 pm
Post
by Onii » Sun Oct 26, 2008 2:36 am
This is not psp related. This is BASIC programming. Your compiler can't find your include file.
The very first error says that it can't find oslib.h.
Pirata Nervo
Posts: 409 Joined: Tue Oct 09, 2007 4:22 am
Post
by Pirata Nervo » Sun Oct 26, 2008 3:17 am
You did not install Oslib.
Make sure you include a blank line at the end too
Upgrade your
PSP
b-k24
Posts: 6 Joined: Sun Oct 26, 2008 1:45 am
Post
by b-k24 » Sun Oct 26, 2008 4:45 am
i did install the oslib to the specified dir...this isnt the first time i installed it on my pc..i also tried uninstalling and reinstalling but it still fails to find the library
what do i need to do? jus copy the oslib.h/OSlib.lib into the C:\pspdev\psp\sdk\include dir
Onii
Posts: 40 Joined: Sun Oct 05, 2008 1:07 pm
Post
by Onii » Sun Oct 26, 2008 11:09 am
Add the include paths for osl to your makefile.
EDIT: While we're at it you will need to add the osl library to your makefile too if it's not already there.
Dariusc123456
Posts: 388 Joined: Tue Aug 12, 2008 12:46 am
Post
by Dariusc123456 » Sun Oct 26, 2008 12:48 pm
Onii wrote: Add the include paths for osl to your makefile.
EDIT: While we're at it you will need to add the osl library to your makefile too if it's not already there.
When its installed, it dont need to be on the makefile, unless you dont have it in the include folder. Then you do what you need todo.