Author Michael.Felt
Recipients David.Edelsohn, Michael.Felt, martin.panter
Date 2016-05-10.18:25:12
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1462904714.79.0.750970267143.issue26439@psf.upfronthosting.co.za>
In-reply-to
Content
Spent more time today, testing - on 3.5.1, 3.4.4 and 2.7.11.

The patches would not apply on both Python2 and Python3, but the new file Lib/ctypes/aixutil.py is identical on all three versions.

History of patching (starting from version 3.5.1(.1) is my patched version (as are Python-3.4.4.1 and Python-2.7.11.4)

michael@x071:[/data/prj/aixtools/python/python-3.4.4.1]for i in ../*patches/*patch^Jdo^Jcat $i | patch -p1 ^Jdone
patching file Lib/ctypes/__init__.py
Hunk #1 succeeded at 341 (offset 4 lines).
patching file Lib/ctypes/test/test_loading.py
patching file Lib/ctypes/util.py
Hunk #1 succeeded at 70 (offset -6 lines).
Hunk #2 succeeded at 256 (offset -6 lines).
Hunk #3 succeeded at 275 (offset -6 lines).
patching file Modules/_ctypes/_ctypes.c
Hunk #1 succeeded at 5508 (offset -1 lines).
michael@x071:[/data/prj/aixtools/python/python-3.4.4.1]

But, not with 2.7.11

michael@x071:[/data/prj/aixtools/python/python-2.7.11.4]for i in ../*patches/*patch^Jdo^Jcat $i | patch -p1 --dry-run^Jdone
patching file Lib/ctypes/__init__.py
Hunk #1 succeeded at 355 (offset 18 lines).
patching file Lib/ctypes/test/test_loading.py
Hunk #1 succeeded at 38 (offset -5 lines).
patching file Lib/ctypes/util.py
Hunk #1 succeeded at 71 (offset -5 lines).
Hunk #2 FAILED at 262.
Hunk #3 FAILED at 274.
2 out of 3 hunks FAILED -- saving rejects to file Lib/ctypes/util.py.rej
patching file Modules/_ctypes/_ctypes.c
Hunk #1 FAILED at 5509.
1 out of 1 hunk FAILED -- saving rejects to file Modules/_ctypes/_ctypes.c.rej

So, I made new patches against 2.7.11 after patching manually.

After the builds:

==============================
aixtools.python:aixtools.python.man.en_US:2.7.11.4::I:T:::::N:man pages::::0::
aixtools.python:aixtools.python.rte:2.7.11.4::I:T:::::N:built 10-May-2016 1810 UTC::::0::
==============================
root@x064:[/data/prj/aixtools/python/python-2.7.11.4]cd Lib/ctypes
root@x064:[/data/prj/aixtools/python/python-2.7.11.4/Lib/ctypes]../../python util.py
None
libc.a(shr.o)
libbz2.a(libbz2.so)
('aix.find_library("libiconv.so")', 'libiconv.a(shr4.o)')
('aix.find_library("libintl.so")', 'libintl.a(libintl.so.1)')
('aix.find_library("libintl.so.1")', 'libintl.a(libintl.so.1)')
('aix.find_library("libintl.so.2")', None, ':: should be None!')
('aix.find_library("libintl.so.8")', None)
<CDLL 'libc.a(shr.o)', handle c at 300e5810>
<CDLL 'libintl.a(libintl.so.1)', handle d at 300e5810>
<CDLL 'libcrypt.a(shr.o)', handle e at 300e5810>
libcrypt.a(shr.o)
root@x064:[/data/prj/aixtools/python/python-2.7.11.4/Lib/ctypes]../../python test/test_loading.py
libc_name is libc.a(shr.o)
ss..sss
----------------------------------------------------------------------
Ran 7 tests in 0.189s

OK (skipped=5)

==============================
aixtools.python:aixtools.python.man.en_US:3.4.4.1::I:T:::::N:man pages::::0::
aixtools.python:aixtools.python.rte:3.4.4.1::I:T:::::N:built 10-May-2016 1812 UTC::::0::
==============================
root@x064:[/data/prj/aixtools/python/python-3.4.4.1]cd Lib/ctypes
root@x064:[/data/prj/aixtools/python/python-3.4.4.1/Lib/ctypes]../../python util.py
None
libc.a(shr.o)
libbz2.a(libbz2.so)
aix.find_library("libiconv.so") libiconv.a(shr4.o)
aix.find_library("libintl.so") libintl.a(libintl.so.1)
aix.find_library("libintl.so.1") libintl.a(libintl.so.1)
aix.find_library("libintl.so.2") None :: should be None!
aix.find_library("libintl.so.8") None
<CDLL 'libc.a(shr.o)', handle b at 300e7250>
<CDLL 'libintl.a(libintl.so.1)', handle c at 300e7250>
<CDLL 'libcrypt.a(shr.o)', handle d at 300e7250>
libcrypt.a(shr.o)
root@x064:[/data/prj/aixtools/python/python-3.4.4.1/Lib/ctypes]../../python test/test_loading.py
libc_name is libc.a(shr.o)
ss..sss
----------------------------------------------------------------------
Ran 7 tests in 0.323s

OK (skipped=5)

root@x064:[/data/prj/aixtools/python/python-3.5.1.1]installp -d . -L
aixtools.python:aixtools.python.man.en_US:3.5.1.0::I:T:::::N:man pages::::0::
aixtools.python:aixtools.python.man.en_US:3.5.1.1::I:T:::::N:man pages::::0::
aixtools.python:aixtools.python.rte:3.5.1.0::I:T:::::N:built 03-Mar-2016 0856 UTC::::0::
aixtools.python:aixtools.python.rte:3.5.1.1::I:T:::::N:built 10-May-2016 1620 UTC::::0::

And, with a 64-bit build

root@x064:[/data/prj/aixtools/python/python-3.5.1.1]installp -d . -L
aixtools.python:aixtools.python.man.en_US:3.5.1.0::I:T:::::N:man pages::::0::
aixtools.python:aixtools.python.man.en_US:3.5.1.1::I:T:::::N:man pages::::0::
aixtools.python:aixtools.python.rte:3.5.1.0::I:T:::::N:built 03-Mar-2016 0856 UTC::::0::
aixtools.python:aixtools.python.rte:3.5.1.1::I:T:::::N:built 10-May-2016 1620 UTC::::0::
root@x064:[/data/prj/aixtools/python/python-3.5.1.1]cd lib/ctypes
ksh: lib/ctypes:  not found.
root@x064:[/data/prj/aixtools/python/python-3.5.1.1]cd Lib/ctypes
root@x064:[/data/prj/aixtools/python/python-3.5.1.1/Lib/ctypes]../../python util.py
None
libc.a(shr_64.o)
None
aix.find_library("libiconv.so") libiconv.a(shr4_64.o)
aix.find_library("libintl.so") libintl.a(libintl.so.1)
aix.find_library("libintl.so.1") libintl.a(libintl.so.1)
aix.find_library("libintl.so.2") None :: should be None!
aix.find_library("libintl.so.8") None
<CDLL 'libc.a(shr_64.o)', handle a at 0x7000000001c79e8>
<CDLL 'libintl.a(libintl.so.1)', handle b at 0x7000000001c79e8>
<CDLL 'libcrypt.a(shr_64.o)', handle c at 0x7000000001c79e8>
libcrypt.a(shr_64.o)
root@x064:[/data/prj/aixtools/python/python-3.5.1.1/Lib/ctypes]../../python test/test_loading.py
libc_name is libc.a(shr_64.o)
ss..sss
----------------------------------------------------------------------
Ran 7 tests in 0.414s

OK (skipped=5)

Patches follow (question, should these be in a tar file in the future?)
History
Date User Action Args
2016-05-10 18:25:15Michael.Feltsetrecipients: + Michael.Felt, martin.panter, David.Edelsohn
2016-05-10 18:25:14Michael.Feltsetmessageid: <1462904714.79.0.750970267143.issue26439@psf.upfronthosting.co.za>
2016-05-10 18:25:14Michael.Feltlinkissue26439 messages
2016-05-10 18:25:13Michael.Feltcreate