Register Guidelines E-Books Search Today's Posts Mark Forums Read

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

Notices

Reply
 
Thread Tools Search this Thread
Old 04-05-2007, 05:44 AM   #31
mtas
Enthusiast
mtas doesn't littermtas doesn't litter
 
Posts: 42
Karma: 145
Join Date: Oct 2006
Device: iLiad
Quote:
Originally Posted by Oskar Wahlberg
Just thought I should inform that the VMware image also works fine with VMware Fusion ( beta ) running under mac os x. I guess it would be possible to get the toolchain to run natively but the image with a ready dev env was very nice.

Is there any sample apps with code or "howto's" that I can download and compile to make sure it all works ok before I dev my own stuff?

Thanx for taking the time to putting it together and making it available to us all.
Hey Oskar, are you the one I think you are?
Mats Söderlind
mtas is offline   Reply With Quote
Old 04-05-2007, 06:26 AM   #32
Mambo
Gadget fan
Mambo can teach chickens to fly.Mambo can teach chickens to fly.Mambo can teach chickens to fly.Mambo can teach chickens to fly.Mambo can teach chickens to fly.Mambo can teach chickens to fly.Mambo can teach chickens to fly.Mambo can teach chickens to fly.Mambo can teach chickens to fly.Mambo can teach chickens to fly.Mambo can teach chickens to fly.
 
Posts: 147
Karma: 3968
Join Date: Sep 2006
Location: London
Device: RM Tablet PC, iLiad, PRS 505, iPod Touch
Quote:
Originally Posted by Oskar Wahlberg
Just thought I should inform that the VMware image also works fine with VMware Fusion ( beta ) running under mac os x. I guess it would be possible to get the toolchain to run natively but the image with a ready dev env was very nice.

Is there any sample apps with code or "howto's" that I can download and compile to make sure it all works ok before I dev my own stuff?

Thanx for taking the time to putting it together and making it available to us all.
Yeah a howto would be great. I tried to follow what is in the wiki but stuck at the "dl-and-install.sh" part or something. This command was not recognised by the system. I suppose I could figure out the rest if someone could write a walkthrough from getting the code up to saving the compiled executable to the iliad.
Mambo is offline   Reply With Quote
Old 04-05-2007, 07:08 AM   #33
yokos
Pac-Man catched my iLiad.
yokos plays well with othersyokos plays well with othersyokos plays well with othersyokos plays well with othersyokos plays well with othersyokos plays well with othersyokos plays well with othersyokos plays well with othersyokos plays well with othersyokos plays well with othersyokos plays well with others
 
yokos's Avatar
 
Posts: 720
Karma: 2571
Join Date: Apr 2006
Location: Germany; next to Baltic Sea
Device: 1st gen iRex iLiad with 2nd ed. battery/case
Ok, vmware image is running; next step would be to use in the right way.
Attached Thumbnails
Click image for larger version

Name:	VMware_01.png
Views:	586
Size:	60.0 KB
ID:	3036   Click image for larger version

Name:	VMware_02.png
Views:	572
Size:	30.9 KB
ID:	3037   Click image for larger version

Name:	VMware_03.png
Views:	678
Size:	35.3 KB
ID:	3038   Click image for larger version

Name:	VMware_04.png
Views:	695
Size:	28.2 KB
ID:	3039   Click image for larger version

Name:	VMware_05.png
Views:	709
Size:	21.4 KB
ID:	3040   Click image for larger version

Name:	VMware_06.png
Views:	684
Size:	19.0 KB
ID:	3041  
yokos is offline   Reply With Quote
Old 04-05-2007, 09:15 AM   #34
Adam B.
Addicted to Porting
Adam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the rough
 
Adam B.'s Avatar
 
Posts: 1,695
Karma: 7194
Join Date: Oct 2006
Location: Indianapolis, IN
Device: iRex iLiad, Nokia 770, Samsung i760
I'll throw together a how-to today with an app you can download compile and test.
Adam B. is offline   Reply With Quote
Old 04-05-2007, 05:49 PM   #35
Adam B.
Addicted to Porting
Adam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the rough
 
