]> git.ipfire.org Git - thirdparty/ntp.git/commitdiff
Libopts-5.17.1pre14 update
authorHarlan Stenn <stenn@ntp.org>
Sun, 6 Jan 2013 11:26:49 +0000 (06:26 -0500)
committerHarlan Stenn <stenn@ntp.org>
Sun, 6 Jan 2013 11:26:49 +0000 (06:26 -0500)
bk: 50e95f79D95LWJMVmrr6FR-KWCCU2A

sntp/libopts/autoopts/options.h
sntp/libopts/autoopts/project.h
sntp/libopts/autoopts/usage-txt.h
sntp/libopts/compat/compat.h
sntp/libopts/compat/windows-config.h
sntp/libopts/m4/libopts.m4
sntp/libopts/m4/liboptschk.m4

index 73b491e518f72e9b8e90a43f5fd26a4557e8f8f3..4c0a26f005a427d510e39f1d4f8d9a7aa9b830ef 100644 (file)
@@ -2,14 +2,14 @@
  *  
  *  DO NOT EDIT THIS FILE   (options.h)
  *  
- *  It has been AutoGen-ed  December 27, 2012 at 12:59:05 PM by AutoGen 5.17.0pre12
+ *  It has been AutoGen-ed  January  4, 2013 at 04:15:49 PM by AutoGen 5.17.1pre14
  *  From the definitions    funcs.def
  *  and the template file   options_h
  *
  *  This file defines all the global structures and special values
  *  used in the automated option processing library.
  *
- *  Automated Options Copyright (C) 1992-2012 by Bruce Korb
+ *  Automated Options Copyright (C) 1992-2013 by Bruce Korb
  *
  *   *  AutoOpts is free software: you can redistribute it and/or modify it
  *  under the terms of the GNU Lesser General Public License as published
 // END-CONFIGURED-HEADERS
 
 /**
- * Defined to normal value of EX_USAGE.  Used to indicate that paged usage
+ * Defined to abnormal value of EX_USAGE.  Used to indicate that paged usage
  * was requested.  It is used to distinguish a --usage from a --help request.
  * --usage is abbreviated and --help gives as much help as possible.
  */
 #define AO_EXIT_REQ_USAGE 10064
 
-/*
+/**
  *  PUBLIC DEFINES
  *
  *  The following defines may be used in applications that need to test the
  *  See the relevant generated header file to determine which and what
  *  values for "opt_name" are available.
  */
-#define OPTIONS_STRUCT_VERSION      151552
-#define OPTIONS_VERSION_STRING      "37:0:12"
+#define OPTIONS_STRUCT_VERSION      151553
+#define OPTIONS_VERSION_STRING      "37:1:12"
 #define OPTIONS_MINIMUM_VERSION     102400
 #define OPTIONS_MIN_VER_STRING      "25:0:0"
+#define OPTIONS_DOTTED_VERSION      "37.1"
 #define OPTIONS_VER_TO_NUM(_v, _r)  (((_v) * 4096) + (_r))
 
+/**
+ * Option argument types.  This must fit in the OPTST_ARG_TYPE_MASK
+ * field of the fOptState field of an option descriptor (tOptDesc).
+ * It will be a problem to extend beyond 4 bits.
+ */
 typedef enum {
-    OPARG_TYPE_NONE             =  0,
-    OPARG_TYPE_STRING           =  1,    /* default type/ vanilla string      */
-    OPARG_TYPE_ENUMERATION      =  2,    /* opt arg is an enum (keyword list) */
-    OPARG_TYPE_BOOLEAN          =  3,    /* opt arg is boolean-valued         */
-    OPARG_TYPE_MEMBERSHIP       =  4,    /* opt arg sets set membership bits  */
-    OPARG_TYPE_NUMERIC          =  5,    /* opt arg is a long int             */
-    OPARG_TYPE_HIERARCHY        =  6,    /* option arg is hierarchical value  */
-    OPARG_TYPE_FILE             =  7,    /* option arg names a file           */
-    OPARG_TYPE_TIME             =  8,    /* opt arg is a time duration        */
-    OPARG_TYPE_FLOAT            =  9,    /* opt arg is a floating point num   */
-    OPARG_TYPE_DOUBLE           = 10,    /* opt arg is a double prec. float   */
-    OPARG_TYPE_LONG_DOUBLE      = 11,    /* opt arg is a long double prec.    */
-    OPARG_TYPE_LONG_LONG        = 12     /* opt arg is a long long int        */
+    OPARG_TYPE_NONE         =  0, /**< does not take an argument         */
+    OPARG_TYPE_STRING       =  1, /**< default type/ vanilla string      */
+    OPARG_TYPE_ENUMERATION  =  2, /**< opt arg is an enum (keyword list) */
+    OPARG_TYPE_BOOLEAN      =  3, /**< opt arg is boolean-valued         */
+    OPARG_TYPE_MEMBERSHIP   =  4, /**< opt arg sets set membership bits  */
+    OPARG_TYPE_NUMERIC      =  5, /**< opt arg is a long int             */
+    OPARG_TYPE_HIERARCHY    =  6, /**< option arg is hierarchical value  */
+    OPARG_TYPE_FILE         =  7, /**< option arg names a file           */
+    OPARG_TYPE_TIME         =  8, /**< opt arg is a time duration        */
+    OPARG_TYPE_FLOAT        =  9, /**< opt arg is a floating point num   */
+    OPARG_TYPE_DOUBLE       = 10, /**< opt arg is a double prec. float   */
+    OPARG_TYPE_LONG_DOUBLE  = 11, /**< opt arg is a long double prec.    */
+    OPARG_TYPE_LONG_LONG    = 12  /**< opt arg is a long long int        */
 } teOptArgType;
 
