Under latest Cygwin 1.7:
$ ../configure
libtool: compile: gcc -c -DHAVE_CONFIG_H -Wall -Werror -g -O2 -DMAA_MAJOR=1 -DMAA_MINOR=3 -DMAA_TEENY=0 -I. -I.. ../xmalloc.c -DDLL_EXPORT -DPIC -o .libs/xmalloc.o
cc1: warnings being treated as errors
In file included from ../xmalloc.c:22:
../maaP.h:115: error: 'optind' redeclared without dllimport attribute: previous dllimport ignored
../maaP.h:116: error: 'optarg' redeclared without dllimport attribute: previous dllimport ignored
This code cause error:
/* Handle getopt correctly */
#if HAVE_GETOPT_H
# include <getopt.h>
#endif
#if !defined(HAVE_GETOPT)
extern int getopt( int, char * const *, const char * );
#endif
extern int optind;
extern char *optarg;
When I comment
/* extern int optind; */
/* extern char *optarg; */
build complete successful.
I use libmaa-1.3.0.tar.gz in order to build dictd under Cygwin.
I miss:
$ make
command...
I could not reproduce the problem on cygwin-1.7.1
but I hope I've just fixed the problem in maaP.h revision 1.41.
Thanks!