Register Guidelines E-Books Today's Posts Search

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

Notices

Reply
 
Thread Tools Search this Thread
Old 03-20-2019, 02:20 PM   #16
BloodRagg
Zealot
BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.
 
BloodRagg's Avatar
 
Posts: 128
Karma: 842196
Join Date: Feb 2019
Device: none
Quote:
Originally Posted by NiLuJe View Post
If you don't actually need to play with Qt, unlike this thread implies: https://github.com/koreader/koxtoolchain

If you do need to play with Qt, good luck. If you do, AFAICT, for Qt4, you're better off matching Sergey's toolchain, which is probably documented somewhere... For Qt5, Kobo's latest toolchain, which you can suss out from current FW binaries.
Found it this morning, compiling took over an hour on my horrible machine.
Its a great piece of work though but the binaries it produced segfaulted also

Live CD also produced segfaulted binaries, so i know its something im missing

Quote:
Originally Posted by NiLuJe View Post
Note that in dropbear's specific case, libtom* is involved. If you opt to build against an external copy, it will not build against current libtomcrypt.

Both options should work though: I build it against external copies, KOReader against the internal ones, and it behaves in both cases.
That could be my problem..i tried almost everything, but then again im quite the noob.
BloodRagg is offline   Reply With Quote
Old 03-20-2019, 02:41 PM   #17
pazos
cosiñeiro
pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.
 
Posts: 1,275
Karma: 2200073
Join Date: Apr 2014
Device: BQ Cervantes 4
If you want to build qt applications with koxtoolchain you'll need to link statically against libstdc++, because system is too old for modern toolchains.

Add the following to your pro file (of course edit the path first):

