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

Close

Unable to use cmake to link blas, lapack and fft

Help
Yi-Ping
2013-06-28
2013-07-01
  • Yi-Ping
    Yi-Ping
    2013-06-28

    Hi,

    I try to install itpp on scientific linux.
    I have blas and lapack installed.
    But when I follow the instruction to use cmake .. to generate make file. I got the following message. It seems cmake cannot link to the blas or lapack library I have. Not quite sure how to fix that. Thanks!


    -- A library with BLAS API not found. Please specify library location.
    -- A library with BLAS API not found. Please specify library location.
    -- LAPACK requires BLAS
    -- A library with LAPACK API not found. Please specify library location.
    -- Could NOT find FFT (missing: FFT_LIBRARIES FFT_INCLUDES)
    -- A library with FFT API not found. Please specify library location.
    CMake Warning at CMakeLists.txt:186 (message):
    BLAS library not found.

    CMake Warning at CMakeLists.txt:190 (message):
    LAPACK library not found.

    CMake Warning at CMakeLists.txt:194 (message):
    FFT library not found.

    CMake Warning at CMakeLists.txt:198 (message):
    You can still compile IT++ but the functionality will be reduced.

     
  • Bogdan Cristea
    Bogdan Cristea
    2013-06-28

    Hi

    Have you installed the header files for these two libraries ? Have a look at CMakeError.log and post here the relevan parts with the error messages you get.

    regards
    Bogdan

     
    • Yi-Ping
      Yi-Ping
      2013-06-28

      Hi, Bogdan,

      Thanks a lot for your answer. It reminds me that I forgot to install the header files on my machine. Now every thing works fine.

      Best,
      Yi-Ping

       
  • Navneet
    Navneet
    2013-06-28

    Hi Bogdan,
    I am trying to install itpp-4.3.0 on RHEL 6 using cmake28 (cmake version 2.8.6 is not available for RHEL 6 using yum).

    I am also getting similar message that its not able to find BLAS, LAPACK and FFTW. These libraries are present in /usr/lib64 directory. I have added this path to my LD_LIBRARY_PATH using the command export LD_LIBRARY_PATH=/usr/lib64:${LD_LIBRARY_PATH}. It is still not able to find these libraries.

    I also installed ATLAS on RHEL 6 and then gave commands
    export LD_LIBRARY_PATH=/usr/lib64/atlas:${LD_LIBRARY_PATH}
    cmake28 .. -DBLA_VENDOR=ATLAS

    Still I am getting the same problem that its not able to find BLAS, LAPACK or FFTW. Can you please help me out? You mentioned that header files need to be installed. What is that and how can I do so for these libraries?

    Thanks,
    Navneet

     
  • Yi-Ping
    Yi-Ping
    2013-06-28

    Hi, Navneet,

    You can use the add/remove software and install the develope packages for those libraryies, ie. atlas, fft. Those develop packages will include the headfiles. Once those headfiles are installed

    export LD_LIBRARY_PATH=/usr/lib64/atlas
    cmake28 .. -DBLA_VENDOR=ATLAS

    That solved my problem on SL6. Maybe you can try it.

    Best,
    Yi-Ping

     
  • Navneet
    Navneet
    2013-07-01

    Hi Yi-Ping,

    Thanks for the help. It worked I think. I was able to compile. I can see libitpp.so.8.2.0 in '/usr/local/lib' folder. So I think the itpp library was built and installed.
    But I am not able to find any place where itpp-config was installed. When I issue "itpp-config --help" on command prompt, it gives error "-bash: itpp-config: command not found". Can you please tell me what to do?

    Following are the set of commands I used for building and installation:

    % export LD_LIBRARY_PATH=/usr/lib64/atlas
    % cmake28 .. -DBLA_VENDOR=ATLAS
    % sudo make
    % sudo make install

    I just want to add that I cannot be root on the machine and hence I am using sudo.

    Thanks,
    Navneet

     
    Last edit: Navneet 2013-07-01