Python-2.2.1, Solaris7, make test fails...

Hugh Sasse Staff Elec Eng hgs at dmu.ac.uk
Thu Apr 18 14:18:22 EDT 2002


On 18 Apr 2002, Martin v. [iso-8859-1] Löwis wrote:

> So the property that is being reversed is 'build as static'.
>
> > So the fastest fix is for me to doengrade binutils?
>
> No. The fastest fix is to apply the patch below, and rerun configure.
>
> Regards,
> Martin
>
OK here is the result of building with the patch.

Script started on Thu Apr 18 18:23:55 2002
this is .kshrc
neelix hgs Python-2.2.1 322 $ gmake test
        [...]
building '_socket' extension
skipping /home/hgs/Python-2.2.1/Modules/socketmodule.c (build/temp.solaris-2.7-sun4u-2.2/socketmodule.o up-to-date)
gcc -shared build/temp.solaris-2.7-sun4u-2.2/socketmodule.o -L/usr/local/ssl/lib -L/usr/local/lib -lssl -lcrypto -o build/lib.solaris-2.7-sun4u-2.2/_socket.so
skipping 'dbm' extension (up-to-date)
building 'gdbm' extension
gcc -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -fPIC -I. -I/home/hgs/Python-2.2.1/./Include -I/usr/local/include -IInclude/ -c /home/hgs/Python-2.2.1/Modules/gdbmmodule.c -o build/temp.solaris-2.7-sun4u-2.2/gdbmmodule.o
gcc -shared build/temp.solaris-2.7-sun4u-2.2/gdbmmodule.o -L/usr/local/lib -lgdbm -o build/lib.solaris-2.7-sun4u-2.2/gdbm.so
WARNING: removing "gdbm" since importing it failed

    That is expected.
        [...]
building 'fpectl' extension
gcc -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -fPIC -I. -I/home/hgs/Python-2.2.1/./Include -I/usr/local/include -IInclude/ -c /home/hgs/Python-2.2.1/Modules/fpectlmodule.c -o build/temp.solaris-2.7-sun4u-2.2/fpectlmodule.o
gcc -shared build/temp.solaris-2.7-sun4u-2.2/fpectlmodule.o -L/usr/local/lib -o build/lib.solaris-2.7-sun4u-2.2/fpectl.so
WARNING: removing "fpectl" since importing it failed

    Also expected

building '_tkinter' extension
gcc -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -fPIC -DWITH_APPINIT=1 -I/usr/openwin/include -I. -I/home/hgs/Python-2.2.1/./Include -I/usr/local/include -IInclude/ -c /home/hgs/Python-2.2.1/Modules/_tkinter.c -o build/temp.solaris-2.7-sun4u-2.2/_tkinter.o
In file included from /usr/local/include/tk.h:83,
                 from /home/hgs/Python-2.2.1/Modules/_tkinter.c:49:

        [lots of warnings about X11 trimmed]

gcc -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -fPIC -DWITH_APPINIT=1 -I/usr/openwin/include -I. -I/home/hgs/Python-2.2.1/./Include -I/usr/local/include -IInclude/ -c /home/hgs/Python-2.2.1/Modules/tkappinit.c -o build/temp.solaris-2.7-sun4u-2.2/tkappinit.o
In file included from /usr/local/include/tk.h:83,
                 from /home/hgs/Python-2.2.1/Modules/tkappinit.c:16:

        [lots more warnigns about X11 trimmed]

gcc -shared build/temp.solaris-2.7-sun4u-2.2/_tkinter.o build/temp.solaris-2.7-sun4u-2.2/tkappinit.o -L/usr/openwin/lib -L/usr/local/lib -ltk8.3 -ltcl8.3 -lX11 -o build/lib.solaris-2.7-sun4u-2.2/_tkinter.so
WARNING: removing "_tkinter" since importing it failed

    I wonder why this failed.  Explored below

