+ /* All of the various command-line options */
+ const GOptionEntry cl_opts[] = {
+ { "version", 'V', 0, G_OPTION_ARG_NONE, &version, N_("Show version information"), NULL },
+ { NULL },
+ };
+
+ /* Set up the command-line parser */
+ GError *error = NULL;
+ GOptionContext *context = g_option_context_new (NULL);
+ g_option_context_add_main_entries (context, cl_opts, NULL);
+ g_option_context_add_group (context, gtk_get_option_group (TRUE));
+ g_option_context_parse (context, &argc, &argv, &error);
+ g_option_context_free (context);
+
+ /* Check for unknown options, and give a nice message if there are some */
+ if (error)