[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

7.15 Using getopt(3C)

There is a template named, ‘getopt.tpl’ that is distributed with AutoOpts. Using that template instead of ‘options.tpl’ will produce completely independent source code that will parse command line options. It will utilize either the standard getopt(3C) or the GNU getopt_long(3GNU) function to drive the parsing. Which is used is selected by the presence or absence of the long-opts program attribute. It will save you from being dependent upon the libopts library and it produces code ready for internationalization. However, it also carries with it some limitations on the use of AutoOpts features and some requirements on the build environment.


This document was generated by Bruce Korb on October 16, 2013 using texi2html 1.82.