#include #include #include #include #include #include "common.h" int main(int argc, char *argv[]) { char config_path[PATH_MAX]; int option; config_path[0] = '\0'; while ((option = getopt(argc, argv, "hvc:")) != -1) { switch (option) { case 'h': printf("Usage: %s [-h|-v|-c ]\n", argv0); exit(EXIT_SUCCESS); break; case 'v': printf("v" VERSION_STRING "\n"); exit(EXIT_SUCCESS); break; case 'c': strncpy(config_path, optarg, sizeof(config_path)); break; } } }