Several Windows related cleanups:
* Removed a #define from pyconfig.h. The macro was already defined a few lines higher.
* Fixed path to tix in the build_tkinter.py script
* Changed make_buildinfo.c to use versions of unlink and strcat which are considered safe by Windows (as suggested by MvL).
* Removed two defines from pyproject.vsprops that are no longer required. Both are defined in pyconfig.h and make_buildinfo.c doesn't use the unsafe versions any more (as suggested by MvL).
* Added some more information about PGO and the property files to PCbuild9/readme.txt.
Fixed get_config_h_filename for Windows. Without the patch it can't find the pyconfig.h file inside a build tree.
Added several small unit tests for sysconfig.
Fix Issue 1045.
Factor-out common calling code by simplifying the length_hint API.
Speed-up the function by caching the PyObject_String for the attribute lookup.
The macros _WIN32, _WIN64 and _M_X64 are defined by the compiler. The VS 2008 IDE doesn't know about (some) of the macros and can display wrong information. In my case a section #ifdef _WIN64 was grayed out although the platform was x64. I've added the macros to pyproject.vsprops and x64.vsprops.
I've also added a paragraph about the property files to the readme and fixed the order of pyupdate > pyinstrument.
Ronald Oussoren [Wed, 5 Dec 2007 20:07:36 +0000 (20:07 +0000)]
This "fixes" compilation issues for the Carbon._OSA module on OSX Leopard
by purging bindings to OSA's debug API's. Those APIs we're completely
unsupported on OSX 10.4 and are no longer available on OSX 10.5.
Note that this patches a generated file. This is somewhat acceptable because
regenerating the file is non-trivial and wouldn't use system headers anyway.
These optimizations create smaller and a bit faster code on my machine. I've also disabled an optimization that may be dangerous. Intrinsic functions conflict with errno.
Added warning that make install may overwrite or masquerade the default python binary. Use make altinstall instead.
A native English speaker may want to rephrase the paragraph. ;)
Patch #1537 from Chad Austin
Change GeneratorExit's base class from Exception to BaseException
(This time I'm applying the patch to the correct sandbox.)
Martin v. Löwis [Mon, 3 Dec 2007 19:20:02 +0000 (19:20 +0000)]
Issue #1727780: Support loading pickles of random.Random objects created
on 32-bit systems on 64-bit systems, and vice versa. As a consequence
of the change, Random pickles created by Python 2.6 cannot be loaded
in Python 2.5.
Applied my patch #1455 with some extra fixes for VS 2005
The new msvc9compiler module supports VS 2005 and VS 2008. I've also fixed build_ext to support PCbuild8 and PCbuild9 and backported my fix for xxmodule.c from py3k. The old code msvccompiler is still in place in case somebody likes to build an extension with VS 2003 or earlier.
I've also updated the cygwin compiler module for VS 2005 and VS 2008. It works with VS 2005 but I'm unable to test it with VS 2008. We have to wait for a new version of cygwin.
Feature #1534
Added PyFloat_GetMax(), PyFloat_GetMin() and PyFloat_GetInfo() to the float API.
Added a dictionary sys.float_info with information about the internal floating point type to the sys module.
Although pyconfig.h claims that WIN32 is obsolete it is still required for the locale module. locale.getdefaultlocale() fails silently w/o the WIN32 macro.
Christian Heimes [Fri, 30 Nov 2007 21:11:28 +0000 (21:11 +0000)]
Fix for feature request #1528 Add os.fchmod
Georg Brandl has added fchmod() and fchown(). I've contributed lchown but I'm not able to test it on Linux. However it should be available on Mac and some other flavors of Unix.
I've made a quick test of fchmod() and fchown() on my system. They are working as expected.
Christian Heimes [Fri, 30 Nov 2007 19:18:08 +0000 (19:18 +0000)]
Removed or replaced some more deprecated preprocessor macros.
Moved the _DEBUG and NDEBUG macros to two new property files.
Fixed #1527 Problem with static libs on Windows
Updated README.txt
Issue #1402: PyInterpreterState_Clear() may still invoke user code
(in deallocation of running threads, for example), so the PyGILState_Release()
function must still be functional.
On the other hand, _PyGILState_Fini() only frees memory, and can be called later.
Backport candidate, but only after some experts comment on it.
Christian Heimes [Tue, 27 Nov 2007 23:16:44 +0000 (23:16 +0000)]
Expose Py_Py3kWarningFlag as sys.py3kwarning as discussed in #1504
Also added a warning.warnpy3k() as convenient method for Python 3.x related deprecation warnings.