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

Go Back   MobileRead Forums > E-Book Readers > Kobo Reader > Kobo Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 07-22-2012, 05:46 AM   #1
BWinmill
Wizard
BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.
 
Posts: 1,813
Karma: 15164032
Join Date: Sep 2011
Device: Sony PRS-T1
Setting up a development environment ...

How do you setup a development environment for the Kobo Touch?

I would prefer something hosted on the Touch.

If that is not possible, is it possible to use the compilers from the Android SDK?

Which headers are required for the Touch?

In the case of cross compilers, do I need to copy the libraries from the Touch onto the host system?
BWinmill is offline   Reply With Quote
Old 07-22-2012, 06:39 AM   #2
ah-
Connoisseur
ah- could sell banana peel slippers to a Deveel.ah- could sell banana peel slippers to a Deveel.ah- could sell banana peel slippers to a Deveel.ah- could sell banana peel slippers to a Deveel.ah- could sell banana peel slippers to a Deveel.ah- could sell banana peel slippers to a Deveel.ah- could sell banana peel slippers to a Deveel.ah- could sell banana peel slippers to a Deveel.ah- could sell banana peel slippers to a Deveel.ah- could sell banana peel slippers to a Deveel.ah- could sell banana peel slippers to a Deveel.
 
Posts: 64
Karma: 3062
Join Date: Jan 2012
Device: Kobo Touch
The way to do it is to setup a cross compilation environment, for a bit outdated guide see http://blog.ringerc.id.au/2011/01/pr...nment-for.html

I'd love to have an easy guide here, that would lower the entry barrier quite a bit.

I'm also not sure what and how much changed with the 2.0 firmware, before that the library versions in the Kobolabs github repository matched the ones on the device but they at least switched to Qt 4.8 now.
ah- is offline   Reply With Quote
Old 08-06-2012, 08:12 PM   #3
tonyv
Member
tonyv began at the beginning.
 
Posts: 12
Karma: 20
Join Date: Oct 2009
Device: elonex eb600
A guide for kobo touch from memory and bash history so will edit if people have prob
My system is ubuntu 10.04 64bit
Telnet into kobo using this guide
http://wiki.mobileread.com/wiki/Kobo_Touch_Hacking
optionally set up usb networking




on kobo
>strings /lib/libc.so.6 | grep ourcery
this is what i got
GNU C Library (Sourcery G++ Lite 2010q1-202) stable release version 2.11.1, by Roland McGrath et al.
if you have a different compiler you can flash to 1.9.17 or
download your version from mentor could try
site:sourcery.mentor.com "your version" in google
make directory for downloads
>mkdir ~/kobostuff
>cd ~/kobostuff

>wget https://sourcery.mentor.com/public/g...ux-gnueabi.bin
>wget https://sourcery.mentor.com/sgpp/lit...ng-started.pdf (optional)
or get from this
http://www.codesourcery.com/sgpp/lit...al/release1293

The Sourcery G++ graphical installer is incompatible with the dash shell, which is the
default /bin/sh for recent releases of the Ubuntu and Debian GNU/Linux distributions.

Ubuntu has dash instead of bash to run scripts the Sourcery G++ graphical installer is incompatible with the dash shell hence

>sudo dpkg-reconfigure -plow dash
Install as /bin/sh? No (do this again with yes after install to restore dash )
see pdf above

>sudo apt-get install gettext autoconf libglib2.0-dev ia32-libs
ia32-libs for 64 bit system don't need it for 32
>chmod a+x arm-2010q1-202-arm-none-linux-gnueabi.bin
>./arm-2010q1-202-arm-none-linux-gnueabi.bin

Accept the default install path of $HOME/CodeSourcery/Sourcery_G++_Lite when prompted. Accept all other installer defaults.

put this line at end of ~/.bashrc
export PATH="/home/"yourusername"/CodeSourcery/Sourcery_G++_Lite/bin:${PATH}"

open new xterm so it reads .bashrc
to test
>arm-none-eabi-g++ -v
the last line of the output should contains: Sourcery G++ Lite 2010q1-202

should be able to compile full_updatescreen.c demo in eink.tar.gz below

arm-none-linux-gnueabi-gcc -Wall full_updatescreen.c -o update

to compile qt and libs set up symbolic links like so
> cd ~/CodeSourcery/Sourcery_G++_Lite/bin
> for f in arm-none-linux-gnueabi-* ; do ln -s $f arm-linux-${f:23}; done

