Re: [Python-Dev] [Python-checkins] python/dist/src setup.py, 1.219, 1.220
A new hashlib module to replace the md5 and sha modules. It adds support for additional secure hashes such as SHA-256 and SHA-512. The hashlib module uses OpenSSL for fast platform optimized implementations of algorithms when available. The old md5 and sha modules still exist as wrappers around hashlib to preserve backwards compatibility.
I'm getting compilation errors: C:\py25\Modules\sha512module.c(146) : error C2059: syntax error : 'bad suffix on number' C:\py25\Modules\sha512module.c(146) : error C2146: syntax error : missing ')' before identifier 'L' C:\py25\Modules\sha512module.c(146) : error C2059: syntax error : 'bad suffix on number' C:\py25\Modules\sha512module.c(146) : error C2059: syntax error : 'bad suffix on number' C:\py25\Modules\sha512module.c(146) : error C2059: syntax error : 'bad suffix on number' C:\py25\Modules\sha512module.c(146) : error C2059: syntax error : 'bad suffix on number' C:\py25\Modules\sha512module.c(146) : error C2059: syntax error : 'bad suffix on number' C:\py25\Modules\sha512module.c(146) : fatal error C1013: compiler limit : too many open parentheses Also, there should be updating entries to Misc/NEWS, PC/VC6/pythoncore.dsp, and PC/config.c. Raymond
On Mon, Aug 22, 2005 at 08:46:27AM -0400, Raymond Hettinger wrote:
A new hashlib module to replace the md5 and sha modules. It adds support for additional secure hashes such as SHA-256 and SHA-512. The hashlib module uses OpenSSL for fast platform optimized implementations of algorithms when available. The old md5 and sha modules still exist as wrappers around hashlib to preserve backwards compatibility.
I'm getting compilation errors:
C:\py25\Modules\sha512module.c(146) : error C2059: syntax error : 'bad suffix on number' C:\py25\Modules\sha512module.c(146) : error C2146: syntax error : missing ')' before identifier 'L' C:\py25\Modules\sha512module.c(146) : error C2059: syntax error : 'bad suffix on number' C:\py25\Modules\sha512module.c(146) : error C2059: syntax error : 'bad suffix on number' C:\py25\Modules\sha512module.c(146) : error C2059: syntax error : 'bad suffix on number' C:\py25\Modules\sha512module.c(146) : error C2059: syntax error : 'bad suffix on number' C:\py25\Modules\sha512module.c(146) : error C2059: syntax error : 'bad suffix on number' C:\py25\Modules\sha512module.c(146) : fatal error C1013: compiler limit : too many open parentheses
Also, there should be updating entries to Misc/NEWS, PC/VC6/pythoncore.dsp, and PC/config.c.
Raymond
I don't have a win32 dev environment at the moment so i didn't see that. Sorry. If you remove the 'ULL' suffix from all of the 64bit constants in that file what happens? I added the ULLs to quelch the mass of warnings about constants being to large for the datatype that gcc 3.3 was spewing. -greg
[Gregory P. Smith]
I don't have a win32 dev environment at the moment so i didn't see that. Sorry.
No big deal. But we still have to get the code back to ANSI compliance. Do you have an ANSI-strict option with your compiler? Raymond
Raymond Hettinger wrote:
But we still have to get the code back to ANSI compliance. Do you have an ANSI-strict option with your compiler?
Please don't call this "ANSI compliant". ANSI does many more thinks that writing C standards, and, in the specific case, the code *is* ANSI compliant as it stands - it just doesn't comply to C89. It complies to ISO C 99, which (I believe) is also an U.S. American national (ANSI) standard. gcc does have an option to force c89 compliance, but there is a good chance that Python stops compiling with option: on many systems, essential system headers fail to comply with C89 (in addition, activating that mode also makes many extensions unavailable). Regards, Martin
"Martin" == Martin v Löwis <martin@v.loewis.de> writes:
Martin> Raymond Hettinger wrote: >> Do you have an ANSI-strict option with your compiler? Martin> gcc does have an option to force c89 compliance, but there Martin> is a good chance that Python stops compiling with option: Martin> on many systems, essential system headers fail to comply Martin> with C89 (in addition, activating that mode also makes Martin> many extensions unavailable). However, it might be a reasonable pre-checkin test to try compiling changed files with the option enabled, depending on the number of nonconforming system headers, etc., and grep the output for whinging about c89-nonconformance. -- School of Systems and Information Engineering http://turnbull.sk.tsukuba.ac.jp University of Tsukuba Tennodai 1-1-1 Tsukuba 305-8573 JAPAN Ask not how you can "do" free software business; ask what your business can "do for" free software.
participants (4)
-
"Martin v. Löwis"
-
Gregory P. Smith
-
Raymond Hettinger
-
Stephen J. Turnbull