“No rule to make target 'install'”… But Makefile exists

后端 未结 3 1866
失恋的感觉
失恋的感觉 2020-12-31 03:46

I am running into issues installing a C++ library. The CMake command is successful and generates the Makefile, but it gives a warning:

CMake Warning (dev) at         


        
相关标签:
3条回答
  • 2020-12-31 03:56

    I also came across the same error. Here is the fix: If you are using Cmake-GUI:

    1. Clean the cache of the loaded libraries in Cmake-GUI File menu.
    2. Configure the libraries.
    3. Generate the Unix file.

    If you missed the 3rd step:

    *** No rule to make target `install'. Stop.

    error will occur.

    0 讨论(0)
  • 2020-12-31 04:17

    Could you provide a whole makefile? But right now I can tell - you should check that "install" target already exists. So, check Makefile whether it contains a

    install: (anything there)
    

    line. If not, there is no such target and so make has right. Probably you should use just "make" command to compile and then use it as is or install yourself, manually.

    Install is not any standard of make, it is just a common target, that could exists, but not necessary.

    0 讨论(0)
  • 2020-12-31 04:18

    I was receiving the same error message, and my issue was that I was not in the correct directory when running the command make install. When I changed to the directory that had my makefile it worked.

    So possibly you aren't in the right directory.

    0 讨论(0)
提交回复
热议问题