+/*
+ * name of the application
+ */
+static const char appname[] = "afm-user-daemon";
+
+/*
+ * string for printing usage
+ */
+static const char usagestr[] =
+ "usage: %s [-q] [-v] [-m mode] [-r rootdir]... [-a appdir]...\n"
+ "\n"
+ " -a appdir adds an application directory\n"
+ " -r rootdir adds a root directory of applications\n"
+ " -m mode set default launch mode (local or remote)\n"
+ " -d run as a daemon\n"
+ " -q quiet\n"
+ " -v verbose\n"
+ "\n";
+
+/*
+ * Option definition for getopt_long
+ */
+static const char options_s[] = "hdqvr:a:m:";
+static struct option options_l[] = {
+ { "root", required_argument, NULL, 'r' },
+ { "application", required_argument, NULL, 'a' },
+ { "mode", required_argument, NULL, 'm' },
+ { "daemon", no_argument, NULL, 'd' },
+ { "quiet", no_argument, NULL, 'q' },
+ { "verbose", no_argument, NULL, 'v' },
+ { "help", no_argument, NULL, 'h' },
+ { NULL, 0, NULL, 0 }
+};
+
+/*
+ * Connections to D-Bus
+ * This is an array for using the function
+ * jbus_read_write_dispatch_multiple
+ * directly without transformations.
+ */
+static struct jbus *jbuses[2];
+#define system_bus jbuses[0]
+#define user_bus jbuses[1]