Issue709178
This issue tracker has been migrated to GitHub,
and is currently read-only.
For more information,
see the GitHub FAQs in the Python's Developer Guide.
Created on 2003-03-25 02:55 by jkluebs, last changed 2022-04-10 16:07 by admin. This issue is now closed.
Files | ||||
---|---|---|---|---|
File name | Uploaded | Description | Edit | |
python-distutils-remove-cygwin-static.diff | jkluebs, 2003-03-25 02:56 | patch to remove -static option from cygwinccompiler.py | ||
cygwinccompiler.py-shared.diff | jlt63, 2003-04-10 16:19 | patch to use -shared instead of -mdll -static for newer toolchains |
Messages (14) | |||
---|---|---|---|
msg43148 - (view) | Author: John Kabir Luebs (jkluebs) | Date: 2003-03-25 02:55 | |
Currently, the cygwinccompiler.py compiler handling in distutils is invoking the cygwin and mingw compilers with the -static option. Logically, this means that the linker should choose to link to static libraries instead of shared/dynamically linked libraries. Current win32 binutils expect import libraries to have a .dll.a suffix and static libraries to have .a suffix. If -static is passed, it will skip the .dll.a libraries. This is pain if one has a tree with both static and dynamic libraries using this naming convention, and wish to use the dynamic libraries. The -static option being passed in distutils is to get around a bug in old versions of binutils where it would get confused when it found the DLLs themselves. The decision to use static or shared libraries is site or package specific, and should be left to the setup script or to command line options. |
|||
msg43149 - (view) | Author: Martin v. Löwis (loewis) * | Date: 2003-03-28 00:03 | |
Logged In: YES user_id=21627 Jason, can you take a look? If not, please unassign it. |
|||
msg43150 - (view) | Author: Jason Tishler (jlt63) * | Date: 2003-03-28 18:41 | |
Logged In: YES user_id=86216 Note that I only have minimal experience building Win32 extensions modules... This patch works "fine" with my *very* limited testing. Specifically, I successfully rebuilt the Win32 readline module with it applied. BTW, this area of Distutils probably should be revisited to bring it up to date. For example, the "-mdll --entry _DllMain@12" options could be replaced by "-shared". |
|||
msg43151 - (view) | Author: John Kabir Luebs (jkluebs) | Date: 2003-03-28 20:56 | |
Logged In: YES user_id=87160 The -mdll --entry DllMain@12 option is guarded for an old version of gcc that did not have the correct specs to accept -shared. I didn't touch it, even though it's crazy if anyone is using such an old and buggy toolchain. --shared and --dll are equivalent as far as ld is concerned. |
|||
msg43152 - (view) | Author: Jason Tishler (jlt63) * | Date: 2003-03-28 21:16 | |
Logged In: YES user_id=86216 John, would you be willing to help test or supply me with test cases? I have built exactly one Win32 extension. |
|||
msg43153 - (view) | Author: Martin v. Löwis (loewis) * | Date: 2003-03-28 22:15 | |
Logged In: YES user_id=21627 I'm in favour of applying this patch, and also of patches that mandate recent Cygwin releases; if such patches are implemented, the minimum required Cygwin version should be stated somewhere. |
|||
msg43154 - (view) | Author: John Kabir Luebs (jkluebs) | Date: 2003-03-28 23:31 | |
Logged In: YES user_id=87160 I can help with testing. I have access to W2K and Win98 (ugh) boxen. I don't mind installing a few older toolchains if you think that's necessary. I think any C/C++ python extension using plain distutils (no fancy hacks added on) and has one or more DLL dependencies is a good test case. |
|||
msg43155 - (view) | Author: Jason Tishler (jlt63) * | Date: 2003-03-31 16:58 | |
Logged In: YES user_id=86216 loewis> I'm in favour of applying this patch, and loewis> also of patches that mandate recent Cygwin loewis> releases; I would like to apply an enhanced version of this patch. By enhanced, I mean using "gcc -shared" (no more dllwrap and gcc -mdll) and removing redundant gcc options, etc. Additionally, I would like to fix get_versions() so it can deal with versions that only have two components (e.g., 3.2) as opposed to requiring three (e.g. 2.95.3). Are these changes acceptable? loewis> if such patches are implemented, the minimum loewis> required Cygwin version should be stated loewis> somewhere. I propose that the currently available Cygwin and Mingw tool chains be that above stated minimum. Is this acceptable? Unfortunately, I have no idea where the above stated "somewhere" shoud be. |
|||
msg43156 - (view) | Author: Jason Tishler (jlt63) * | Date: 2003-03-31 17:02 | |
Logged In: YES user_id=86216 jkluebs> I can help with testing. I have access to W2K jkluebs> and Win98 (ugh) boxen. I don't mind jkluebs> installing a few older toolchains if you jkluebs> think that's necessary. Thanks for the offer. I'm set up for the current Cygwin and Mingw tool chains. Let's wait to see if testing with older ones is necessary. jkluebs> I think any C/C++ python extension using jkluebs> plain distutils (no fancy hacks added on) and jkluebs> has one or more DLL dependencies is a good jkluebs> test case. Can you point me to one that builds OOTB under Python 2.2.2? |
|||
msg43157 - (view) | Author: Martin v. Löwis (loewis) * | Date: 2003-03-31 21:33 | |
Logged In: YES user_id=21627 jlt63: Your proposed changes all sound fine. |
|||
msg43158 - (view) | Author: Jason Tishler (jlt63) * | Date: 2003-04-01 19:11 | |
Logged In: YES user_id=86216 Martin, Thanks for your approval. I would like to check in the changes in parts. For example: 1. John's remove -static patch. 2. my get_versions() fix patch 3. my -shared patch 4. etc. In this way, I can more easily roll back if I goof. Can I just attach more patches to this one? Or, should I create a new SF patch for each of my patches? |
|||
msg43159 - (view) | Author: Jason Tishler (jlt63) * | Date: 2003-04-09 16:23 | |
Logged In: YES user_id=86216 Checked in as Lib/distutils/cygwinccompiler.py 1.22. Sorry, for sluggish response time. I will create separate SF patches for the forthcoming, related patches. |
|||
msg43160 - (view) | Author: Jason Tishler (jlt63) * | Date: 2003-04-10 16:19 | |
Logged In: YES user_id=86216 After some more reflection, I would like to revert the original patch and apply my version, cygwinccompiler.py-shared.diff, instead. My reasons are the following: 1. support for older toolchains is retained 2. support for new toolchains (i.e., ld -shared) is added The goal of my approach is to avoid breaking older toolchains while adding better support for newer ones. John and/or anyone else, is my approach acceptable? Can you find any problems with it? Thanks. |
|||
msg43161 - (view) | Author: Jason Tishler (jlt63) * | Date: 2003-04-14 13:10 | |
Logged In: YES user_id=86216 Checked in as Lib/distutils/cygwinccompiler.py 1.24. I guess that no news is good news... :,) |
History | |||
---|---|---|---|
Date | User | Action | Args |
2022-04-10 16:07:52 | admin | set | github: 38211 |
2003-03-25 02:55:06 | jkluebs | create |