>mkdir ~/kobo
>cd ~/kobo
>git clone git://github.com/kobolabs/Kobo-Reader.git koboreader

>KOBOLABS=$HOME/kobo/KoboLabs
>mkdir -p ~/kobo/fs ~/kobo/tmp

make new text file /kobo/KoboLabs/build/build-config-user.sh with this contents

DEVICEROOT=$HOME/kobo/fs
QT_EXTRA_ARGS=--prefix=$HOME/kobo/qt

edit kobo/KoboLabs/build/scripts/qt.sh
on line starting with ./configure add "-D QT_NO_QWS_CURSOR" at end without quotes
cd ~/kobo/tmp
~/kobo/KoboLabs/build/build-all.sh



if sucessful can test qt by compiling eink qt plugin in QtEink.tar.gz
mkdir whatever
cp QtEink.tar.gz whatever
cd whatever
tar -zxvf QtEink.tar.gz
>~/kobo/qt/bin/qmake
> make clean
> make
copy libKindleFb.so to this directory on kobo
/usr/local/Trolltech/QtEmbedded-4.6.2-arm/plugins/gfxdrivers/

then compile this crude demo Sketch.tar.gz same as above
transfer to kobo
on kobo
>LD_LIBRARY_PATH=/usr/local/Trolltech/QtEmbedded-4.6.2-arm/lib
>QWS_DISPLAY=kindlefb // guess where most the code came from see below
>QWS_MOUSE_PROTO=tslib:/dev/input/event1
>./CppQtExample20 -qws



ref
http://blog.ringerc.id.au/2011/01/pr...nment-for.html
kobo java based pdf reader has eink driver for swing
http://www.blogger.com/comment.g?blo...12809223613654 http://code.google.com/p/mediaz/
Qt plugin for kindle source for kobo plugin
http://www.griffin.net/2010/01/hacki...nd-sudoku.html
Good luck

I have started a new thread about eink drivers please use this thread for support about setting up enviroment and other about eink drivers .
Attached Files
File Type: gz eink.tar.gz (3.1 KB, 239 views)
File Type: gz QtEink.tar.gz (34.4 KB, 210 views)
File Type: gz Sketch.tar.gz (47.7 KB, 195 views)

Last edited by tonyv; 08-06-2012 at 09:13 PM.
tonyv is offline   Reply With Quote
Old 03-18-2013, 11:02 AM   #4
mastnacek
Enthusiast
mastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-books
 
Posts: 33
Karma: 946
Join Date: Mar 2013
Device: Kobo Mini
Re

hello I have problem with this

Quote:
put this line at end of ~/.bashrc
export PATH="/home/"yourusername"/CodeSourcery/Sourcery_G++_Lite/bin:${PATH}"

open new xterm so it reads .bashrc
to test
>arm-none-eabi-g++ -v
the last line of the output should contains: Sourcery G++ Lite 2010q1-202
mastnacek is offline   Reply With Quote
Old 03-18-2013, 01:41 PM   #5
KevinShort
Addict
KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.
 
KevinShort's Avatar
 
Posts: 342
Karma: 165069
Join Date: Jan 2012
Location: Virginia, US
Device: Kobo Wifi, Kobo Glo
Quote:
Originally Posted by mastnacek View Post
hello I have problem with this
It's hard for us to help you unless you tell us what is happening. Are you getting a "command not found" error? What output do you get when you run this command?
Code:
arm-none-eabi-g++ -v
KevinShort is offline   Reply With Quote
Old 03-18-2013, 03:10 PM   #6
mastnacek
Enthusiast
mastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-books
 
Posts: 33
Karma: 946
Join Date: Mar 2013
Device: Kobo Mini
Sorry, I was in a hurry. Now i installing new xubuntu into virtualbox so ill try make development enviroment again. I want make plugin fbreader or cool reader.
mastnacek is offline   Reply With Quote
Old 03-19-2013, 04:38 AM   #7
mastnacek
Enthusiast
mastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-booksmastnacek has learned how to read e-books
 
Posts: 33
Karma: 946
Join Date: Mar 2013
Device: Kobo Mini
Done, this works
export PATH=$PATH:/home/jara/CodeSourcery/Sourcery_G++_Lite/bin/

