add option-directory to optional compiled features

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
load config file recursively when a directory is specified to --options

If a directory is specified to --options, its directories which name
is ended with '.d" are traversed recursively and files ended with
.ctags or .conf are loaded.

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
introduce config file search path

ctags can load configration files which are specified with --options
option. A path for an existing file or directory was expected as
the argument for --options.

In this patch config file search path are introduced.  For argment of
--options, before searching existing fie or directory resolved
relatively from current working directpry, config file search path is
searched.

Currently config file search path can be specified with
CTAGS_DATA_PATH enviroment variable. Paths in CTAGS_DATA_PATH are
searched to load a configuration file. Like PATH enviroment variable,
the paths can be enumerated with `:' as a separator.

Let me describe following command line:

    $ cd /home/devel
    $ CTAGS_DATA_PATH=/a:/b ./ctags --options=x ...

To load x as configuration file (or directpry), ctags looks at /a/x
then /b/x. If x cannot be found, finally ctags looks at /home/devel/x.
If you want to load /home/deve/x anyway, use one of following command line:

    $ CTAGS_DATA_PATH=/a:/b ./ctags --options=./x ...

or

    $ CTAGS_DATA_PATH=/a:/b ./ctags --options=/home/devel/x ...

If a directory is givens as an argment for --options, files which
names are ended with ".ctags" or ".cnf" are loaded alphabetically
order. Loading are done in recursively; directories which names are
ended with ".d" are loaded, too.

TODO: update ctags.1.
Signed-off-by: Masatake YAMATO <yamato@redhat.com>
add unit test cases for config file search path

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
add regex parser for snmp mib definition

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
add a unit test case for mib parser

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
introduce corpus file search path

This is similar to the config file search path.

When --<LANG>-corpus is used to specify a corpus file, corpus file
search path is looked first.

Consider $path is a path enumerated on CTAGS_DATA_PATH environment
variable. Files under $path/corpora are looked at.

e.g.

	$ CTAGS_DATA_PATH=/a:/b ctags --foo-corpus=file.foo ...

To load file.foo, /a/corpora/file.foo is checked first. If it is not found,
then /b/corpora/file.foo is checked. If it is not found, ./file.foo is checked.

If you want to file.foo in the current working directly, use prefix "./"
like

	$ CTAGS_DATA_PATH=/a:/b ctags --foo-corpus=./file.foo ...

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
add corpus file for snmp mib parser

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
avoid NULL pointer deference in findTgTableEntry

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
print number of parser candidates before tg tournament if --verbose is given

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
improve help messages of tg command

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
add a test case for --<LANG>-corpus option

Signed-off-by: Masatake YAMATO <yamato@redhat.com>