Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

Installation problem of staden-2.0.0b9 Centos

2012-01-19
2013-04-18
  • Hi all,

    I have a problem installing staden-2.0.0b9 on my CentOS5 system (2.6.18-53.1.21.el5) using both the source and compiled version.

    I have set LD_LIBRARY_PATH to /usr/lib64 and STADENROOT to /usr/local/staden which links to /usr/local/staden-2.0.0b9.x86_64.

    When I run /usr/local/staden-2.0.0b9.x86_64/bin/gap5 or any other binary I get

    # bin/gap5
    couldn't load file "/usr/lib/tk8.4/../libtk8.4.so": /usr/lib/tk8.4/../libtk8.4.so: wrong ELF class: ELFCLASS32

    # ll /usr/lib/tk8.4/../libtk8.4.so
    -rwxr-xr-x 1 root Root 960652 Feb 21  2008 /usr/lib/tk8.4/../libtk8.4.so

    When running ./configure and make the source I get

    # ./configure
    checking for gcc… gcc
    checking for C compiler default output file name… a.out
    checking whether the C compiler works… yes
    checking whether we are cross compiling… no
    checking for suffix of executables…
    checking for suffix of object files… o
    checking whether we are using the GNU C compiler… yes
    checking whether gcc accepts -g… yes
    checking for gcc option to accept ISO C89… none needed
    checking for g++… g++
    checking whether we are using the GNU C++ compiler… yes
    checking whether g++ accepts -g… yes
    checking for gawk… gawk
    checking for curl-config… /usr/bin/curl-config
    checking for the version of libcurl… 7.15.5
    checking whether libcurl just needs -lcurl… yes
    checking whether libcurl is usable… yes
    checking for curl_free… yes
    checking how to run the C preprocessor… gcc -E
    checking for grep that handles long lines and -e… /bin/grep
    checking for egrep… /bin/grep -E
    checking for ANSI C header files… yes
    checking for sys/types.h… yes
    checking for sys/stat.h… yes
    checking for stdlib.h… yes
    checking for string.h… yes
    checking for memory.h… yes
    checking for strings.h… yes
    checking for inttypes.h… yes
    checking for stdint.h… yes
    checking for unistd.h… yes
    checking for inflateEnd in -lz… yes
    checking zlib.h usability… yes
    checking zlib.h presence… yes
    checking for zlib.h… yes
    checking for lzma_easy_buffer_encode in -llzma… yes
    checking lzma.h usability… yes
    checking lzma.h presence… yes
    checking for lzma.h… yes
    checking for png_create_write_struct in -lpng… yes
    checking png.h usability… yes
    checking png.h presence… yes
    checking for png.h… yes
    checking for staden-io_lib-config… no
    checking for io_lib-config… /usr/local/bin/io_lib-config
    checking if io_lib version >= 1.12.5… no
    checking io_lib/Read.h usability… yes
    checking io_lib/Read.h presence… yes
    checking for io_lib/Read.h… yes
    checking for mvwprintw in -lncurses… yes
    checking ncurses.h usability… yes
    checking ncurses.h presence… yes
    checking for ncurses.h… yes
    checking for ANSI C header files… (cached) yes
    checking for sys/wait.h that is POSIX.1 compatible… yes
    checking fcntl.h usability… yes
    checking fcntl.h presence… yes
    checking for fcntl.h… yes
    checking limits.h usability… yes
    checking limits.h presence… yes
    checking for limits.h… yes
    checking for unistd.h… (cached) yes
    checking for zlib.h… (cached) yes
    checking pwd.h usability… yes
    checking pwd.h presence… yes
    checking for pwd.h… yes
    checking for special C compiler options needed for large files… no
    checking for _FILE_OFFSET_BITS value needed for large files… no
    checking for _LARGEFILE_SOURCE value needed for large files… no
    checking for library containing cos… -lm
    checking for popen… yes
    checking for X… libraries /usr/lib64, headers
    checking whether -R must be followed by a space… neither works
    checking for gethostbyname… yes
    checking for connect… yes
    checking for remove… yes
    checking for shmat… yes
    checking for IceConnectionNumber in -lICE… yes
    checking whether byte ordering is bigendian… no
    checking for correct TEA configuration… ok (TEA 3.7)
    checking for Tcl configuration… found /usr/local/lib/tclConfig.sh
    checking for existence of /usr/local/lib/tclConfig.sh… loading
    checking for Tk configuration… found /usr/lib/tkConfig.sh
    checking for existence of /usr/lib/tkConfig.sh… loading
    checking for ranlib… ranlib
    checking if 64bit support is requested… no
    checking if 64bit Sparc VIS support is requested… no
    checking if compiler supports visibility "hidden"… yes
    checking if rpath support is requested… yes
    checking system version… Linux-2.6.18-53.1.21.el5
    checking for dlopen in -ldl… yes
    checking for ar… ar
    checking for required early compiler flags… none
    checking for 64-bit integer type… using long
    checking for Tcl public headers… /usr/local/include
    checking for Tcl private include files… Using srcdir found in tclConfig.sh: /home/brian/tcl8.5.9
    checking for Tk public headers… /usr/include
    checking for Tk private include files… Using srcdir found in tkConfig.sh: /usr/include/tk-private
    checking tklib directory… yes (/usr/share/tklib0.4)
    checking iwidgets directory… yes (/usr/share/iwidgets4.0.1)
    checking itcl directory… vers=/3003000/
    yes (/usr/lib/itcl3.3)
    checking itk directory… yes (/usr/lib/itk3.3)
    configure: creating ./config.status
    config.status: creating Makefile
    config.status: creating system.mk
    config.status: creating shlib.conf
    config.status: creating staden_config.h
    config.status: staden_config.h is unchanged


    External packages used:
    curl:      via /usr/bin/curl-config
    zlib:      DIR (system)
    curses:    DIR (system)
    liblzma:   DIR
    io_lib:    via /usr/local/bin/io_lib-config
    Tcl:       via /usr/local/lib/tclConfig.sh
    Tk:        via /usr/lib/tkConfig.sh
    tklib:     /usr/share/tklib0.4
    Iwidgets:  /usr/share/iwidgets4.0.1
    Itcl:      /usr/lib/itcl3.3
    Itk:       /usr/lib/itk3.3


    # make
    '/usr/local/staden' not versioned, and not exported
    cd Misc && make -f /usr/local/staden/./Misc/Makefile   BUILD=/usr/local/staden SRC=/usr/local/staden/./Misc SUBDIR=Misc all
    '/usr/local/staden' not versioned, and not exported
    make: Entering directory `/usr/local/staden-2.0.0b9.x86_64.src/Misc'
    make: Nothing to be done for `all'.
    make: Leaving directory `/usr/local/staden-2.0.0b9.x86_64.src/Misc'
    cd tk_utils && make -f /usr/local/staden/./tk_utils/Makefile   BUILD=/usr/local/staden SRC=/usr/local/staden/./tk_utils SUBDIR=tk_utils all
    '/usr/local/staden' not versioned, and not exported
    make: Entering directory `/usr/local/staden-2.0.0b9.x86_64.src/tk_utils'
    gcc -g -O2  -DUSE_NON_CONST  -I/usr/local/staden/./tk_utils -I/usr/local/staden/./Misc -I/usr/local/staden/./tk_utils -I/usr/local/include -I"/usr/include/tk-private/generic" -I"/usr/include/tk-private/unix" -I"/home/brian/tcl8.5.9/generic" -I"/home/brian/tcl8.5.9/unix" -I/usr/local/staden/./seq_utils   -I/usr/local/staden  -DSVN_VERSION= -fPIC   -o cli_arg.o -c cli_arg.c
    In file included from cli_arg.c:7:
    /usr/include/tk-private/generic/tk.h:59:3: error: #error Tk 8.4 must be compiled with tcl.h from Tcl 8.4
    make: ***  Error 1
    make: Leaving directory `/usr/local/staden-2.0.0b9.x86_64.src/tk_utils'
    make: ***  Error 2

    These are installed
    # rpm -qa |grep tcl
    tcl-8.4.13-4.el5
    itcl-3.3-0.9.RC1.el4
    tclx-devel-8.4.0-5.fc6
    itcl-devel-3.3-0.7.RC1.el5
    tcllib-1.11.1-1.el5
    postgresql-tcl-8.1.21-1.el5_5.1
    itcl-devel-3.3-0.7.RC1.el5
    tcl-devel-8.4.13-4.el5
    tclx-8.4.0-5.fc6
    tclx-devel-8.4.0-5.fc6
    itcl-3.3-0.7.RC1.el5
    tcl-8.4.13-4.el5
    tcl-devel-8.4.13-4.el5

    # rpm -qa |grep -i '^tk'
    tk-devel-8.4.13-5.el5_1.1
    tklib-0.4.1-5.el5
    tk-8.4.13-5.el5_1.1
    tk-8.4.13-5.el5_1.1
    tkinter-2.4.3-24.el5
    tk-devel-8.4.13-5.el5_1.1

    Could anyone help me with this?

    Many thanks in advance for any advice,
    Marcus

     
  • James Bonfield
    James Bonfield
    2012-01-24

    couldn't load file "/usr/lib/tk8.4/../libtk8.4.so": /usr/lib/tk8.4/../libtk8.4.so: wrong ELF class: ELFCLASS32

    So I see the cause of this now. It's an error in the staden-2.0.0b9.x86_64/lib/tk8.4/pkgIndex.tcl file. It explicitly attempts to load /usr/lib/tk8.4.so instead of the version bundled in the staden-2.0.0b9.x86_64 tarball.

    Edit the /usr/lib part of it to contain ".." (dot dot) instead. Ie the entire file consists of:

    if {[package vcompare [package provide Tcl] 8.4] != 0} { return }
    package ifneeded Tk 8.4 [list load [file join $dir .. libtk8.4.so.0] Tk]
    

    This should then work. I'll see if I can replace the existing tarball on sourceforge too. Sorry about that issue.

    James