Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Python: Bugs

[issue12641] Remove -mno-cygwin from distutils

 

 

Python bugs RSS feed   Index | Next | Previous | View Threaded


report at bugs

Jul 10, 2012, 1:20 AM

Post #1 of 5 (202 views)
Permalink
[issue12641] Remove -mno-cygwin from distutils

Craig McQueen <python [at] craig> added the comment:

I've come across this issue when trying to build extensions for Python 3.3 on Windows, needing a recent enough MinGW to provide a library for msvcr100. See issue #15315.

----------
nosy: +cmcqueen1975

_______________________________________
Python tracker <report [at] bugs>
<http://bugs.python.org/issue12641>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com


report at bugs

Jul 10, 2012, 2:30 AM

Post #2 of 5 (198 views)
Permalink
[issue12641] Remove -mno-cygwin from distutils [In reply to]

Martin v. Löwis <martin [at] v> added the comment:

I have gcc 3.4.4 in my cygwin installation, and it still needs the -mno-cygwin option, else the resulting binary will link with cygwin1.dll (which is undesired).

----------

_______________________________________
Python tracker <report [at] bugs>
<http://bugs.python.org/issue12641>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com


report at bugs

Jul 10, 2012, 3:11 AM

Post #3 of 5 (196 views)
Permalink
[issue12641] Remove -mno-cygwin from distutils [In reply to]

Martin v. Löwis <martin [at] v> added the comment:

I just installed the cygwin gcc4 package; this gives me gcc 4.5.3. In this version, -mno-cygwin is still recognized, and gives this error message:

gcc: The -mno-cygwin flag has been removed; use a mingw-targeted cross-compiler.

So it seems that removing the -mno-cygwin flag is definitely incorrect, as it will result in a cygwin binary.

I then installed the mingw-gcc-core package, which gave me the utility i686-pc-mingw32-gcc, which indeed is able to create a (nearly) correct binary.

So I think we should check whether i686-pc-mingw32-gcc exists in the path, and if so, use it (without a -mno-cygwin flag). If it doesn't exist, we should continue to use gcc -mno-cygwin.

My remaining concern with i686-pc-mingw32-gcc is that it still links with msvcrt.dll in addition to linking with msvcrXY.dll; this is incorrect.

There is another concern that this applies to 32-bit mode only; in 64-bit mode, i686-w64-mingw32-gcc should be used. However, this is issue 4709.

----------

_______________________________________
Python tracker <report [at] bugs>
<http://bugs.python.org/issue12641>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com


report at bugs

Jul 10, 2012, 3:19 AM

Post #4 of 5 (198 views)
Permalink
[issue12641] Remove -mno-cygwin from distutils [In reply to]

Martin v. Löwis <martin [at] v> added the comment:

The 64-bit compiler is actually called x86_64-w64-mingw32-gcc.

----------

_______________________________________
Python tracker <report [at] bugs>
<http://bugs.python.org/issue12641>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com


report at bugs

Jul 10, 2012, 4:31 PM

Post #5 of 5 (193 views)
Permalink
[issue12641] Remove -mno-cygwin from distutils [In reply to]

Craig McQueen <python [at] craig> added the comment:

It would be great if this could be sorted out in time for Python 3.3. Otherwise I don't think we'll be able to use MinGW to build extensions in Windows. Unless there is a version of MinGW which supports the -mno-cygwin option, as well as libmsvcr100.

----------

_______________________________________
Python tracker <report [at] bugs>
<http://bugs.python.org/issue12641>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com

Python bugs RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.