Re: Leopard and scripts on startup
site_archiver@lists.apple.com Delivered-To: darwin-dev@lists.apple.com On Mar 19, 2008, at 10:48 AM, Geoff Lee wrote: Geoff, Geoff, int r, fd; revoke(_PATH_CONSOLE); fd = open(_PATH_CONSOLE, O_RDWR); assert(fd != -1); r = login_tty(fd); assert(r != -1); execl(_PATH_BSHELL, "-sh", NULL); _exit(EXIT_FAILURE); davez _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/site_archiver%40lists.appl... On 19 Mar 2008, at 17:15, Dave Zarzycki wrote: Any hints as to where to look for more information would be appreciated. I've scoured the Boot process documentation on Apple's site but the possibility of running without the window server doesn't really seem to be covered. As of Leopard, the console tty is no longer used or even setup during boot. You're going to have to do that yourself. Please also keep in mind that manipulating /dev/console is not a supported feature of the operating system. Thanks for your reply. So if I want to boot into a non-gui environment where I can take user input, what's the best way of going about it? I can now get the output from my script to display on the console using <StandardOutPath> /dev/console, but (presumably for the reasons you mention) I can't take any input (from a bash 'read'). Do I need to initialise the console with getty? Just being able to spawn a shell would be pretty useful at this point! I realise this is not going to be a supported configuration, but any insight/reading pointers would be gratefully received. The following unsupported code would let one (and only one) launchd job own/use /dev/console and run a shell. This email sent to site_archiver@lists.apple.com
participants (1)
-
Dave Zarzycki