AIX

 View Only
  • 1.  Unable to Install a few Python Packages

    Posted Thu June 02, 2022 03:12 PM
    Edited by Carl Burnett Fri June 03, 2022 08:30 AM
    Hello,
    I am new to Python3 and AIX alike. I am developer and do not know much of admin work.

    While trying to install LXML, PANDAS, NUMPY, SCIPY and PYODBC packages, the install failed. Upon investigating, it was found that the necessary CC and FORTRAN compilers are not present in the server.

    I had tried most of the solutions suggested in the forums and in the AIX toolbox community, but nothing worked, I had also reached out to my in house UNIX admins and the solutions they suggested did not work either.

    My admin suggested the use the following two lines in my .profile. However, that also did not work.

    export CC=gcc
    export FC=gfortran

    I am not sure if this is OS related or tool related and hence the posting the question after having stuck with this for over a month. Any suggestions are welcome.

    sudo python -m pip install lxml

    PRIMARY ERROR:

    xlc_r -DNDEBUG -O -I/opt/include -O2 -qmaxmem=-1 -qarch=pwr5 -q64 -I/opt/include -O2 -qmaxmem=-1 -qarch=pwr5 -q64 -DCYTHON_CLINE_IN_TRACEBACK=0 -I/opt/freeware/include/libxml2 -I/opt/freeware/include -Isrc -Isrc/lxml/includes -I/opt/python3/opt/include/python3.6m -c src/lxml/etree.c -o build/temp.AIX.7105.2135.64-3.6/src/lxml/etree.o -w
    unable to execute 'xlc_r': No such file or directory
    Compile failed: command 'xlc_r' failed with exit status 1
    creating tmp
    cc -I/opt/freeware/include/libxml2 -I/opt/freeware/include -I/usr/include/libxml2 -c /tmp/xmlXPathInitblgj4nvj.c -o tmp/xmlXPathInitblgj4nvj.o
    unable to execute 'cc': No such file or directory
    *********************************************************************************
    Could not find function xmlCheckVersion in library libxml2. Is libxml2 installed?
    *********************************************************************************
    error: command 'xlc_r' failed with exit status 1
    ----------------------------------------
    ERROR: Failed building wheel for lxml

    ------------------------------
    Bhavani Kumar Metla
    ------------------------------


  • 2.  RE: Unable to Install a few Python Packages

    Posted 15 days ago

    I have the same issue.
    Do you have a solution?



    ------------------------------
    Rainer Schilling
    ------------------------------



  • 3.  RE: Unable to Install a few Python Packages

    Posted 14 days ago
    Hi There

    Check output of rpm -qa gcc to see if the Open Source GNU compiler is installed.
    AIX has xlC but it may be that your installation required gcc compiler.

    Regards
    Anwar=
    ===============================================================
    This message has been analyzed by Deep Discovery Email Inspector.




  • 4.  RE: Unable to Install a few Python Packages

    IBM Champion
    Posted 14 days ago

    Bhavani,

    Hi, good day to you.

    I had a similar issue a while back, take a look at 

    https://community.ibm.com/community/user/power/communities/community-home/digestviewer/viewthread?GroupId=6049&MessageKey=0fa6471d-7fce-4c27-90d3-f1e7ade1fed9&CommunityKey=daa942cb-b783-4fd3-ba27-a2d7462f9530&tab=digestviewer

    as this might help you solve your issue.

    Regards, Steve



    ------------------------------
    Steve Munday
    AIX, IBM i, HMC, PowerVM
    ------------------------------



  • 5.  RE: Unable to Install a few Python Packages

    Posted 13 days ago

    Thanks a lot! This helped.

    I used the approach of setting the PATH and that worked
    After that I finally linked python3 binaries  from /opt/freeware/bin to /usr/bin, because I don't like having /opt/freeware/bin before /usr/bin permanently in my path.



    ------------------------------
    Rainer Schilling
    ------------------------------