+/* *INDENT-OFF* */
+ struct option long_options[] = {
+ { "alt-autoscale", no_argument, 0, 'A'},
+ { "imgformat", required_argument, 0, 'a'},
+ { "font-smoothing-threshold", required_argument, 0, 'B'},
+ { "base", required_argument, 0, 'b'},
+ { "color", required_argument, 0, 'c'},
+ { "full-size-mode", no_argument, 0, 'D'},
+ { "daemon", required_argument, 0, 'd'},
+ { "slope-mode", no_argument, 0, 'E'},
+ { "end", required_argument, 0, 'e'},
+ { "force-rules-legend", no_argument, 0, 'F'},
+ { "imginfo", required_argument, 0, 'f'},
+ { "graph-render-mode", required_argument, 0, 'G'},
+ { "no-legend", no_argument, 0, 'g'},
+ { "height", required_argument, 0, 'h'},
+ { "no-minor", no_argument, 0, 'I'},
+ { "interlaced", no_argument, 0, 'i'},
+ { "alt-autoscale-min", no_argument, 0, 'J'},
+ { "only-graph", no_argument, 0, 'j'},
+ { "units-length", required_argument, 0, 'L'},
+ { "lower-limit", required_argument, 0, 'l'},
+ { "alt-autoscale-max", no_argument, 0, 'M'},
+ { "zoom", required_argument, 0, 'm'},
+ { "no-gridfit", no_argument, 0, 'N'},
+ { "font", required_argument, 0, 'n'},
+ { "logarithmic", no_argument, 0, 'o'},
+ { "pango-markup", no_argument, 0, 'P'},
+ { "font-render-mode", required_argument, 0, 'R'},
+ { "rigid", no_argument, 0, 'r'},
+ { "step", required_argument, 0, 'S'},
+ { "start", required_argument, 0, 's'},
+ { "tabwidth", required_argument, 0, 'T'},
+ { "title", required_argument, 0, 't'},
+ { "upper-limit", required_argument, 0, 'u'},
+ { "vertical-label", required_argument, 0, 'v'},
+ { "watermark", required_argument, 0, 'W'},
+ { "width", required_argument, 0, 'w'},
+ { "units-exponent", required_argument, 0, 'X'},
+ { "x-grid", required_argument, 0, 'x'},
+ { "alt-y-grid", no_argument, 0, 'Y'},
+ { "y-grid", required_argument, 0, 'y'},
+ { "lazy", no_argument, 0, 'z'},
+ { "units", required_argument, 0, LONGOPT_UNITS_SI},
+ { "alt-y-mrtg", no_argument, 0, 1000}, /* this has no effect it is just here to save old apps from crashing when they use it */
+ { "disable-rrdtool-tag",no_argument, 0, 1001},
+ { "right-axis", required_argument, 0, 1002},
+ { "right-axis-label", required_argument, 0, 1003},
+ { "right-axis-format", required_argument, 0, 1004},
+ { "legend-position", required_argument, 0, 1005},
+ { "legend-direction", required_argument, 0, 1006},
+ { "border", required_argument, 0, 1007},
+ { "grid-dash", required_argument, 0, 1008},
+ { "dynamic-labels", no_argument, 0, 1009},
+ { 0, 0, 0, 0}
+};
+/* *INDENT-ON* */
+
+ optind = 0;
+ opterr = 0; /* initialize getopt */
+ rrd_parsetime("end-24h", &start_tv);
+ rrd_parsetime("now", &end_tv);