-static struct option options[] = {
- { "nodaemon", 0, 0, 'n' },
- { "compat", 0, 0, 'c' },
- { "help", 0, 0, 'h' },
- { }
+static gchar *option_device = NULL;
+static gboolean option_detach = TRUE;
+static gboolean option_compat = FALSE;
+static gboolean option_debug = FALSE;
+
+static GOptionEntry options[] = {
+ { "device", 'i', 0, G_OPTION_ARG_STRING, &option_device,
+ "Specify network device/interface", "DEV" },
+ { "nodaemon", 'n', G_OPTION_FLAG_REVERSE,
+ G_OPTION_ARG_NONE, &option_detach,
+ "Don't fork daemon to background" },
+ { "compat", 'c', 0, G_OPTION_ARG_NONE, &option_compat,
+ "Enable Network Manager compatibility" },
+ { "debug", 'd', 0, G_OPTION_ARG_NONE, &option_debug,
+ "Enable debug information output" },
+ { NULL },