Menu

Fatal Error in Building

Help
Tim A Kyle
2001-11-05
2012-09-19
  • Tim A Kyle

    Tim A Kyle - 2001-11-05

    Hi-

    I am using Python 2.1 and MySQL 3.23 on Solaris 2.8 with Gnome as a windows manager. I am trying to build the interface but when I type:

    > python setup.py

    I get:

    running build
    running build_py
    not copying CompatMysqldb.py (output up-to-date)
    not copying _mysql_exceptions.py (output up-to-date)
    not copying MySQLdb/__init__.py (output up-to-date)
    not copying MySQLdb/converters.py (output up-to-date)
    not copying MySQLdb/connections.py (output up-to-date)
    not copying MySQLdb/cursors.py (output up-to-date)
    not copying MySQLdb/sets.py (output up-to-date)
    not copying MySQLdb/times.py (output up-to-date)
    not copying MySQLdb/constants/__init__.py (output up-to-date)
    not copying MySQLdb/constants/CR.py (output up-to-date)
    not copying MySQLdb/constants/FIELD_TYPE.py (output up-to-date)
    not copying MySQLdb/constants/ER.py (output up-to-date)
    not copying MySQLdb/constants/FLAG.py (output up-to-date)
    not copying MySQLdb/constants/REFRESH.py (output up-to-date)
    not copying MySQLdb/constants/CLIENT.py (output up-to-date)
    running build_ext
    building '_mysql' extension
    skipping _mysql.c (build/temp.solaris-2.8-sun4u-2.1/_mysql.o up-to-date)
    gcc -shared build/temp.solaris-2.8-sun4u-2.1/_mysql.o -L/usr/local/mysql/lib -lmysqlclient -lz -o build/lib.solaris-2.8-sun4u-2.1/_mysql.so

    ...

    dynstr_append_mem                   0xc0        /usr/local/mysql/lib/libmysqlclient.a(string.o)
    memchr                              0x10        /usr/local/mysql/lib/libmysqlclient.a(strnlen.o)
    ld: fatal: relocations remain against allocatable but non-writable sections
    collect2: ld returned 1 exit status

    Can anyone see the problem here? My setup.py file is as follows:

    elif sys.platform == "sunos5": # Solaris 2.8
        include_dirs = ['/usr/local/mysql/include']
        library_dirs = ['/usr/local/mysql/lib']
        libraries = [mysqlclient, "z"]
        runtime_library_dirs = [' /usr/local/lib:/usr/openwin/lib:/usr/dt/lib']
        extra_objects = []

    Thanks for your help,

    Tim

     
    • Andy Dustman

      Andy Dustman - 2001-11-12

      This is a problem that seems to only occur with GCC on Solaris. Try using the current CVS version.

      http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/~checkout~/mysql-python/MySQLdb/setup.py?rev=1.17&content-type=text/x-python

       
    • xQvverty

      xQvverty - 2002-01-18

      I have the same problem in Linux RedHat 7.0

      Did you allready solve your problem? In such a case, could you tell me how?

      Thanks.

       
    • Tim A Kyle

      Tim A Kyle - 2002-01-18

      Yes I did. The solution is at the URL

      https://sourceforge.net/forum/message.php?msg_id=493835

      HTH,

      Tim

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.