forums.ps2dev.org Forum Index forums.ps2dev.org
Homebrew PS2, PSP & PS3 Development Discussions
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

i dont understand my error log

 
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development
View previous topic :: View next topic  
Author Message
S4LVAT10N



Joined: 27 Dec 2009
Posts: 16

PostPosted: Mon Dec 28, 2009 8:05 am    Post subject: i dont understand my error log Reply with quote

C:\PSPSDK\MYPROJ~1\SALVAT~1>make
psp-gcc -I. -IC:/pspsdk/psp/sdk/include -O2 -G0 -Wall -D_PSP_FW_VERSION=
-o main.o main.c
main.c:8:2: error: invalid preprocessing directive #inlcude
main.c: In function 'main':
main.c:79: error: 'O_RDONLY' undeclared (first use in this function)
main.c:79: error: (Each undeclared identifier is reported only once
main.c:79: error: for each function it appears in.)
main.c:93:1: warning: "PATH" redefined
main.c:84:1: warning: this is the location of the previous definition
main.c:102:1: warning: "PATH" redefined
main.c:93:1: warning: this is the location of the previous definition
main.c:111:1: warning: "PATH" redefined
main.c:102:1: warning: this is the location of the previous definition
main.c:120:1: warning: "PATH" redefined
main.c:111:1: warning: this is the location of the previous definition
main.c:129:1: warning: "PATH" redefined
main.c:120:1: warning: this is the location of the previous definition
main.c:138:1: warning: "PATH" redefined
main.c:129:1: warning: this is the location of the previous definition
MAKE: *** [main.o] Error 1

whats it mean by " invalid preprocessing directive #inlcude"?
and why isnt O_WRONLY or any other of the commands working?

btw the include is #include <pspiofilemgr.h>
Back to top
View user's profile Send private message
cheriff
Regular


Joined: 23 Jun 2004
Posts: 262
Location: Sydney.au

PostPosted: Mon Dec 28, 2009 8:34 am    Post subject: Re: i dont understand my error log Reply with quote

Quote:
whats it mean by "invalid preprocessing directive #inlcude
Just that, ie inlcude is not a valid #directive for the preprocessor.

Quote:
btw the include is #include <pspiofilemgr.h>
I think you'll find that's what it should be, not what you've actually written.

Read the error again:
Quote:
main.c:8:2: error: invalid preprocessing directive #inlcude


inLCude and inCLude are two different words.


NB: Editors with syntax highlighting are very useful: "Why didnt my #inlcude change to the colour of all other preprocessor commands?" "Oright, I typoed it" *fix*
_________________
Damn, I need a decent signature!
Back to top
View user's profile Send private message
S4LVAT10N



Joined: 27 Dec 2009
Posts: 16

PostPosted: Mon Dec 28, 2009 9:00 am    Post subject: Reply with quote

lol ya i just figured that out. thanks. i type to fast and dont look at what im typing so i mess up alot

EDIT: its still saying O_WRONLY and O_CREAT are undeclared...
Back to top
View user's profile Send private message
arnie



Joined: 11 Apr 2009
Posts: 16

PostPosted: Mon Dec 28, 2009 1:18 pm    Post subject: Reply with quote

1. Read Slowly
2. Type Slowly
3. Think Slowly
4. #include slowly
5. Set PATH slowly
6. Read carefully
7. Type carefully
8. Think carefully
9. #include carefully
10. Set PATH carefully

-arnie
Back to top
View user's profile Send private message
coyotebean



Joined: 05 Dec 2009
Posts: 26

PostPosted: Mon Dec 28, 2009 3:09 pm    Post subject: Reply with quote

S4LVAT10N wrote:
lol ya i just figured that out. thanks. i type to fast and dont look at what im typing so i mess up alot

EDIT: its still saying O_WRONLY and O_CREAT are undeclared...


Undeclared means undeclared, period.
Common mistake: typo & missing include or define/enum etc.
Compiling error indicates your code is syntactically incorrect.
Back to top
View user's profile Send private message
S4LVAT10N



Joined: 27 Dec 2009
Posts: 16

PostPosted: Mon Dec 28, 2009 11:28 pm    Post subject: Reply with quote

lol arnie path is suppose to be like that. it continuosuly changes but i wanted it like that and it works fine. im just trying to add a log to my program and last time i checked you dont need to declare O_CREAT or O_WRONLY....
Back to top
View user's profile Send private message
ne0h



Joined: 21 Feb 2008
Posts: 386

PostPosted: Tue Dec 29, 2009 3:47 am    Post subject: Reply with quote

S4LVAT10N, you basically have to know how to write down a C programm for PC, that's a PSP Development forum, not a C programming forum...
Sorry,

ne0h
_________________
Get Xplora!
Back to top
View user's profile Send private message
S4LVAT10N



Joined: 27 Dec 2009
Posts: 16

PostPosted: Tue Dec 29, 2009 5:30 am    Post subject: Reply with quote

but thats the thing. for the most part i could make decent programs for the pc. before i started trying to make a function that made a log on the psp i tested it first on the pc and it worked fine. when i did it on the psp i had not known you needed to have PSP in front. i kept doing O_WRONLY. after i relized i needed to do PSP_O_WRONLY and i already finished the log this morning. thought i do want to learn more on pc i am alot more interested in psp so i want to learn it first. even if it makes life harder for me.

btw the path redefined isnt an error. i want it like that and works the way i wanted it to
Back to top
View user's profile Send private message
arnie



Joined: 11 Apr 2009
Posts: 16

PostPosted: Tue Dec 29, 2009 11:48 pm    Post subject: Reply with quote

SALVATION,

To be honest, I did not understand your reply.

-arnie
Back to top
View user's profile Send private message
S4LVAT10N



Joined: 27 Dec 2009
Posts: 16

PostPosted: Wed Dec 30, 2009 1:26 am    Post subject: Reply with quote

sorry. i ment like in the error log it repeatedly said path redifined and i thought u thought that was an error and i was just saying i wanted it like that. that it wasnt an error
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development All times are GMT + 10 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group