[AstroPy] PyWCS build failure on Windows 7 and Windows XP with EPD

Michael Droettboom mdroe at stsci.edu
Tue Apr 5 07:45:59 EDT 2011


There must be some difference in the mingw32 headers you have and the 
ones I have (I'm on 32-bit and you seem to be on 64-bit, though I don't 
know if that's relevant.)  In my headers, the _NO_OLDNAMES #define turns 
off definining the deprecated "wcsset" function in the MS non-standard 
string library -- MS takes "wcs" to mean "wide character string" :)

Can you send me (off list) a copy of this file?

c:/python27/egg-info/mingw/usr/lib/gcc/../../x86_64-w64-mingw32/include/string.h

Mike

On 04/04/2011 03:00 PM, Tom Aldcroft wrote:
> Hi Mike,
>
> No joy on the install with the new defsetup.py file:
>
> C:\Python27\Scripts\pywcs-1.10-4.7>python setup.py install
> running install
> running build
> running build_py
> copying lib\svn_version.py ->  build\lib.win-amd64-2.7\pywcs
> running build_ext
> building 'pywcs._pywcs' extension
> C:\Python27\Scripts\gcc.exe -mno-cygwin -mdll -O -Wall -DMS_WIN64 -DECHO -DWCSTR
> IG_MACRO -DPYWCS_BUILD -D_GNU_SOURCE -DNDEBUG -DYY_NO_UNISTD_H -D_CRT_SECURE_NO_
> WARNINGS -D_NO_OLDNAMES -UDEBUG -IC:\Python27\lib\site-packages\numpy\core\inclu
> de -I.\wcslib\C -Iwcslib\C -I.\src -IC:\Python27\include -IC:\Python27\PC -c wcs
> lib\C\flexed/wcsbth.c -o build\temp.win-amd64-2.7\Release\wcslib\c\flexed\wcsbth
>
> .o
> In file included from wcsbth.l:118:0:
> .\wcslib\C/wcs.h:1396:5: error: conflicting types for 'wcsset'
> c:/python27/egg-info/mingw/usr/lib/gcc/../../x86_64-w64-mingw32/include/string.h
> :161:20: note: previous declaration of 'wcsset' was here
> wcsbth.l: In function 'wcsbth':
> wcsbth.l:2081:1: warning: statement with no effect
> wcsbth.l: At top level:
> wcsbth.c:19886:16: warning: 'input' defined but not used
> error: command 'gcc' failed with exit status 1
>
> The error looks basically the same, although the presence of the
> -D_NO_OLDNAMES in the build log indicates that the patch was applied
> and that the new defsetup.py was being used.
>
> - Tom
>
> On Mon, Apr 4, 2011 at 9:21 AM, Michael Droettboom<mdroe at stsci.edu>  wrote:
>    
>> Can you apply the attached patch and let me know if it works for you?
>>
>> Mike
>>
>> On 04/03/2011 07:04 PM, Tom Aldcroft wrote:
>>      
>>> Hi -
>>>
>>> I'm am unable to build PyWCS on a Windows 7 and Windows XP machines
>>> using the latest EPD 7.0.2.  In both cases I get the same compiler
>>> error.   Any hints or advice would be most welcome.  Below I include
>>> configuration information and the build log.
>>>
>>> Thanks, Tom
>>>
>>> ---------------------------------
>>>
>>> Windows 7 Pro 64bit, 2009, fully updated.
>>>
>>> Python version is 2.7.1 -- EPD 7.0-2 (64bit)
>>>
>>> Here is what I get with "python setup.py install" command from the
>>> directory indicated, where I unzipped the pywcs tar ball:
>>>
>>> C:\Python27\Scripts\pywcs-1.10-4.7>python setup.py install
>>>
>>> running install
>>> running build
>>> running build_py
>>> copying lib\svn_version.py ->    build\lib.win-amd64-2.7\pywcs
>>>
>>> running build_ext
>>> building 'pywcs._pywcs' extension
>>> C:\Python27\Scripts\gcc.exe -mno-cygwin -mdll -O -Wall -DMS_WIN64 -DECHO
>>> -DWCSTR
>>> IG_MACRO -DPYWCS_BUILD -D_GNU_SOURCE -DNDEBUG -DYY_NO_UNISTD_H
>>> -D_CRT_SECURE_NO_
>>> WARNINGS -UDEBUG -IC:\Python27\lib\site-packages\numpy\core\include
>>> -I.\wcslib\C
>>>   -Iwcslib\C -I.\src -IC:\Python27\include -IC:\Python27\PC -c
>>> wcslib\C\flexed/wc
>>> sbth.c -o build\temp.win-amd64-2.7\Release\wcslib\c\flexed\wcsbth.o
>>> In file included from wcsbth.l:118:0:
>>> .\wcslib\C/wcs.h:1396:5: error: conflicting types for 'wcsset'
>>>
>>> c:/python27/egg-info/mingw/usr/lib/gcc/../../x86_64-w64-mingw32/include/string.h
>>> :161:20: note: previous declaration of 'wcsset' was here
>>> wcsbth.l: In function 'wcsbth':
>>> wcsbth.l:2081:1: warning: statement with no effect
>>> wcsbth.l: At top level:
>>> wcsbth.c:19886:16: warning: 'input' defined but not used
>>> error: command 'gcc' failed with exit status 1
>>> _______________________________________________
>>> AstroPy mailing list
>>> AstroPy at scipy.org
>>> http://mail.scipy.org/mailman/listinfo/astropy
>>>
>>>        
>>
>> --
>> Michael Droettboom
>> Science Software Branch
>> Space Telescope Science Institute
>> Baltimore, Maryland, USA
>>
>>
>> _______________________________________________
>> AstroPy mailing list
>> AstroPy at scipy.org
>> http://mail.scipy.org/mailman/listinfo/astropy
>>
>>
>>      


-- 
Michael Droettboom
Science Software Branch
Space Telescope Science Institute
Baltimore, Maryland, USA




More information about the AstroPy mailing list