Code:
LIBS += /home/pazos/x-tools/arm-kobo-linux-gnueabihf/arm-kobo-linux-gnueabihf/lib/libstdc++.a
QMAKE_LFLAGS += -static-libstdc++
You can build Qt 4.8.5 with koxtoolchain without problems, but you'll need to repurpose Sergey's drivers for touchscreen, framebuffer and keypad (or luck into his sources and add these drivers to Qt, but it's more work)

Last edited by pazos; 03-20-2019 at 02:50 PM.
pazos is offline   Reply With Quote
Advert
Old 03-20-2019, 07:26 PM   #18
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,480
Karma: 26012494
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
Time to fire up GDB...

(I smell hardfp/softp shenanigans, as Kobo's dynamic loader is slightly finicky on that front).
NiLuJe is offline   Reply With Quote
Old 03-21-2019, 08:06 AM   #19
BloodRagg
Zealot
BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.
 
BloodRagg's Avatar
 
Posts: 128
Karma: 842196
Join Date: Feb 2019
Device: none
@NiLuJe
gdb ? you give me way too much credit

@pazos
Toolchain was from 2013, so i needed the lib32stdc++6 package. Afaict this could have been used by the compiler.

So I tried your static linking, (one step forward) the results were slightly different but still no dice
Then I removed the lib32stdc++6 package and tried the latest koxtoolchain as its 64-bit

Makes no difference, I either end up with a 'segfault' or 'illegal Instruction'.

I'm feeling quite hopeless here
Attached Files
File Type: zip config.log.zip (15.9 KB, 151 views)

Last edited by BloodRagg; 03-21-2019 at 08:08 AM. Reason: attached config.log
BloodRagg is offline   Reply With Quote
Old 03-21-2019, 08:58 AM   #20
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,480
Karma: 26012494
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
Try attaching a simple hello world you built so we can check how exactly it crashes .
NiLuJe is offline   Reply With Quote
Advert
Old 03-21-2019, 12:12 PM   #21
BloodRagg
Zealot
BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.
 
BloodRagg's Avatar
 
Posts: 128
Karma: 842196
Join Date: Feb 2019
Device: none
Hmm...that compiles and runs just fine.
BloodRagg is offline   Reply With Quote
Old 03-21-2019, 05:14 PM   #22
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,480
Karma: 26012494
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
What's the actual target device, and on which FW version? And what kind of CFLAGS are you passing?

EDIT: As far as dropbear is concerned, you may also want to *disable* hardening, as that's been broken since since the latest release on my end (with a hang, not a crash, though).

Last edited by NiLuJe; 03-21-2019 at 05:18 PM.
NiLuJe is offline   Reply With Quote
Old 03-26-2019, 02:37 PM   #23
BloodRagg
Zealot
BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.
 
BloodRagg's Avatar
 
Posts: 128
Karma: 842196
Join Date: Feb 2019
Device: none
Found the %$£$@£$£ £4 problem, linker defaulted to build system instead of host/target.

>> LD=arm-linux-gnuabihf << fixed the problem in my case.

So I configured all those other variables as well CC GXX AR NM OBJCOPY etc.. etc..

Silly me thought make CROSS_COMPILE=arm-linux-gnuabihf- would be enough.

@NiLuJe, how did you compile 2018.76, mine keeps asking for glibc 2.25 which relies on kernel 3.2.0 ?

Furthest i came was 2016.72
BloodRagg is offline   Reply With Quote
Old 03-26-2019, 02:55 PM   #24
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,480
Karma: 26012494
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
@BloodRagg: What's asking for glibc 2.25? The configure or the binaries at runtime? Which what TC?
NiLuJe is offline   Reply With Quote
Old 03-26-2019, 03:39 PM   #25
BloodRagg
Zealot
BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.
 
BloodRagg's Avatar
 
Posts: 128
Karma: 842196
Join Date: Feb 2019
Device: none
Quote:
Originally Posted by NiLuJe View Post
@BloodRagg: What's asking for glibc 2.25? The configure or the binaries at runtime? Which what TC?
Binaries:
[root@(none) tmp]# ./sbin/dropbear
./sbin/dropbear: /lib/libc.so.6: version `GLIBC_2.25' not found (required by ./sbin/dropbear)
[root@(none) tmp]#

TC: gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf
PKG: dropbear-2019.77
BloodRagg is offline   Reply With Quote
Old 03-26-2019, 04:27 PM   #26
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,480
Karma: 26012494
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
How was that TC built? koxtoolchain targets glibc-2.15, so it can't pull newer symbols unless you're doing things wrong .
See my earlier mention of disabling hardening, but even if that fixes it, that doesn't mean that your setup isn't seriously broken .

Speaking of: exceedingly few things should require you to manually enforce CC, CXX, AR, NM, LD & friends. Very few things actually rely on a CROSS_something env var either (OTOH, busybox and OpenSSL would be two exceptions, each expecting a slightly different env var, with a slightly different syntax, IIRC).
What *is* almost ubiquitous, though, is autotool's confusingly named --host argument, which accepts a toolchain triplet, and automatically obeys it to set CC & co.

EDIT: As far as 2019.77 is concerned, my best guess is you're picking up your system includes/glibc because of aforementioned mistakes, and as such it's detecting strlcat/strlcpy as available, while they're definitely not .

Last edited by NiLuJe; 03-26-2019 at 04:45 PM.
NiLuJe is offline   Reply With Quote
Old 03-27-2019, 05:48 AM   #27
BloodRagg
Zealot
BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.
 
BloodRagg's Avatar
 
Posts: 128
Karma: 842196
Join Date: Feb 2019
Device: none
Quote:
Originally Posted by NiLuJe View Post
How was that TC built? koxtoolchain targets glibc-2.15, so it can't pull newer symbols unless you're doing things wrong .
See my earlier mention of disabling hardening, but even if that fixes it, that doesn't mean that your setup isn't seriously broken .
A beginners charm

Quote:
Originally Posted by NiLuJe View Post
Speaking of: exceedingly few things should require you to manually enforce CC, CXX, AR, NM, LD & friends. Very few things actually rely on a CROSS_something env var either (OTOH, busybox and OpenSSL would be two exceptions, each expecting a slightly different env var, with a slightly different syntax, IIRC).
What *is* almost ubiquitous, though, is autotool's confusingly named --host argument, which accepts a toolchain triplet, and automatically obeys it to set CC & co.
I noticed, but i was confused about it.

Quote:
Originally Posted by NiLuJe View Post
EDIT: As far as 2019.77 is concerned, my best guess is you're picking up your system includes/glibc because of aforementioned mistakes, and as such it's detecting strlcat/strlcpy as available, while they're definitely not .
I think it was toolchain based as it compiles properly now, but fails when i try to do a make install.It complains about an ld linking problem.
It works when i remove the MULTI=1 though, but i really want it as an multiexec
Code:
/tmp/autobuild/gcc-kox-7.4.1-2019.02-1f65f8d-x86_64-arm-kobo-linux-gnueabihf/bin/../lib/gcc/arm-kobo-linux-gnueabihf/7.4.1/../../../../arm-kobo-linux-gnueabihf/bin/ld.bfd: /tmp/autobuild/gcc-kox-7.4.1-2019.02-1f65f8d-x86_64-arm-kobo-linux-gnueabihf/bin/../arm-kobo-linux-gnueabihf/sysroot/usr/lib/Scrt1.o: in function `_start':
init.c:(.text+0x4c): undefined reference to `main'
collect2: error: ld returned 1 exit status
Makefile:192: recipe for target 'dropbear' failed
make: *** [dropbear] Error 1
/tmp/autobuild/dropbear-2019.77$
BloodRagg is offline   Reply With Quote
Old 03-27-2019, 10:10 AM   #28
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,480
Karma: 26012494
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
Full configure and build output would be more helpful .
NiLuJe is offline   Reply With Quote
Old 03-27-2019, 11:41 AM   #29
BloodRagg
Zealot
BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.BloodRagg ought to be getting tired of karma fortunes by now.
 
BloodRagg's Avatar
 
Posts: 128
Karma: 842196
Join Date: Feb 2019
Device: none
Logs:
So, I switched toolchains from linaro to kox:
- glibc 2.23 wont compile under kox, symbol error, so i figured well might as well go with 2.15 because kox does. wont compile either
- dropbear 2019.77 does compile under kox only not with multi under linaro it would but i would be facing glibc too old error.

Its like throwing craps in Vegas, its probably me but geez louise I'm going mad

Last edited by BloodRagg; 03-27-2019 at 02:01 PM.
BloodRagg is offline   Reply With Quote
Old 03-27-2019, 12:03 PM   #30
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,480
Karma: 26012494
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
Why do you want to compile the glibc? It's a *very* hairy process, best left to dedicated tools (f.g., buildroot), that no-one not actually building a distro should ever need to go through.

Last edited by NiLuJe; 03-27-2019 at 12:07 PM.
NiLuJe is offline   Reply With Quote
Reply

Tags
compile, crosscompile, examples, source code


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Setting up a development environment ... BWinmill Kobo Developer's Corner 27 06-16-2014 08:21 AM
help set up development environment? brianinmaine Kindle Developer's Corner 7 01-19-2014 08:23 AM
Problem with creating the development environment rozen Calibre 6 05-29-2011 11:38 PM
setup development environment JeffElkins Calibre 21 10-22-2008 03:25 PM
Setting up development environment tompe OpenInkpot 9 08-27-2008 02:26 PM


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


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