【问题标题】:I want to know this cause and solution我想知道这个原因和解决方法
【发布时间】:2017-04-27 01:12:24
【问题描述】:

[ 6%] 构建目标ChainedLib

[ 12%] 构建目标 ChainedApp

[15%] 链接 CXX 可执行 ColorConsole

/usr/bin/ld: 无法打开输出文件 ColorConsole: 是目录

collect2: 错误:ld 返回 1 个退出状态

make[2]: *** [ColorConsole] 오류 1

make[1]: *** [CMakeFiles/ColorConsole.dir/all] 오류 2

make: *** [all] 오류 2

我安装了 plog 库。 cmake CMakeList.txt 完成。但是,makefile 失败了 我不知道原因

【问题讨论】:

  • 错误就在那里。它正在尝试链接一个名为ColorConsole 的可执行文件,但有一个目录名为该目录。

标签: c++ makefile cmake


【解决方案1】:

您有一个名为ColorConsole 的目录。 makefile 尝试生成具有该名称的文件。该解决方案最有可能删除(或重命名)目录。

【讨论】:

    猜你喜欢
    • 2022-01-25
    • 2021-03-11
    • 2020-12-28
    • 2022-11-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-09-08
    • 2022-06-12
    相关资源
    最近更新 更多