chicken-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Chicken-users] Patch to add Sony PSP support


From: Adam King
Subject: [Chicken-users] Patch to add Sony PSP support
Date: Tue, 25 Mar 2008 21:16:19 -0400

Hi All:

  I needed to add a scheme compiler/interpreter to a psp project I'm
working on, and after trying a few, Chicken seemed to offer the best
set of features I was looking for.  So, I've attached a patch against
the latest svn version to add psp support.  It makes a few minor
changes to some scm files and adds a new posixpsp.scm file (which is
mostly a copy of posixunix.scm for now.  The free, open source psp dev
toolkit ( http://pspdev.org ) is mostly posix compatible - though I'll
need to add some psp specific stuff).   To test it, I compiled
r4rstest.scm as embedded and included it in a simple psp specific
main.c(attached), the output of which I've also attached for anyone
curious (it ran directly on my psp through psplink).   It is cross
compiled under gentoo linux.

Anyways, I'll keep on working on it - and feedback is welcome.  Cheers,

  Adam (aka: zilt)

P.S.  Here's how I compiled r4rstest.scm (note: I don't know why it's
trying to make an executable when specifying the "-e" option - though
since it does create r4rstest.o before it dies, it doesn't really
matter).  See attached psp-r4trstest.out for the psplink session and
output :

address@hidden /tmp/tt $ psp-csc -e r4rstest.scm
Warning: redefinition of extended binding `first'
Warning: redefinition of standard binding `+'
Warning: redefinition of standard binding `+'
/usr/local/pspdev/lib/gcc/psp/4.1.0/../../../../psp/bin/ld: cannot find -ldl
collect2: ld returned 1 exit status
*** Shell command terminated with exit status 1: psp-gcc r4rstest.o -o
r4rstest -L/usr/local/pspdev/lib  -Wl,-R/usr/local/pspdev/lib
-lchicken -lm -ldl

address@hidden /tmp/tt $ file r4rstest.o
r4rstest.o: ELF 32-bit LSB relocatable, MIPS, MIPS-II version 1 (SYSV)

address@hidden /tmp/tt $ make
psp-gcc -I/usr/local/pspdev/include -I.
-I/usr/local/pspdev/psp/sdk/include -G0 -Wall -D_PSP_FW_VERSION=350
-L/usr/local/pspdev/lib -L. -L/usr/local/pspdev/psp/sdk/lib   main.o
r4rstest.o -lm -lchicken -lm -lpspdebug -lpspdisplay -lpspge -lpspctrl
-lpspsdk -lc -lpspnet -lpspnet_inet -lpspnet_apctl -lpspnet_resolver
-lpsputility -lpspuser -lpspkernel -o chick.elf
psp-fixup-imports chick.elf
mksfo 'test' PARAM.SFO
psp-strip chick.elf -o chick_strip.elf
pack-pbp EBOOT.PBP PARAM.SFO NULL  \
                NULL NULL NULL  \
                NULL  chick_strip.elf NULL
[0]        408 bytes | PARAM.SFO
[1]          0 bytes | NULL
[2]          0 bytes | NULL
[3]          0 bytes | NULL
[4]          0 bytes | NULL
[5]          0 bytes | NULL
[6]    1560552 bytes | chick_strip.elf
[7]          0 bytes | NULL
rm -f chick_strip.elf

Attachment: psp-chicken.patch
Description: Binary data

Attachment: psp-r4rstest.out
Description: Binary data

Attachment: main.c
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]