| OS X - Development and Darwin Discussion and questions about development for Mac OS X. |
| Post Reply | New Thread | Subscribe |
|
|
Thread Tools |
![]() Member Since: Apr 18, 2009
Posts: 1
![]() |
Before the GUI comes up, output to /dev/console
presumably is visible as text. Afterward, _something_ apparently captures the output. Perhaps the Console app can show it too, although I must be missing it somehow. What I'd like to be able to do is intercept output to /dev/console; not preventing it from going wherever it goes now, but doing something with it, or at any rate some of it; namely, filtering it a bit (maybe) and popping up Growl notifications. What brought this on is having a mixed environment with both Solaris and Mac systems (well, one Mac) at home. For example, Solaris NFS servers will send a message using "rwall", which communicates via rpc to rpc.rwalld (which in turn uses wall(1) to write to all terminals). I ported rpc.rwalld from one of the BSDs to Mac OS X with the only difficulty due to the Mac's RPC APIs being different (and arguably lame). But a Growl message for that sort of thing would be the most friendly I thought about modifying rpc.rwalld, but then thought it better to move it down deeper. So I grabbed the Darwin source for wall(1), and thought about putting the Growl notifications in there. But then I thought, would it be _possible_ to solve this not only for "wall" messages, but for anything else that gets written to /dev/console too? I saw the TIOCCONS ioctl in tty(4), but that seems to suggest it only redirects kernel-originated messages, and running xterm -C as root, and within it, echo testing >/dev/console does _not_ show the text written to /dev/console. So I'm pretty much stumped as to how that's done. Any hints? ("dump all those non-Mac systems" is _not_ acceptable :-) |
| QUOTE Thanks | |
| Post Reply | New Thread | Subscribe |
| Thread Tools | |
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
|
|
|
|
|||||||
Thread |
Thread Starter |
Forum |
Replies |
Last Post |
| Managed to screw up my iTunes | MikeandDeni | OS X - Apps and Games | 2 | 04-09-2009 09:28 AM |
| I've managed the 'unmanageable'! | brianwmay | Switcher Hangout | 8 | 04-01-2008 05:22 PM |
| Managed Accounts Games don't work | MacFanBoy | OS X - Operating System | 0 | 01-19-2008 11:58 PM |
| AutoStart in a Managed Account | gadgetfreak | Switcher Hangout | 0 | 11-13-2006 08:34 AM |
All times are GMT -4. The time now is 02:54 AM.
Powered by vBulletin