+/**
+ * value descriptor for sub options
+ */
 typedef struct optionValue {
-    teOptArgType        valType;
-    char*               pzName;
+    teOptArgType        valType;        /**< which argument type    */
+    char *              pzName;         /**< name of the sub-option */
     union {
-        char            strVal[1];      /* OPARG_TYPE_STRING      */
-        unsigned int    enumVal;        /* OPARG_TYPE_ENUMERATION */
-        unsigned int    boolVal;        /* OPARG_TYPE_BOOLEAN     */
-        unsigned long   setVal;         /* OPARG_TYPE_MEMBERSHIP  */
-        long            longVal;        /* OPARG_TYPE_NUMERIC     */
-        void*           nestVal;        /* OPARG_TYPE_HIERARCHY   */
+        char            strVal[1];      /**< OPARG_TYPE_STRING      */
+        unsigned int    enumVal;        /**< OPARG_TYPE_ENUMERATION */
+        unsigned int    boolVal;        /**< OPARG_TYPE_BOOLEAN     */
+        unsigned long   setVal;         /**< OPARG_TYPE_MEMBERSHIP  */
+        long            longVal;        /**< OPARG_TYPE_NUMERIC     */
+        void*           nestVal;        /**< OPARG_TYPE_HIERARCHY   */
     } v;
 } tOptionValue;
 
+/**
+ * file argument state and handling.
+ */
 typedef enum {
-    FTYPE_MODE_MAY_EXIST        = 0x00,
-    FTYPE_MODE_MUST_EXIST       = 0x01,
-    FTYPE_MODE_MUST_NOT_EXIST   = 0x02,
-    FTYPE_MODE_EXIST_MASK       = 0x03,
-    FTYPE_MODE_NO_OPEN          = 0x00,
-    FTYPE_MODE_OPEN_FD          = 0x10,
-    FTYPE_MODE_FOPEN_FP         = 0x20,
-    FTYPE_MODE_OPEN_MASK        = 0x30
+    FTYPE_MODE_MAY_EXIST        = 0x00, /**< may or may not exist */
+    FTYPE_MODE_MUST_EXIST       = 0x01, /**< must pre-exist       */
+    FTYPE_MODE_MUST_NOT_EXIST   = 0x02, /**< must *not* pre-exist */
+    FTYPE_MODE_EXIST_MASK       = 0x03, /**< mask for these bits  */
+    FTYPE_MODE_NO_OPEN          = 0x00, /**< leave file closed    */
+    FTYPE_MODE_OPEN_FD          = 0x10, /**< call open(2)         */
+    FTYPE_MODE_FOPEN_FP         = 0x20, /**< call fopen(3)        */
+    FTYPE_MODE_OPEN_MASK        = 0x30  /**< open/fopen/not open  */
 } teOptFileType;
 
+/**
+ * the open flag bits or the mode string, depending on the open type.
+ */
 typedef union {
-    int             file_flags;
-    char const *    file_mode;
+    int             file_flags;  /**< open(2) flag bits    */
+    char const *    file_mode;   /**< fopen(3) mode string */
 } tuFileMode;
 
 typedef struct argList tArgList;
@@ -146,7 +161,7 @@ struct argList {
     char const *    apzArgs[MIN_ARG_ALLOC_CT];
 };
 
-/*
+/**
  *  Bits in the fOptState option descriptor field.
  */
 
