diff options
author | Aaron Plattner <aplattner@nvidia.com> | 2008-02-12 21:06:48 -0800 |
---|---|---|
committer | Aaron Plattner <aplattner@nvidia.com> | 2008-02-12 21:06:48 -0800 |
commit | 62e3914fdaac08d83e07e0ac786de4c273a3fdb5 (patch) | |
tree | d8eb142e29179b6085f70686efe36d1da794fe5a /src/command-line.c | |
parent | edd7bf5b8a4073387e4dad37269572ec4d1b6a59 (diff) |
1.0-71671.0-7167
Diffstat (limited to 'src/command-line.c')
-rw-r--r-- | src/command-line.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/src/command-line.c b/src/command-line.c index 95cc14b..fe262ba 100644 --- a/src/command-line.c +++ b/src/command-line.c @@ -34,6 +34,9 @@ #include "query-assign.h" #include "msg.h" #include "nvgetopt.h" +#include "glxinfo.h" + +#include "NvCtrlAttributes.h" #define TAB " " @@ -78,6 +81,9 @@ static void print_version(void) * flags - bitmask; possible values are NVGETOPT_HAS_ARGUMENT and * NVGETOPT_IS_BOOLEAN * + * description function - function to call to display description + * through nv_msg() + * * description - text for use by print_help() to describe the option */ @@ -107,6 +113,9 @@ static const NVGetoptOption __options[] = { { "assign", 'a', NVGETOPT_HAS_ARGUMENT, print_assign_help, NULL }, { "query", 'q', NVGETOPT_HAS_ARGUMENT, print_query_help, NULL }, + + { "glxinfo", 'g', 0, NULL, + "Print GLX Information for the X display and exit." }, { NULL, 0, 0, 0 }, }; @@ -216,9 +225,6 @@ void print_help(void) } /* print_help() */ - - - /* * parse_command_line() - malloc an Options structure, initialize it * with defaults, and fill in any pertinent data from the commandline @@ -272,6 +278,7 @@ Options *parse_command_line(int argc, char *argv[], char *dpy) op->num_queries++; break; case CONFIG_FILE_OPTION: op->config = strval; break; + case 'g': print_glxinfo(NULL); exit(0); break; default: nv_error_msg("Invalid commandline, please run `%s --help` " "for usage information.\n", argv[0]); |