Adam B.'s Avatar
 
Posts: 1,695
Karma: 7194
Join Date: Oct 2006
Location: Indianapolis, IN
Device: iRex iLiad, Nokia 770, Samsung i760
Here's how I port applications. The following steps should work for you. It may be a bit too detailed in parts, and not in others. But if you're up for porting, you should be able to figure it out. If I'm doing something wrong, let me know. The following method works, but it may not be ideal.


First, boot the virtual machine.

Login to the virtual machine as developer. Type "sudo ifconfig" to find out the ip address of the machine.

SSH to that IP address. In Windows, use putty. On linux or Mac, use the terminal. Again, log in as developer.

Enter the command sb-menu. Go to Select, and select 'iliad-dev', you will use this target for all of your compiling. Then type 'scratchbox' to enter the scratchbox environment.

Type 'pwd'. You should be in /home/developer. This is where I store all the build files.

We will be compiling stardict today. It's a dictionary reading software. There's a precompiled version already on MobileRead.

The easiest ways to download files onto the development box is by using wget. First, go to http://sourceforge.net/projects/stardict/, then, click the link that says "download". We will want the stardict package, with the platform independent source. You should eventually see a link called "stardict-2.4.8.tar.bz2". Click that link, and sourceforge will eventually automatically download the file. However, you don't want to download it to your primary machine. Click cancel when the download screen pops up. You're looking for the link that says "If you are experiencing problems with the download please use this direct link.". Right click on 'this direct link' and click "copy link location". Then, go to your scratchbox and type 'wget' and paste the link. For stardict, you should enter something like "wget http://easynews.dl.sourceforge.net/sourceforge/stardict/stardict-2.4.8.tar.bz2" depending on the mirror that is chosen.

After it is finished downloading, you will need to extract the files. Since this is created with bzip compression you will type "tar -xjvf stardict-2.4.8.tar.bz2". If it were a gzipped archive, you would use tar -xzvf.

CD into the stardict directory. Type "./configure --help" to see your configuration options.

Stardict normally requires Gnome to run. However, we do not have gnome on the iLiad. You can compile it with GTK Support, since almost all iLiad apps are based on GTK. To do this, you'll need the --disable-gnome-support flag.
Also, the iLiad has a limited amount of storage on the internal memory. I choose to compile apps with a static directory pointing to the memory card. There may be a better way to do this, but it works well enough for me. To do this, I use the --prefix=/mnt/card/stardict flag. You would use /mnt/cf for conpact flash.

So, to configure the package, we need to run

Code:
./configure --disable-gnome-support --prefix=/mnt/card/stardict
At this point you should be ready to make the executable. But you'll find when you run make on it, that it has problems compiling. This comes down to a problem with the version of libXML that is installed. You will need to download and compile libXML2. dl-and-install.sh should be able to do this for you, but I haven't had much luck with it. To search for a missing package, I open your browser and go to: http://packages.debian.org/cgi-bin/s...ode=searchword . There, you will find libXML2-dev. Select the first link, and scroll down to the bottom. You will see 2 links: [libxml2_2.6.27.dfsg.orig.tar.gz] [libxml2_2.6.27.dfsg-1.diff.gz] .

On your development box, type "cd ~/dependencies-helper/". There, you will need to wget both files. Once both files are downloaded, run the command
Code:
./unpack-n-patch-n-build-install.sh libxml2_2.6.27.dfsg.orig.tar.gz
This will unzip, configure, make, and install the new libxml2 package. After it completes, go back to the stardict directory. Then, type "make; make install". This will build the program, and put all of it's files in your /mnt/card/stardict directory.

Now, we will need to put together the necessary libraries for the program to include in our package. Move stardict to your home directory.

Code:
cd ~/
mv /mnt/card/stardict ~/
Now, we will run the libarary helper program.

