View Single Post
Old 12-24-2019, 05:56 AM   #407
Marco77
Connoisseur
Marco77 can illuminate an eclipseMarco77 can illuminate an eclipseMarco77 can illuminate an eclipseMarco77 can illuminate an eclipseMarco77 can illuminate an eclipseMarco77 can illuminate an eclipseMarco77 can illuminate an eclipseMarco77 can illuminate an eclipseMarco77 can illuminate an eclipseMarco77 can illuminate an eclipseMarco77 can illuminate an eclipse
 
Posts: 55
Karma: 8430
Join Date: Mar 2016
Device: PW3, Clara HD, PB740
Question

Quote:
Originally Posted by ps67 View Post
Is it possible a patch to have indentation levels in index? I know that Kobo index is flatten by design and I don't know if that behavior can be changed with a patch, but if:

1) it is not too difficult (like hours of work);
2) it is funny for You to do the patch;
3) You have time to do it;

I would like to see how could appear a patched index.

Quote:
Originally Posted by geek1011 View Post

Probably not at the moment, unless I end up writing a tool for injecting significant amounts of additional assembly (it would involve finding enough contiguous free space and possibly messing with the ELF table).
Hi @geek1011
Is the LD_PRELOAD trick the way you found to achieve that? It has the additional advantage you don't even have to write everything in assembly but also plain C.
OTOH, user code is only executed while hooking existing symbols, but there should be a workaround for that.

My other question, since we're in developer's corner, what is the usual workflow when you create a new/custom patch? It has the risk of loop-crashing the nickel process, am I correct? Are there provisions to put back the device in workable state in such occurrences?

Can you for instance:
  1. Enable remote access to the device (telnet/SSH, USBnet maybe) so that it automatically runs at device startup
  2. tweak the libpath of whatever controls the .so load order, using a KoboRoot.tgz to a path controlled by the telnet/ssh user (supposedly, not root)
  3. drop the modified .so's in that path
  4. In case of emergency, delete the overriding .so either by SSHing into the device, or prying the device open, mount its microsd in a PC and remove the file from partition 3
    If things go awry, reflashing (what) via recovery? put vanilla update zip in .kobo? In worst case, reimage the microSD using a backup?

Last edited by Marco77; 12-24-2019 at 06:08 AM. Reason: fmt
Marco77 is offline   Reply With Quote