AIX Open Source

 View Only
  • 1.  Getting error with Make / Cmake

    Posted Mon May 08, 2023 11:45 AM

    Hi,

    I got the following make related errors when trying to install Xgboost for Python 3.7. I have tried both make and cmake from AIX Toolbox and the error messages are the same. I did search Internet and it seems related to compatibility issue. Can someone help?

    Thanks

    Mi

    + cd ./xgboost/
        + echo
        + grep -q darwin
        + LIB_XGBOOST=libxgboost.so
        + make clean
        "Makefile", line 1: make: Dependency line needs colon or double colon operator.
        "Makefile", line 2: make: Dependency line needs colon or double colon operator.
        "Makefile", line 4: make: Dependency line needs colon or double colon operator.
        "Makefile", line 6: make: Dependency line needs colon or double colon operator.
        "Makefile", line 7: make: Dependency line needs colon or double colon operator.
        "Makefile", line 9: make: Dependency line needs colon or double colon operator.
        "Makefile", line 11: make: Dependency line needs colon or double colon operator.
        "Makefile", line 13: make: Dependency line needs colon or double colon operator.
        "Makefile", line 15: make: Dependency line needs colon or double colon operator.
        "Makefile", line 20: make: Dependency line needs colon or double colon operator.
        "Makefile", line 21: make: Shell command needs a leading tab.
        "Makefile", line 23: make: Shell command needs a leading tab.
        "Makefile", line 24: make: Dependency line needs colon or double colon operator.
        "Makefile", line 26: make: Dependency line needs colon or double colon operator.
        "Makefile", line 27: make: Shell command needs a leading tab.

    ..........



    ------------------------------
    Mi Wang
    ------------------------------


  • 2.  RE: Getting error with Make / Cmake

    Posted Mon May 08, 2023 12:39 PM

    Use /opt/freeware/bin/make (GNU make provided by make rpm in Toolbox) instead of AIX /usr/bin/make. 



    ------------------------------
    Ayappan P
    ------------------------------



  • 3.  RE: Getting error with Make / Cmake

    Posted Mon May 08, 2023 04:26 PM

    Hi Ayappan,

    Your suggestion works. But I got new error (below). I did some search in Internet and it seems the option is only for Intel platform. Should I just remove the option from some build script in the Xgboost  package and do the pip install again?

    Thanks

    Mi

    g++: error: unrecognized command-line option '-msse2'



    ------------------------------
    Mi Wang
    ------------------------------



  • 4.  RE: Getting error with Make / Cmake

    Posted Tue May 09, 2023 02:41 AM

    Yes, these are x86 specific options. You should remove them while building in AIX. 



    ------------------------------
    Ayappan P
    ------------------------------



  • 5.  RE: Getting error with Make / Cmake

    Posted Wed May 10, 2023 04:56 PM

    Hi Ayappan,

    I need help on the following:
    1. I see in the CMakeLists.txt file, there is a line as following, I want to add another line right after it to set the value of SUPPORT_MSSE2 as 0. What will be the syntax?

    check_cxx_compiler_flag("-msse2"        SUPPORT_MSSE2)

    2. I see following lines in the Makefile file. I think adding the leading '#' will disable them?

    ifeq ($(USE_SSE), 1)
           CFLAGS += -msse2
    endif
     
    3. For following error I got during the pip installation, should I set the $CC value to point to /opt/freeware/...?

    Makefile:31: MAKE [make] - checked OK
    make: cc: No such file or directory
    make: cc: No such file or directory
     

    Thanks

    Mi



    ------------------------------
    Mi Wang
    ------------------------------



  • 6.  RE: Getting error with Make / Cmake

    Posted Thu May 11, 2023 05:52 AM

    1) You can set it as blank "" , not sure though.
    2) You can comment these things.
    3) You can set CC to "/opt/freeware/bin/gcc -pthread -maix64".



    ------------------------------
    Ayappan P
    ------------------------------



  • 7.  RE: Getting error with Make / Cmake

    Posted Thu May 11, 2023 10:59 AM

    Hi Ayappan,

    I find once I have modified the *.tar.gz file, the pip installation will no longer succeed. I think that is because the original hashes are no longer valid. So I have tried another version of Xgboost and got the following errors. Maybe making some changes to environment variables resolve the issues? (I have installed libgomp and libgomp10 already)


     CMake Error at /opt/freeware/share/cmake-3.22/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
          Could NOT find OpenMP_C (missing: OpenMP_pthreads_LIBRARY) (found version
          "4.5") 

     /tmp/pip-install-10f9hz97/xgboost/xgboost/rabit/../dmlc-core/include/dmlc/build_config_default.h:32:27: fatal error: execinfo.h: No such file or directory
           32 |   #define DMLC_EXECINFO_H <execinfo.h>

    Thanks

    Mi



    ------------------------------
    Mi Wang
    ------------------------------