Code:
./lib-gen.sh stardict/bin/stardict 
./run-gen.sh stardict/bin/stardict 
mv lib stardict
Now, stardict is built, the libraries are in place, and we need to test the program.

Type 'exit' to exit scratchbox. We will need to start the vnc server.
Code:
 vncserver -ac -geometry 768x1024 -depth 8 :1
Once it is started, open your vnc viewer of choice and connect to IP-ADDRESS:5901

Go back into scratchbox. Type sb-menu and select the iliad-irex target.

Now, we will need to start the window manager:

Code:
cd /
DISPLAY=IP-ADDRESS:1
export DISPLAY
/iliad.sh usr/bin/matchbox-window-manager -use_titlebar no -use_cursor no &
/iliad.sh usr/bin/pageBar &
/iliad.sh usr/bin/matchbox-panel --size 39 --no-menu --bgcolor White &
Now, we will need to move the stardict directory to our virtual memory card and tell it where to load the libraries.

Code:
mv ~/stardict /mnt/card/
export LD_LIBRARY_PATH=/mnt/card/stardict/lib
Finally, lets run stardict.

Code:
/mnt/card/stardict/bin/stardict
There you have it! Stardict should be running in your VNC window. You'll need to zip up the folder, create a launcher, and copy it to your iLiad to test on there. You can download one of my other packages to use that as a template. Good luck and let me know if you have any problems or questions.
Adam B. is offline   Reply With Quote
Old 04-05-2007, 05:51 PM   #36
TadW
Uebermensch
TadW ought to be getting tired of karma fortunes by now.TadW ought to be getting tired of karma fortunes by now.TadW ought to be getting tired of karma fortunes by now.TadW ought to be getting tired of karma fortunes by now.TadW ought to be getting tired of karma fortunes by now.TadW ought to be getting tired of karma fortunes by now.TadW ought to be getting tired of karma fortunes by now.TadW ought to be getting tired of karma fortunes by now.TadW ought to be getting tired of karma fortunes by now.TadW ought to be getting tired of karma fortunes by now.TadW ought to be getting tired of karma fortunes by now.
 
TadW's Avatar
 
Posts: 2,582
Karma: 1094606
Join Date: Jul 2003
Location: Italy
Device: Kindle
Wow this deserves a Wiki entry and a sticky in the forum, don't you think?

Thanks Adam!
TadW is offline   Reply With Quote
Old 04-10-2007, 10:02 AM   #37
tororebelde
No es el toro que piensas
tororebelde began at the beginning.
 
tororebelde's Avatar
 
Posts: 44
Karma: 10
Join Date: Mar 2007
Device: iRex iliad
wow

Wow Adam!
You're amazing! you're great!
With this post is really easy to start build & test apps for iLiad!

I tried it following your steps and all worked

Thanks Adam
tororebelde is offline   Reply With Quote
Old 04-10-2007, 11:10 AM   #38
Adam B.
Addicted to Porting
Adam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the rough
 
Adam B.'s Avatar
 
Posts: 1,695
Karma: 7194
Join Date: Oct 2006
Location: Indianapolis, IN
Device: iRex iLiad, Nokia 770, Samsung i760
Thanks for the kind words.

Unfortunately, doing this is only the first step. You still need to digg though the code of the program, setup screen refreshes, change the window class, add an exit button (if necessary), etc, etc.

Since this is my first attempt at linux programming (done some windows vb, c, and java), you should be able to search through my posts here and on the irex forums for tips, direction, and help. That, and this post: http://www.mobileread.com/forums/sho...63&postcount=4 helped me out a lot.

Good luck to those who are new to this. The more people we have bringing out the power of this device, the better it will be.
Adam B. is offline   Reply With Quote
Old 09-30-2007, 11:07 AM   #39
mind
Member
mind began at the beginning.
 
