public static void main (String argv [])
    {
	try {
	    
	    // FIXME: error diagnostics via {/usr/bin,...}/logger

	    if (argv.length != 1) {
		System.err.println ("USBD [ start | stop ]");
		System.exit (1);
	    }

	    if ("start".equals (argv [0])) {
		Host	host = HostFactory.getHost ();

		if (host == null) {
		    System.err.println ("USBD:  USB is not available.");
		    System.exit (1);
		}

		// don't chain proxies till we can prevent loops
		if (host instanceof Remote) {
		    System.err.println ("USBD: proxy already registered");
		    System.exit (1);

		    // FIXME: check to see if it's usable, then
		    // normally rebind
		}

		// Export our host services via RMI
		try {
		    HostProxy	proxy = new HostProxy (host);
		    Naming.bind (rmiName, proxy);
		    System.err.println ("USBD:  Bound RMI name " + rmiName);
		} catch (Exception e) {
		    System.err.println ("USBD:  Couldn't bind to: " + rmiName);
		    if (debug)
			e.printStackTrace ();
		    else
			System.err.println (e.getMessage ());
		}


	    } else if ("stop".equals (argv [0])) {

		// FIXME get the daemon to set 'done'
		// publish our URI in some file (config state)

		System.err.println ("USBD: no 'stop' yet ... "
			+ "use 'ps' and 'kill' for now");
	    
	    // and status query

	    } else {
		System.err.println ("USBD: no '" + argv [0] + "' command");
		System.exit (1);
	    }

	} catch (Exception e) {
	    if (debug)
		e.printStackTrace ();
	    else
		System.err.println (e.getMessage ());
	}
    }