AIX

AIX

Connect with fellow AIX users and experts to gain knowledge, share insights, and solve problems.

 View Only
  • 1.  Building Python 2.5.2 on AIX 6 using GCC

    Posted Mon September 15, 2008 10:16 AM

    Originally posted by: SystemAdmin


    Hello,

    I cannot build Python 2.5.2 on my AIX 6.1 box using gcc.

    I have installed the GCC (gcc-4.2.0-3.aix6.1.ppc.rpm)provided
    by IBM in their "toolbox for AIX" http://www-03.ibm.com/systems/p/os/aix/linux/toolbox/download.html

    I run the following:
    ./configure --with-gcc
    make

    The make process runs compiles and so on that are OK,
    but it stops with this error:
    === http://... ===
    ./Modules/ld_so_aix gcc -pthread -bI:Modules/python.exp build/temp.aix-6.1-2.5/usr/local/work/Python-2.5.2/Modules/fcntlmodule.o -o build/lib.aix-6.1-2.5/fcntl.so
    ld: 0711-317 ERROR: Undefined symbol: .flock
    ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more information.
    collect2: ld returned 8 exit status
    • WARNING: renaming "fcntl" since importing it failed: 0509-022 Cannot load module build/lib.aix-6.1-2.5.
    0509-026 System error: A file or directory in the path name does not exist.
    error: No such file or directory
    make: 1254-004 The error code from the last command is 1.
    =============

    any suggestion?

    thanks


  • 2.  Re: Building Python 2.5.2 on AIX 6 using GCC

    Posted Mon September 15, 2008 11:57 AM

    Originally posted by: j.gann


    I am not familiar with the particular problem at hand, but developers porting their sw to aix report good success with the gcc packages provided by Michael Perzl -> http://www.perzl.org/aix/

    Regards


  • 3.  Re: Building Python 2.5.2 on AIX 6 using GCC

    Posted Wed September 17, 2008 06:57 AM

    Originally posted by: SystemAdmin


    (an answer to my own question:)

    Finally, for the Python build to work, I have added
    "-lbsd" to the CCOPT var in the Modules/ld_so_aix script,
    so that we have the line:
    CCOPT="$CCOPT -Wl,-bM:SRE -Wl,-T512 -Wl,-H512 -lm -lbsd -o $objfile"
    instead of:
    CCOPT="$CCOPT -Wl,-bM:SRE -Wl,-T512 -Wl,-H512 -lm -o $objfile"

    Then python was built correctly


  • 4.  Re: Building Python 2.5.2 on AIX 6 using GCC

    Posted Wed April 07, 2010 07:22 AM

    Originally posted by: haubi


    This now happens on AIX5.3 too, after upgrading to:
    $ oslevel -s
    5300-08-09-1013

    Even if flock() was provided in libbsd.a before already, the declaration for flock() in <sys/file.h> was not.
    Thus python's configure didn't detect flock() and used something else.

    But now, as flock() is declared in <sys/file.h>, python's configure detects flock(), but doesn't link libbsd.
    This is reported as: http://bugs.python.org/issue4026

    Another thing worth to mention is:
    There seems to be no flock() implementation for 64bits on AIX5.3 (can't say for AIX6.1) - at least not in libbsd.a,
    but <sys/file.h> unconditionally declares flock() even for 64bits.

    /haubi/


  • 5.  Re: Building Python 2.5.2 on AIX 6 using GCC

    Posted Wed April 07, 2010 10:15 AM

    Originally posted by: SystemAdmin


    wow gold sale shop here,cheap wow gold,cheap wow gold,cheap wow gold,the world of wacraft gold store in the world.luxury watches
    swiss watches


  • 6.  Re: Building Python 2.5.2 on AIX 6 using GCC

    Posted Tue June 22, 2010 10:28 AM

    Originally posted by: haubi


    Just for completion: There is a bug report at python for this issue:
    http://bugs.python.org/issue4026