Include errors

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

Moderators: cheriff, TyRaNiD

Post Reply
Zeno
Posts: 3
Joined: Mon Jun 27, 2005 2:09 pm
Location: Saratoga, NY
Contact:

Include errors

Post by Zeno »

Slightly new to PSPdev. I'm attempting to port something to PSP just to see how it goes, and I've got to this point:

Code: Select all

$ make
psp-gcc -c -Wall -pedantic socket.c
In file included from /usr/local/pspdev/psp/lib/gcc/psp/4.0.0/../../../../psp/in
clude/sys/socket.h:15,
                from socket.c:10:
/usr/local/pspdev/psp/lib/gcc/psp/4.0.0/../../../../psp/include/cygwin/socket.h:
30: error: parse error before '__uid32_t'
In file included from /usr/local/pspdev/psp/lib/gcc/psp/4.0.0/../../../../psp/sy
s-include/unistd.h:4,
                from socket.c:15:
/usr/local/pspdev/psp/lib/gcc/psp/4.0.0/../../../../psp/sys-include/sys/unistd.h
: In function '__declspec':
/usr/local/pspdev/psp/lib/gcc/psp/4.0.0/../../../../psp/sys-include/sys/unistd.h
These are include files. Any idea what would be wrong?
User avatar
Agoln
Posts: 326
Joined: Wed Jun 08, 2005 3:14 am
Location: Fort Wayne, IN

Post by Agoln »

It included the files correctly... read this

Code: Select all

/usr/local/pspdev/psp/lib/gcc/psp/4.0.0/../../../../psp/include/cygwin/socket.h:
30: error: parse error before '__uid32_t' 
You have a parse error right there. Check out the code at that point or google it... maybe it's something known. The other stuff is to just let you know how the compiler got to that point.
Zeno
Posts: 3
Joined: Mon Jun 27, 2005 2:09 pm
Location: Saratoga, NY
Contact:

Post by Zeno »

Yes I saw that and that's what I'm asking about. The include files are fine... never changed. But I'll post the line here/look at the line in socket.h
crazyc
Posts: 408
Joined: Fri Jun 17, 2005 10:13 am

Post by crazyc »

Including cygwin's socket.h (assuming that is what you are doing) will do you no good as there is no socket implementation for the psp yet.
PspPet
Posts: 210
Joined: Wed Mar 30, 2005 2:13 am
Contact:

Post by PspPet »

> Including cygwin's socket.h (assuming that is what you are doing) will do you no good ....
True.

> ...as there is no socket implementation for the psp yet.
FWIW: the "sceNetInet" library is very very similar to Berkeley sockets

#define socket sceNetInetSocket
#define sendto sceNetInetSendto
... [you get the point]
http://pspdev.ofcode.com/api.php?type=2&id=201

The "sockaddr" and other types are a little non-standard, but very close.
So if you need socket.h for porting your app, the future looks promising. For now, remove the header.
Zeno
Posts: 3
Joined: Mon Jun 27, 2005 2:09 pm
Location: Saratoga, NY
Contact:

Post by Zeno »

I figured it'd be something like that. Alright time to find another project to port.
Post Reply