delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
X-SWARE-Spam-Status: | No, hits=-3.0 required=5.0 tests=AWL,BAYES_00,KHOP_THREADED,RCVD_IN_DNSWL_NONE,RCVD_IN_HOSTKARMA_YE,TW_YG |
X-Spam-Check-By: | sourceware.org |
Subject: | Re: XOPEN_SOURCE and string.h |
Mime-Version: | 1.0 (Mac OS X Mail 6.2 \(1499\)) |
From: | Denis Excoffier <cygwin AT Denis-Excoffier DOT org> |
In-Reply-To: | <50F08B7A.8000900@gmail.com> |
Date: | Sat, 12 Jan 2013 00:50:05 +0100 |
Cc: | cygwin AT cygwin DOT com |
Message-Id: | <529F8785-F5F4-44F6-AAE1-B422E904073F@Denis-Excoffier.org> |
References: | <DB6397CD-79A6-428E-9B08-15365DC7BCF4 AT Denis-Excoffier DOT org> <50F08B7A DOT 8000900 AT gmail DOT com> |
To: | marco atzeri <marco DOT atzeri AT gmail DOT com> |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Id: | <cygwin.cygwin.com> |
List-Unsubscribe: | <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com> |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sourceware.org/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
X-MIME-Autoconverted: | from quoted-printable to 8bit by delorie.com id r0BNogiX008698 |
On 2013-01-11 23:00, marco atzeri wrote: > On 1/11/2013 10:47 PM, Denis Excoffier wrote: >> Hello, >> >> In order to compile some packages (including slang-2.2.4 and ccrypt-1.9) >> with GCC-4.7.2, i had to patch /usr/include/string.h iaw the following: >> >> >> diff -uNr x-o/usr/include/string.h x-p/usr/include/string.h >> --- x-o/usr/include/string.h 2012-11-23 14:40:09.000000000 +0100 >> +++ x-p/usr/include/string.h 2013-01-11 22:29:39.000000000 +0100 >> @@ -64,13 +64,13 @@ >> char *_EXFUN(strcasestr,(const char *, const char *)); >> char *_EXFUN(strchrnul,(const char *, int)); >> #endif >> -#if !defined(__STRICT_ANSI__) || (_XOPEN_SOURCE >= 500) >> +#if !defined(__STRICT_ANSI__) || ((_XOPEN_SOURCE - 0) >= 500) >> char *_EXFUN(strdup,(const char *)); >> #endif >> #ifndef __STRICT_ANSI__ >> char *_EXFUN(_strdup_r,(struct _reent *, const char *)); >> #endif >> -#if !defined(__STRICT_ANSI__) || (_XOPEN_SOURCE >= 700) >> +#if !defined(__STRICT_ANSI__) || ((_XOPEN_SOURCE - 0) >= 700) >> char *_EXFUN(strndup,(const char *, size_t)); >> #endif >> #ifndef __STRICT_ANSI__ >> >> >> >> See also /usr/include/sys/features.h. >> >> Otherwise i obtain the message: >> >> /usr/include/string.h:67:49: error: operator '>=' has no left operand >> /usr/include/string.h:73:49: error: operator '>=' has no left operand >> >> Hope this helps, >> >> Regards, >> >> Denis Excoffier. >> >> > > are you sure about that file ? Sure yes. It has been inside Cygwin snapshots since end of last December. It was introduced in newlib near the 22nd October 2012. I suppose that other occurrences of _XOPEN_SOURCE have to be checked. % cygcheck -f /usr/include/string.h cygwin-1.7.17-1 % uname -a CYGWIN_NT-5.1 jupiter 1.7.18s(0.263/5/3) 20130111 15:37:20 i686 Cygwin % See http://cygwin.com/ml/cygwin/2011-02/msg00534.html (and many others). Denis Excoffier. -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |