summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFabian Groffen <grobian@gentoo.org>2009-10-11 09:42:43 +0000
committerFabian Groffen <grobian@gentoo.org>2009-10-11 09:42:43 +0000
commit9fd49a08ee30374227377c040a716581733b82e5 (patch)
tree06378519ae362ff2103bed0068964f15b2c4f4e6 /dev-python/pycrypto/files/pycrypto-2.0.1-caseimport.patch
parentMerge from Prefix (diff)
downloadgentoo-2-9fd49a08ee30374227377c040a716581733b82e5.tar.gz
gentoo-2-9fd49a08ee30374227377c040a716581733b82e5.tar.bz2
gentoo-2-9fd49a08ee30374227377c040a716581733b82e5.zip
Merge from Prefix
(Portage version: 2.2.00.14552-prefix/cvs/Darwin powerpc, RepoMan options: --force)
Diffstat (limited to 'dev-python/pycrypto/files/pycrypto-2.0.1-caseimport.patch')
-rw-r--r--dev-python/pycrypto/files/pycrypto-2.0.1-caseimport.patch63
1 files changed, 63 insertions, 0 deletions
diff --git a/dev-python/pycrypto/files/pycrypto-2.0.1-caseimport.patch b/dev-python/pycrypto/files/pycrypto-2.0.1-caseimport.patch
new file mode 100644
index 000000000000..ad4331ff05d2
--- /dev/null
+++ b/dev-python/pycrypto/files/pycrypto-2.0.1-caseimport.patch
@@ -0,0 +1,63 @@
+http://sourceforge.net/tracker/index.php?func=detail&aid=1849383&group_id=20937&atid=320937
+
+--- pycrypto-2.0.1/Hash/MD5.py
++++ pycrypto-2.0.1/Hash/MD5.py
+@@ -13,11 +13,14 @@
+ digest_size = new().digest_size
+
+ except ImportError:
+- from md5 import *
++ # cannot import 'md5' from within 'MD5.py',
++ # because on case insensitive filesystems it will find myself.
++ # thus need to do the actual 'import md5' from somewhere else.
++ from extmd5 import *
+
+- import md5
+- if hasattr(md5, 'digestsize'):
++ import extmd5
++ if hasattr(extmd5, 'digestsize'):
+ digest_size = digestsize
+ del digestsize
+- del md5
++ del extmd5
+
+--- pycrypto-2.0.1/Hash/SHA.py
++++ pycrypto-2.0.1/Hash/SHA.py
+@@ -13,9 +13,12 @@
+ digest_size = new().digest_size
+
+ except ImportError:
+- from sha import *
+- import sha
+- if hasattr(sha, 'digestsize'):
++ # cannot import 'sha' from within 'SHA.py',
++ # because on case insensitive filesystems it will find myself.
++ # thus need to do the actual 'import sha' from somewhere else.
++ from extsha import *
++ import extsha
++ if hasattr(extsha, 'digestsize'):
+ digest_size = digestsize
+ del digestsize
+- del sha
++ del extsha
+--- pycrypto-2.0.1/Hash/extmd5/__init__.py
++++ pycrypto-2.0.1/Hash/extmd5/__init__.py
+@@ -0,0 +1,2 @@
++# see ../MD5.py for why this is done
++from md5 import *
+--- pycrypto-2.0.1/Hash/extsha/__init__.py
++++ pycrypto-2.0.1/Hash/extsha/__init__.py
+@@ -0,0 +1,2 @@
++# see ../SHA.py for why this is done
++from sha import *
+--- pycrypto-2.0.1/setup.py
++++ pycrypto-2.0.1/setup.py
+@@ -132,7 +132,7 @@
+ 'url':"http://www.amk.ca/python/code/crypto",
+
+ 'cmdclass' : {'build_ext':PCTBuildExt},
+- 'packages' : ["Crypto", "Crypto.Hash", "Crypto.Cipher", "Crypto.Util",
++ 'packages' : ["Crypto", "Crypto.Hash", "Crypto.Hash.extmd5", "Crypto.Hash.extsha", "Crypto.Cipher", "Crypto.Util",
+ "Crypto.Protocol", "Crypto.PublicKey"],
+ 'package_dir' : { "Crypto":"." },
+ # One module is defined here, because build_ext won't be