Hello Ben,
I have been looking through the Genode run scripts, and it seems that init will only look in the root of a ROM for both libraries and binaries. It would be very useful to be able to search for binaries and libraries in multiple directories (e.g. /lib, /usr/lib, /bin, /usr/bin, etc.) Also, is there a way to separate the library and binary directories without hacking init? If not, how hard would it be to hack init to add this feature?
I would advise against changing init. If you want to fetch libraries from different portions of a file system or from different file systems, I recommend you to create a more sophisticated version of fs_rom, which does not use a single file-system session but multiple. Let me call it "multi_fs_rom" for now. The ROM modules will still be requested by their plain names. The multi_fs_rom service will scan the search locations for files with the supplied name and hand out the file content as a dataspace. This way, you can keep libraries and executables at arbitrary places.
To let CLI monitor use your multi_fs_rom service instead of obtaining ROM modules from core, add the following line at the beginning of the routing configuration of cli_monitor:
<service name="ROM"> <child name="multi_fs_rom"/> </service>
It looks like it is time to develop your first ROM service. :-)
Cheers Norman