running build_scripts
not copying /home/hgs/Python-2.2.1/Tools/scripts/pydoc (up-to-date)
./python -E -c 'import sys ; from distutils.util import get_platform ; print get_platform()+"-"+sys.version[0:3]' >platform
find ./Lib -name '*.py[co]' -print | xargs rm -f
./python -E -tt ./Lib/test/regrtest.py -l
test test_al skipped -- No module named al
test test_bsddb skipped -- No module named bsddb
test test_cd skipped -- No module named cd
test test_cl skipped -- No module named cl
test test_curses skipped -- Use of the `curses' resource not enabled
test test_dl skipped -- No module named dl
test test_gdbm skipped -- No module named gdbm
test test_gl skipped -- No module named gl
test test_imgfile skipped -- No module named imgfile
test test_largefile crashed -- exceptions.IOError: [Errno 27] File too large

    How much space does it want?  I don't know this one anyway.

test test_linuxaudiodev skipped -- No module named linuxaudiodev
test test_minidom skipped -- No module named pyexpat
test test_nis skipped -- No NIS master found for any map

    I didn't expect that.  We use nisplus....

test test_ntpath skipped -- No module named nt
test test_openpty skipped -- No openpty() available.
test test_pyexpat skipped -- No module named pyexpat
test test_sax skipped -- no XML parsers available
test test_socket_ssl skipped -- Use of the `network' resource not enabled

    What network resouce?

test test_socketserver skipped -- Use of the `network' resource not enabled
test test_sunaudiodev skipped -- no audio device found!

    Its a headless server, so I'd expect that.

test test_winreg skipped -- No module named _winreg
test test_winsound skipped -- No module named winsound
165 tests OK.
1 test failed:
    test_largefile
21 tests skipped:
    test_al test_bsddb test_cd test_cl test_curses test_dl test_gdbm
    test_gl test_imgfile test_linuxaudiodev test_minidom test_nis
    test_ntpath test_openpty test_pyexpat test_sax test_socket_ssl
    test_socketserver test_sunaudiodev test_winreg test_winsound
Ask someone to teach regrtest.py about which tests are
expected to get skipped on sunos5.
gmake: [test] Error 1 (ignored)
./python -E -tt ./Lib/test/regrtest.py -l

    [ Same messages again]

165 tests OK.
1 test failed:
    test_largefile
21 tests skipped:
    test_al test_bsddb test_cd test_cl test_curses test_dl test_gdbm
    test_gl test_imgfile test_linuxaudiodev test_minidom test_nis
    test_ntpath test_openpty test_pyexpat test_sax test_socket_ssl
    test_socketserver test_sunaudiodev test_winreg test_winsound
Ask someone to teach regrtest.py about which tests are
expected to get skipped on sunos5.
gmake: *** [test] Error 1
neelix hgs Python-2.2.1 323 $ exit

script done on Thu Apr 18 18:46:27 2002

So why did tkinter fail:

Script started on Thu 18 Apr 2002 19:06:22 BST
neelix hgs 11 %> ./python
Python 2.2.1 (#2, Apr 18 2002, 18:23:04) [C] on sunos5
Type "help", "copyright", "credits" or "license" for more information.
>>> import tkine ter
Traceback (most recent call last):
  File "<stdin>", line 1, in ?
ImportError: No module named tkinter
>>>
neelix hgs 12 %> exit
neelix hgs 13 %>
script done on Thu 18 Apr 2002 19:07:09 BST

Hmm...

Script started on Thu 18 Apr 2002 19:11:03 BST
neelix hgs 11 %> ./try_tkinter.sh
#!/bin/sh -v
gcc -v -shared build/temp.solaris-2.7-sun4u-2.2/_tkinter.o build/temp.solaris-2.7-sun4u-2.2/tkappinit.o -L/usr/openwin/lib -L/usr/local/lib -ltk8.3 -ltcl8.3 -lX11 -o build/lib.solaris-2.7-sun4u-2.2/_tkinter.so
gcc: build/temp.solaris-2.7-sun4u-2.2/_tkinter.o: No such file or directory
gcc: build/temp.solaris-2.7-sun4u-2.2/tkappinit.o: No such file or directory
Reading specs from /usr/local/lib/gcc-lib/sparc-sun-solaris2.7/2.95.3/specs
gcc version 2.95.3 20010315 (release)

neelix hgs 12 %> exit
neelix hgs 13 %>
script done on Thu 18 Apr 2002 19:12:24 BST


No, I can't see why it never built that.

        Hugh






More information about the Python-list mailing list