View Single Post
Old 04-19-2012, 09:46 PM   #6
geekmaster
Carpe diem, c'est la vie.
geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.
 
geekmaster's Avatar
 
Posts: 6,430
Karma: 10764602
Join Date: Nov 2011
Location: Multiverse 6627A
Device: K1 to PW3
Version 1.1 of tcc works great on the K3, but on the K5(touch) it has a problem parsing one of the new load library scripts.
Code:
# cat /usr/lib/libc.so
/* GNU ld script
   Use the shared library, but some functions are only in
   the static library, so try that secondarily.  */
OUTPUT_FORMAT(elf32-littlearm)
GROUP ( /lib/libc.so.6 /usr/lib/libc_nonshared.a  AS_NEEDED ( /lib/ld-linux.so.3 ) )
Part of the problem is that although the /usr/lib/libc.so loader script included in newer kindles says to load libc_nonshared.a, that file does not actually exist on the kindle, so when you compile with tcc on a newer kindle, it fails with this error message:
tcc: file '/usr/lib/libc_nonshared.a' not found

So, I just solved this problem by bind-mounting a stripped-down libc.so script file that tcc knows how to parse. I added the script to the /mnt/us/tcc directory, and I added the mount and umount statements to the tccmake script. It works great.

I packaged that up into a v1.3 download package, available at the first post in this thread. This new version should work on all the kindles.


Last edited by geekmaster; 03-22-2016 at 05:21 PM.
geekmaster is offline   Reply With Quote