Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sources DOT redhat DOT com Delivered-To: mailing list cygwin AT sources DOT redhat DOT com From: "Gerrit P. Haase" Organization: Esse keine toten Tiere To: Ted Fong Date: Thu, 20 Sep 2001 23:50:51 +0200 MIME-Version: 1.0 Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7BIT Subject: Re: Compile error with rsync-2.4.6 and latest Cygwin Reply-to: gp AT familiehaase DOT de CC: cygwin AT cygwin DOT com Message-ID: <3BAA80DB.26081.349BEA3F@localhost> In-reply-to: X-mailer: Pegasus Mail for Win32 (v3.12cDE) X-Hops: 1 X-Sender: 320081107336-0001 AT t-dialin DOT net Ted Fong schrieb am 2001-09-20, 16:02: >Hello, > >My environment is NT 4.0 with the version of Cygwin downloaded 2001Sep20 >(see cygcheck output below). Install of Cygwin was "default" - no changes >to environment settings. > >Receiving this error when compiling rsync-2.4.6: > >$ make >gcc -I. -I. -O -c lib/getopt.c -o lib/getopt.o >lib/getopt.c: In function `getopt_long': >lib/getopt.c:672: argument `argv' doesn't match prototype >/usr/include/getopt.h:56: prototype declaration >lib/getopt.c:672: argument `options' doesn't match prototype >/usr/include/getopt.h:56: prototype declaration >lib/getopt.c:672: argument `long_options' doesn't match prototype >/usr/include/getopt.h:56: prototype declaration >make: *** [lib/getopt.o] Error 1 /usr/include/getopt.h should not be included if you don't have the cygwin getopt_long version patched. I got another error, because lib/getopt.h gets included and then /usr/include/getopt/h gets included by unistd.h. I have my unistd.h patched because it is causing trouble since lots of packages contains their own getopt.c / getopt.h like rsync, too. Now Have you logged the output of configure? There should be included this line: checking for working getopt_long... no Now if that is the case, lib/getopt.h gets included. Here is how i patched /usr/include/unistd.h to get around this problem: /* unistd.h for Cygwin. */ #ifndef _UNISTD_H_ #define _UNISTD_H_ # include #if !defined(__GETOPT_H__) && !defined(_GETOPT_H) # include #endif #endif /* _UNISTD_H_ */ Ciao, Gerrit -- =^..^= -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/