@@ -250,7 +265,7 @@ typedef uint32_t opt_state_mask_t;
  *  and may be subject to change.
  */
 
-/*
+/**
  *  Define the processing state flags
  */
 
@@ -335,6 +350,11 @@ typedef tUsageProc * tpUsageProc;
 #define OPTION_LIMIT     SHRT_MAX
 #define NO_EQUIVALENT    (OPTION_LIMIT+1)
 
+/**
+ * Option argument value.  Which is valid is determined by:
+ * (fOptState & OPTST_ARG_TYPE_MASK) >> OPTST_ARG_TYPE_SHIFT
+ * which will yield one of the teOptArgType values.
+ */
 typedef union {
     char const *    argString;
     uintptr_t       argEnum;
@@ -366,7 +386,7 @@ struct optDesc {
 
     opt_state_mask_t        fOptState;        /* PUBLIC */
     unsigned int            reserved;
-    opt_arg_union_t          optArg;           /* PUBLIC */
+    opt_arg_union_t         optArg;           /* PUBLIC */
     void *                  optCookie;        /* PUBLIC */
 
     int const  * const      pOptMust;
index c0df391bc164f85dea4452e2433e1bc4ea323a4f..573616d264b9a9531450c36b87dae24bcddfd7ec 100644 (file)
@@ -1,4 +1,28 @@
 
+/**
+ * \file project.h
+ *
+ *  This file is part of AutoOpts, a companion to AutoGen.
+ *  AutoOpts is free software.
+ *  AutoOpts is Copyright (C) 1992-2013 by Bruce Korb - all rights reserved
+ *
+ *  AutoOpts is available under any one of two licenses.  The license
+ *  in use must be one of these two and the choice is under the control
+ *  of the user of the license.
+ *
+ *   The GNU Lesser General Public License, version 3 or later
+ *      See the files "COPYING.lgplv3" and "COPYING.gplv3"
+ *
+ *   The Modified Berkeley Software Distribution License
+ *      See the file "COPYING.mbsd"
+ *
+ *  These files have the following md5sums:
+ *
+ *  43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3
+ *  06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3
+ *  66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd
+ */
+
 #ifndef AUTOGEN_PROJECT_H
 #define AUTOGEN_PROJECT_H
 
@@ -48,3 +72,4 @@ typedef int tSuccess;
 #endif
 
 #endif /* AUTOGEN_PROJECT_H */
+/* end of project.h */
index 5f911b162d289d8bb6e023d6ca857d9d9cfbf4e8..58376b763475f5eed888f66994ff362035dd6ca7 100644 (file)
@@ -2,7 +2,7 @@
  *  
  *  DO NOT EDIT THIS FILE   (usage-txt.h)
  *  
- *  It has been AutoGen-ed  December 27, 2012 at 12:59:03 PM by AutoGen 5.17.0pre12
+ *  It has been AutoGen-ed  January  4, 2013 at 04:15:47 PM by AutoGen 5.17.1pre14
  *  From the definitions    usage-txt.def
  *  and the template file   usage-txt.tpl
  *  @file usage-txt.h
@@ -14,7 +14,7 @@
  *  they may substitute translated strings using a procedure that steps through
  *  all the string pointers.
  *
- *  Copyright (C) 1992-2012 Bruce Korb, all rights reserved.
+ *  Copyright (C) 1992-2013 Bruce Korb, all rights reserved.
  *  This is free software. It is licensed for use, modification and
  *  redistribution under the terms of the
  *  GNU Lesser General Public License, version 3 or later
@@ -233,7 +233,7 @@ char const option_lib_text[4660] =
 /*   260 */ "\tThis is less than the minimum library version:  \0"
 /*   310 */ "strdup of %d byte string failed\n\0"
 /*   343 */ "Automated Options version %s\n"
-            "\tcopyright (c) 1999-2012 by Bruce Korb - all rights reserved\n\0"
+            "\tCopyright (C) 1999-2013 by Bruce Korb - all rights reserved\n\0"
 /*   434 */ "AutoOpts lib error: defaulted to option with optional arg\n\0"
 /*   493 */ "(AutoOpts bug):  Aliasing option is out of range.\0"
 /*   543 */ "all\0"
@@ -451,9 +451,9 @@ static void dummy_func(void) {
   puts(_("\tThis is less than the minimum library version:  "));
 #line 77 "../autoopts.c"
   puts(_("strdup of %d byte string failed\n"));
-#line 122 "../version.c"
+#line 120 "../version.c"
   puts(_("Automated Options version %s\n"
-       "\tcopyright (c) 1999-2012 by Bruce Korb - all rights reserved\n"));
+       "\tCopyright (C) 1999-2013 by Bruce Korb - all rights reserved\n"));
 #line 585 "../find.c"
   puts(_("AutoOpts lib error: defaulted to option with optional arg\n"));
 #line 53 "../alias.c"
@@ -480,7 +480,7 @@ static void dummy_func(void) {
   puts(_("version, usage and configuration options:"));
 #line 266 "../makeshell.c"
   puts(_("Error %d (%s) from the pipe(2) syscall\n"));
-#line 162 "../version.c"
+#line 160 "../version.c"
   puts(_("ERROR: version option argument '%c' invalid.  Use:\n"
        "\t'v' - version only\n"
        "\t'c' - version and copyright\n"
@@ -640,17 +640,17 @@ static void dummy_func(void) {
   puts(_("Write failure to output file"));
 #line 307 "../usage.c"
   puts(_("Write failure to output file"));
-#line 168 "../version.c"
+#line 166 "../version.c"
   puts(_("Write failure to output file"));
 #line 701 "../usage.c"
   puts(_(" - reading file %s"));
 #line 302 "../usage.c"
   puts(_("\n"
        "please send bug reports to:  %s\n"));
-#line 106 "../version.c"
+#line 104 "../version.c"
   puts(_("\n"
        "please send bug reports to:  %s\n"));
-#line 128 "../version.c"
+#line 126 "../version.c"
   puts(_("\n"
        "please send bug reports to:  %s\n"));
 #line 673 "../usage.c"
index 714e9e472b0caad41366e8855cff632d891bcc27..73ee3892ff41af9b1a469561637557a1b625dce6 100644 (file)
@@ -6,7 +6,7 @@
  *  compat.h is free software.
  *  This file is part of AutoGen.
  *
- *  AutoGen Copyright (c) 1992-2012 by Bruce Korb - all rights reserved
+ *  AutoGen Copyright (C) 1992-2013 by Bruce Korb - all rights reserved
  *
  *  AutoGen is free software: you can redistribute it and/or modify it
  *  under the terms of the GNU General Public License as published by the
index 0b88a478144326f21c39f7245f9789fc7eabbbce..e21ba6ed05800a3b38b0ee472512465b0cdfaf95 100644 (file)
@@ -9,7 +9,7 @@
  *
  *  This file is part of AutoOpts, a companion to AutoGen.
  *  AutoOpts is free software.
- *  AutoOpts is Copyright (c) 1992-2012 by Bruce Korb - all rights reserved
+ *  AutoOpts is Copyright (C) 1992-2013 by Bruce Korb - all rights reserved
  *
  *  AutoOpts is available under any one of two licenses.  The license
  *  in use must be one of these two and the choice is under the control
index 8c361ae9b210e478eda7eeeac4a8ed6b16e27a4a..e1ff2ba651feec38eeace09fa4509b725d865fe5 100644 (file)
@@ -2,7 +2,7 @@ dnl  -*- buffer-read-only: t -*- vi: set ro:
 dnl 
 dnl DO NOT EDIT THIS FILE   (libopts.m4)
 dnl 
-dnl It has been AutoGen-ed  December 27, 2012 at 12:58:55 PM by AutoGen 5.17.0pre12
+dnl It has been AutoGen-ed  January  4, 2013 at 04:15:39 PM by AutoGen 5.17.1pre14
 dnl From the definitions    libopts.def
 dnl and the template file   conftest.tpl
 dnl
@@ -449,7 +449,7 @@ dnl the config tests that the library needs.  Invoke the
 dnl "INVOKE_LIBOPTS_MACROS" macro iff we are building libopts.
 dnl
 dnl  This file is part of AutoGen.
-dnl  AutoGen Copyright (c) 1992-2012 by Bruce Korb - all rights reserved
+dnl  AutoGen Copyright (C) 1992-2013 by Bruce Korb - all rights reserved
 dnl
 dnl  AutoGen is free software: you can redistribute it and/or modify it
 dnl  under the terms of the GNU General Public License as published by the
index de0d0d801aa418a77cfda65c4f79678f4bf47bee..b607191bec2f791774b680fb66d127f762a9e232 100644 (file)
@@ -1,5 +1,5 @@
 # liboptschk.m4 serial 2 (autogen - 5.11.4)
-dnl Copyright (c) 2005-2012 by Bruce Korb - all rights reserved
+dnl Copyright (C) 2005-2013 by Bruce Korb - all rights reserved
 dnl
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,