Originally Posted by yifanlu
I'm going to throw some ideas around about a kindle packaging system. I have two problems with kindle hacks. First, install and uninstalling hacks are messy. Install scripts could modify any files and there isn't a system of where data/binaries should be stored. Also, it's hard to keep up with all the installers/uninstallers and versionings. And using kindle's update system could seem confusing to new users as they think they're upgrading. The second problem is we don't have a nice, GUI, launcher. I'm thinking of using the debian packaging system, but I don't want to modify rootfs if I could prevent it. I was thinking of a custom package structure where to install an app, you copy a folder to the "packages" folder on the kindle or something. In that folder will be an startup script, a shutdown script, a run on demand script, and stop on demand script (optional). It would also contain it's own data in that folder. We only install one startup script to the kindle when jail breaking and that script loads all hacks on startup. To uninstall, just delete the folder for the package. And second, someone (maybe me) could write an app launcher that is activated by a shortcut key or gesture.
The package structure could be like:
And so on.
Can developers give some feedback about this?
This is exactly what I'm thinking of now. My idea is about doing it manually.
So why doesn't a preset package management system fit Kindle? It's simply too heavy to maintain. As you said, rootfs is useless. While gentoo-prefix won't bother you with rootfs, it is unacceptable in size (20x in size of general kindle apps).
A PMS is actually a tool chain about filesystem tree layout, with versioning tools like git/hg/svn included. The trick is to proceed metadata well and keep files organized. Am I going to run, say `apt get update` on my kindle? I don't think so. The most frequent senario is to connect kindle with pc then sync with, what you said, a GUI application.
Since executing commands from kindle is unnecessary, why not consider kindle as an output directory? Thus the problem becomes, that we need a PMS on pc only and kindle is just a local branch. Every install/uninstall/upgrade/reverse operation can be seen as one synchronisation with local repos.
An invisible advantage will be, that library management can be integrated into this sync tool flawlessly.
About the launcher, an official implementation (the one shipped with jailbreak package) is preferable. This concerns usability and only in this way can you control the init/halt of kindle apps. You can make some rules before a 3rd app can be listed in your launcher, for example, config file location etc. I'm not talking about auditing, but I do consider double-way user-friendly design between jailbreakers and app-developers.
In my design, a slim version of PMS just has to do something right,
1. filesystem layout, I totally agree with you about filesystem layout. Technically it is done by adding a global $PREFIX="/packages/" in scripts.
2. dependency, I don't know if it matters as most kindle apps are independent.
3. versioning, a simple cut/copy/paste works well I think, especially when configurations are preserved in separate directories.
In summary, I imagine this PMS for kindle to be mainly an application on pc. If it is written by c/python, it's probably naturally cross platformed.
Here is a link
to gentoo's pms specifications if you are interested.