Posts: 24
Karma: 11
Join Date: Sep 2007
Device: iLiad
I tried on a x86_64 on gentoo, but vmplayer freeze al my pc. Is there any way to compile for iLiad with a 64 bit PC?
Did you use Antartica's toolchain right? What's about official one?

Regards, Gil
mind is offline   Reply With Quote
Old 10-25-2007, 09:28 AM   #40
shiggie
Junior Member
shiggie began at the beginning.
 
Posts: 9
Karma: 10
Join Date: Jun 2006
Fantastic!

I do a lot of development on Windows and I've just caved and bought a 2nd Edition iliad. Looking forward to trying my hand at Linux development... this should make it a bit easier, thanks!

shiggie is offline   Reply With Quote
Old 11-28-2007, 01:43 PM   #41
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: 974
Karma: 687
Join Date: Nov 2007
Device: Dell X51v; iLiad v2
I am not familiar with embedded Linux. And I havn't tried this package. I am curious that does this package play as an iLiad emulator? Since there are already Windows Mobile and PalmOS emulator, I expect an iLiad emulator come true. It will be handy when making homebrew ebooks as I can test if it looks fine on iLiad.
ericshliao is offline   Reply With Quote
Old 11-28-2007, 02:00 PM   #42
Adam B.
Addicted to Porting
Adam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the rough
 
Adam B.'s Avatar
 
Posts: 1,695
Karma: 7194
Join Date: Oct 2006
Location: Indianapolis, IN
Device: iRex iLiad, Nokia 770, Samsung i760
It's not an iLiad emulator per se. You can test applications on it that you compile, but it does not include any of the iLiad's viewers (Mobipocket, iPDF, etc).
Adam B. is offline   Reply With Quote
Old 11-28-2007, 02:58 PM   #43
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: 974
Karma: 687
Join Date: Nov 2007
Device: Dell X51v; iLiad v2
There are some 3-rd party viewers and apps developed by iLiad users. Can I install some of them in this package? If so, it will become a quasi iLiad emulator?
ericshliao is offline   Reply With Quote
Old 12-22-2007, 08:02 PM   #44
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: 974
Karma: 687
Join Date: Nov 2007
Device: Dell X51v; iLiad v2
Hi,
I used it to compile stardict 3.0.1 and failed. I was blocked by an error message (show in attached file) when doing "./configure --disable-gnome-support --disable-spell --disable-gucharmap --disable-festival --dieable-espeak".
Attached Thumbnails
Click image for larger version

Name:	sc.jpg
Views:	429
Size:	121.0 KB
ID:	8349  

Last edited by ericshliao; 12-22-2007 at 08:04 PM.
ericshliao is offline   Reply With Quote
Old 12-23-2007, 12:06 PM   #45
Adam B.
Addicted to Porting
Adam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the roughAdam B. is a jewel in the rough
 
Adam B.'s Avatar
 
Posts: 1,695
Karma: 7194
Join Date: Oct 2006
Location: Indianapolis, IN
Device: iRex iLiad, Nokia 770, Samsung i760
Quote:
Originally Posted by ericshliao View Post
Hi,
I used it to compile stardict 3.0.1 and failed. I was blocked by an error message (show in attached file) when doing "./configure --disable-gnome-support --disable-spell --disable-gucharmap --disable-festival --dieable-espeak".
It looks like that version of Stardict requires a newer version of pkg-config.

I've run into this before. You'll have to download and compile the most recent version. It may also have some dependencies that you need to update as well.
Adam B. is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
iRex DR1000 Development VMWare Image Adam B. iRex 9 08-19-2010 05:23 AM
DR800 Developement VMWare Image? CoolDragon iRex 8 04-04-2010 06:30 AM
calibre VMWare development environment kovidgoyal Calibre 30 12-30-2009 01:43 PM
iLiad iRex iLiad development enviroment on VMware image Alexander Turcic iRex Developer's Corner 0 03-31-2007 03:02 PM


All times are GMT -4. The time now is 12:44 AM.


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