This is the mail archive of the
mailing list for the Cygwin project.
Re: python 2.7.12 pip install with extensions fails with warning: "__BSD_VISIBLE" redefined
- From: cyg Simple <cygsimple at gmail dot com>
- To: cygwin at cygwin dot com
- Date: Mon, 28 Nov 2016 17:41:28 -0500
- Subject: Re: python 2.7.12 pip install with extensions fails with warning: "__BSD_VISIBLE" redefined
- Authentication-results: sourceware.org; auth=none
- References: <20161128195259.GA2570@fedora.wp.comcast.net>
On 11/28/2016 2:53 PM, Stephen Paul Carrier wrote:
>>> Hi -
>>> The newest version of cygwin with python 2.7.12-1 fails when pip
>>> installing packages that require compilation. For example, pycrypto
>> FWIW this patch to pycrypto also fixes it:
>> The problem only occurs when trying to build with the C99 standard if
>> Python itself was not.
> I fixed this issue by editing /usr/include/python2.7/pyconfig.h to comment
> out the second line of:
> /* Define on FreeBSD to activate all library features */
> #define __BSD_VISIBLE 1
The use of a __PRIVATE_DEFINE is highly discouraged. In sys/features.h
you'll find a comment to that effect. Python should have used
_BSD_SOURCE but even that is deprecated in favor of _DEFAULT_SOURCE.
> This seemed like the right thing to do since Cygwin isn't FreeBSD, and
> the problem went away.
No but that doesn't mean the functions do not exist.
> Is this an oversight in python-devel package? Issue doesn't occur in
> 32-bit version.
The oversight would be the use of the private define instead of the
public one. If you remove the __BSD_VISIBLE and use _DEFAULT_SOURCE
instead does it help? If not then there is a deeper issue.
Problem reports: http://cygwin.com/problems.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple