Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > More E-Book Readers > iRex > iRex Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 05-25-2009, 11:46 PM   #1
pwarren
Connoisseur
pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.
 
Posts: 95
Karma: 186186
Join Date: May 2009
Location: Canberra, Australia
Device: Irex Iliad (Dead), EcoReader (Smashed screen), Kobo Touch
My iliad porting adventures!

Part 1. GnuShogi

allrighty, got myself all set up with the official toolchain, and set about making gnushogi compile for the iliad, I've been successful, but I've no way to test it at the moment, as my iliad has not yet arrived!

So, what I had to do:

first step, obviously, was to find the source to gnushogi, easy enough as it's a GNU package:

http://www.cs.caltech.edu/~mvanier/h...i-1.3.2.tar.gz

So, naively, I try a ./configure --host=arm-linux, and it starts complaining about not being able to detect the build architecture, ./configure --host=arm-linux --build=i686 fixes that no worries!

so, it needs libXaw, hrm. this could be fun!

Turns out that libXaw needs a bunch of things: Xext, Xextproto, printproto, Xpm, Xmu. Which are found easily enough on freedekstop.org

Some of them are tricky to comiple. Xext being one of them, you have to edit the configure script at line 20405, so that it doesn't exit when it finds you're cross compiling and can't determine the output of malloc. I think another way to get out of this is to do:

Code:
$ export ac_cv_func_malloc_0_nonnull=yes
which is required for libXmu anyway.


Then once all that's compiled and installed, gnushogi still doesn't compile, as it doesn't tell arm-linux-gcc where the library and header files are, but type in make and wait for it to break, then:

Code:
cd xshogi
arm-linux-gcc -c xshogi.c -Wall -Wno-implicit-int -Wstrict-prototypes -ansi -pedantic -g -O2 -fsigned-char -funroll-loops   -I..      -DFIRST_SHOGI_PROGRAM=\"gnushogi\" -DSECOND_SHOGI_PROGRAM=\"gnushogi\"     -DFIRST_HOST=\"localhost\" -DSECOND_HOST=\"localhost\" -I/path to/where/you/installed/stuff
cd ..
and tell gcc where the include files are, with the final -I argument. Then try make again, which breaks again! We find that the makefile doesn't tell gcc where the libraries are kept, so similar idea to the above:

Code:
cd xshogi
arm-linux-gcc -o xshogi xshogi.o parser.o -g -O2 -fsigned-char -funroll-loops -I.. -lXaw -lXmu -lXt -lXext -lX11 -lXpm -L/home/pwarren/gnushogi/lib/ -L/usr/local/arm/oe/arm-linux/lib
CD ..
so, add in where you installed stuff to, and and the '-lXpm' argument as well.

Then it should compile properly!


Next is the install, the Makefile tries to strip the binaries when installing, so you have to either:

Code:
alias strip='arm-linux-strip'
or edit the gnushogi/Makefile and xshogi/Makefile. And then you should be able to make install!

So there we have it, and I have compiled xshogi for the iliad, I'll attach a tar.gz wiith the compiled libraries and binaries to this thread.

Not sure what to do for my next trick, but I'll think of something
Attached Files
File Type: gz iliad-gnushogi.tar.gz (5.05 MB, 408 views)

Last edited by pwarren; 05-26-2009 at 01:06 AM.
pwarren is offline   Reply With Quote
Old 05-26-2009, 03:24 AM   #2
ericshliao
Guru
ericshliao will become famous soon enoughericshliao will become famous soon enoughericshliao will become famous soon enoughericshliao will become famous soon enoughericshliao will become famous soon enoughericshliao will become famous soon enough
 
Posts: 976
Karma: 687
Join Date: Nov 2007
Device: Dell X51v; iLiad v2
Some advice:
iLiad needs dedicated screen-refreshment mechanism. If you didn't modify the source code of gnushogi or use a patched X lib, you'll need Antartica's xepdmgr to control screen-refreshment.
ericshliao is offline   Reply With Quote
Advert
Old 05-26-2009, 03:56 AM   #3
pwarren
Connoisseur
pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.
 
Posts: 95
Karma: 186186
Join Date: May 2009
Location: Canberra, Australia
Device: Irex Iliad (Dead), EcoReader (Smashed screen), Kobo Touch
Well, I've not done anything except get it to compile, no modifications at all

So, I thought running it with xepdmgr would be the ticket. I'll be able to play more once my iliad gets here
pwarren is offline   Reply With Quote
Old 05-26-2009, 09:37 PM   #4
pwarren
Connoisseur
pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.pwarren can program the VCR without an owner's manual.
 
Posts: 95
Karma: 186186
Join Date: May 2009
Location: Canberra, Australia
Device: Irex Iliad (Dead), EcoReader (Smashed screen), Kobo Touch
As an aside, is there a list of functions that'll need to be changed to work with the iliad sans xepdmgr or hacked Xlib?
pwarren is offline   Reply With Quote
Reply

Tags
gnushogi, iliad, shogi


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
DR800 porting iLiad games to dr800 Mohammad Reza iRex 7 09-16-2010 05:21 AM
Porting or new Funtionality fabiocbr75 iRex 18 09-21-2009 10:24 AM
iLiad Books about porting? Luka Trifunovic iRex Developer's Corner 0 03-20-2008 12:22 AM
iLiad Porting Mono (.net) to Iliad thaoula iRex Developer's Corner 2 12-18-2007 02:56 AM
iLiad Porting old games to the iLiad HarryT iRex Developer's Corner 7 08-19-2007 11:40 AM


All times are GMT -4. The time now is 05:37 PM.


MobileRead.com is a privately owned, operated and funded community.