Just recompiled the kernel config I'm using with that ncurses menu included as a dynamically linked (i.e. copied over the bin as-is and also copied over the libs) and that booted/ran ok. That was within initrd, i.e. was run within a setsid cttyhack child process within init, that when exited out of resumes pid 1 (normal init/console). The reason I use the setsid cttyhack for tty/pseudo terminal is to enable job control (screen/background tasks etc.) that otherwise (console) isn't available. I originally coded that ncurses menu to just show the menu, and exit with a exit string of whatever option was selected, and I have a wrapper script that loops around showing the menu, trapping the selected return text (requested action string) in a case statement, and launching the associated action for that, before re-showing the menu again. As-is that menu is fixed (as compiled into the C program), but relatively easy to change and recompile. With the ncurses program and libs added it expanded the vmlinuz to 12MB (around 360KB larger compared to without the ncurses program/libs).sc0ttman wrote:A simple "main menu" or "welcome menu" ncurses script, which offers easy ways to run various system tools (puppy-config stuff I mentioned above), or recovery scripts (fsck, etc) would make the CLI/terminal experience in Puppy about as easy as any other distro.
.. Kind of separately..
It would be great to have ncurses working as early in the boot process as possible, although I've no idea if it can work in the initrd.
I am biased but if nrcurses does work in the initrd, I'd like to see Pkg (and ncurses) work even from inside the initrd, so that Pkg (and Pkgdialog) can be used even before mounting the main filesystem (rootfs)...
That is without mouse point/click functionality. You have to (the way it is coded i.e. mirrors mc type controls) press F9 to activate the menu and then the first letter of whatever highlighted choice you want to run, or use the arrow keys to navigate/enter to select.
Fatdog has slapt-get cli based package manager alongside gslapt (gui based package manager), so along with wifi net connected I guess that could also be run within init. However I haven't actually tried that.
My vmlinuz is compiled to be very machine specific, but no reason why that couldn't be bloated out by including modules/firmware for a wide range of hardware. Doing so however would expand the size considerably and in that case it would perhaps be best to have initramfs_data.cpio (initrd) outside of vmlinuz. I suspect however that you'd be looking at something like a 80MB system. At that sort of size you might as well just use a bare-bone type puppy as a early stage init boot (something like a xvesa type puppy), do whatever configuration/action you desired within that before exiting to resume init/pid 1 and boot the main/full puppy.