Last edited by mastnacek; 03-19-2013 at 05:14 AM.
mastnacek is offline   Reply With Quote
Old 05-08-2013, 06:37 AM   #8
Grunge
Member
Grunge can eat soup with a fork.Grunge can eat soup with a fork.Grunge can eat soup with a fork.Grunge can eat soup with a fork.Grunge can eat soup with a fork.Grunge can eat soup with a fork.Grunge can eat soup with a fork.Grunge can eat soup with a fork.Grunge can eat soup with a fork.Grunge can eat soup with a fork.Grunge can eat soup with a fork.
 
Posts: 12
Karma: 9172
Join Date: Apr 2013
Device: Kobo Touch
did I somthing wrong?

Hi

Just installed the CodeSourcery like in the description.

i can't execute the commando
arm-none-eabi-g++ -v

all i did find was
arm-none-linux-gnueabi-g++

what gives me with -v :
blablabla
gcc version 4.4.1 (Sourcery G++ Lite 2010q1-202)

so this should be fine?
Greetings and thank you
Grunge

Edit 1.
had do create some symlinks (createdt them in /sbin of my ubuntu):
ln -s /root/CodeSourcery/Sourcery_G++_Lite/bin/arm-none-linux-gnueabi-gcc ./arm-linux-gcc
ln -s /root/CodeSourcery/Sourcery_G++_Lite/bin/arm-linux-ar ./arm-linux-ar
ln -s /root/CodeSourcery/Sourcery_G++_Lite/bin/arm-linux-ranlib ./arm-linux-ranlib

Last edited by Grunge; 05-10-2013 at 10:13 AM.
Grunge is offline   Reply With Quote
Old 05-08-2013, 11:52 AM   #9
KevinShort
Addict
KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.
 
KevinShort's Avatar
 
Posts: 342
Karma: 165069
Join Date: Jan 2012
Location: Virginia, US
Device: Kobo Wifi, Kobo Glo
I don't know why tonyv's guide is different, but arm-none-linux-gnueabi-g++ is the correct name.
KevinShort is offline   Reply With Quote
Old 07-25-2013, 05:19 AM   #10
sunda
Member
sunda began at the beginning.
 
Posts: 15
Karma: 10
Join Date: Jul 2013
Device: Kobo
step problems in Setting up a development environment ......

Hi all, I'm newbie in this field...

I followed the steps above, all ok, but when calling:
~/kobo/KoboLabs/build/build-all.sh

it compiles (a lot), i get this error:

patching file autogen.sh
~/kobo/tmp/libmng-1.0.10 ~/kobo/tmp
copying configure.in
copying automake template
running aclocal
configure.in:22: warning: macro `AM_PROG_LIBTOOL' not found in library
error: Could not find libtoolize in the path!
You'll need to install a copy of libtool before continuing
with the generation of the build system.

Build failed at libmng.sh, aborting


Any ideas how to solve!?

(I can see the file "libmng-1.0.10 and also "libtool-2.2.8" in the tmp folder, so the file is there)

UPDATE:
ok I found out that I had to install Libtool manually (sudo apt-get install "filename").

But I have this now:
...
No need to rebuild udev
No need to rebuild lcms
No need to rebuild libmng
~/kobo/tmp/qt-everywhere-opensource-src-4.6.2 ~/kobo/tmp
/home/okan/kobo/qt: unknown argument

You have not explicitly asked to use pkg-config and are cross-compiling.
pkg-config will not be used to automatically query cflag/lib parameters for
dependencies


Ok it is apperently too difficult for me
Somehow I can't even use linux commands...

Anyone who could help please?
A step by step instructions to set up a Qt development (I'm new in Linux, but could setup a Virtual Box which runs Ubuntu). Maybe with added "idiot proof" instrucstion on the above.

Thanks.

Last edited by sunda; 07-26-2013 at 07:35 AM. Reason: more problems...
sunda is offline   Reply With Quote
Old 07-25-2013, 05:36 PM   #11
stefjan
Junior Member
stefjan is on a distinguished road
 
Posts: 7
Karma: 57
Join Date: Jun 2013
Device: kobo glo
Quote:
Originally Posted by KevinShort View Post
I don't know why tonyv's guide is different, but arm-none-linux-gnueabi-g++ is the correct name.
That's true, but the build-config.sh script sets CC to arm-linux-gcc, so you need to set these links which Grunge mentions for certain other scripts to work.
stefjan is offline   Reply With Quote
Old 07-26-2013, 12:39 PM   #12
KevinShort
Addict
KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.
 
KevinShort's Avatar
 
Posts: 342
Karma: 165069
Join Date: Jan 2012
Location: Virginia, US
Device: Kobo Wifi, Kobo Glo
Sunda: try executing this command right before you run build-all.sh:
Code:
export PKG_CONFIG_PATH=~/kobo/fs/lib/pkgconfig
I noticed that you're trying to compile Qt 4.6. Are you aware that the newer Kobo firmware builds use Qt 4.8? Also, Kobo switched to a new toolchain in 2.6, which complicates things. I tried to compile Qt 4.8 with the new toolchain, without altering the configuration I used for the old toolchain, but it failed to compile.
KevinShort is offline   Reply With Quote
Old 07-26-2013, 01:27 PM   #13
tshering
Wizard
tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.
 
Posts: 1,413
Karma: 365040
Join Date: Jun 2012
Device: kobo touch
I am a little confused about, what is necessary for compiling Qt applications for Kobo under Ubuntu?
Would
https://launchpad.net/linaro-toolcha..._linux.tar.bz2
and
http://releases.qt-project.org/qt4/s...c-4.8.4.tar.gz
suffice?

Last edited by tshering; 07-26-2013 at 01:33 PM.
tshering is offline   Reply With Quote
Old 07-27-2013, 06:01 AM   #14
sunda
Member
sunda began at the beginning.
 
Posts: 15
Karma: 10
Join Date: Jul 2013
Device: Kobo
Quote:
Originally Posted by KevinShort View Post
Sunda: try executing this command right before you run build-all.sh:
Code:
export PKG_CONFIG_PATH=~/kobo/fs/lib/pkgconfig
I noticed that you're trying to compile Qt 4.6. Are you aware that the newer Kobo firmware builds use Qt 4.8? Also, Kobo switched to a new toolchain in 2.6, which complicates things. I tried to compile Qt 4.8 with the new toolchain, without altering the configuration I used for the old toolchain, but it failed to compile.
Thanks for the feedback KevinShort.
Ok, I have installed a new linux and started over...
Now it compiles again, but I have this:
configure error:
*** You must have either have gettext support in your C library, or use the
*** GNU gettext library.
Build failed at glib.sh, aborting


What now

where can see about if it's Qt 4.6 (and how to setup for Qt 4.8? on Kobo and in Compile again in Linux!?).
I'm not sure about Qt 4.6, I have installed the older firmware 2.4.0 on the Kobo and KoboLaunch is working fine with this version. On the kobo I see under folder: "/usr/local/Trolltech" that there is a folder with the name "QtEmbedded-4.6.2-arm"

I use Linux 12.04LTS and in kobo when writing:
strings /lib/libc.so.6 | grep ourcery
GNU C Library (Sourcery G++ Lite 2010q1-202) stable release version 2.11.1, by Roland McGrath et al.

sunda is offline   Reply With Quote
Old 07-27-2013, 01:57 PM   #15
KevinShort
Addict
KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.KevinShort can program the VCR without an owner's manual.
 
KevinShort's Avatar
 
Posts: 342
Karma: 165069
Join Date: Jan 2012
Location: Virginia, US
Device: Kobo Wifi, Kobo Glo
Quote:
Originally Posted by sunda View Post
Thanks for the feedback KevinShort.
Ok, I have installed a new linux and started over...
Now it compiles again, but I have this:
configure error:
*** You must have either have gettext support in your C library, or use the
*** GNU gettext library.
Build failed at glib.sh, aborting
You just need to install gettext. This command will install the stuff you need to compile Qt for Kobo:
Code:
sudo apt-get install gettext autoconf libglib2.0-dev build-essential libtool libdbus-1-dev
If you're using firmware 2.4, then Qt 4.6 is the right version. In the file 'build/scripts/qt.sh', at the end of the ./configure line, make sure to add -D QT_NO_QWS_CURSOR.
KevinShort 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
Problem with creating the development environment rozen Calibre 6 05-30-2011 12:38 AM
calibre VMWare development environment kovidgoyal Calibre 30 12-30-2009 01:43 PM
Setting up Mac Calibre development environment? pdurrant Calibre 2 01-06-2009 08:10 AM
setup development environment JeffElkins Calibre 21 10-22-2008 04:25 PM
Setting up development environment tompe OpenInkpot 9 08-27-2008 03:26 PM


All times are GMT -4. The time now is 12:43 PM.


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