lusi12

lusi12

0个粉丝

1

问答

0

专栏

0

资料

lusi12  发布于  2017-09-19 10:16:20
采纳率 0%
1个问答
2210

编译链接C++库报错

 
RM     libvsrc.a
AR     libvsrc.a
arm-hisiv300-linux-ar: creating libvsrc.a
a - i2c/i2c.o
a - gpio/gpio.o
a - utility/utility.o
a - it6801/it680x.o
a - it6801/edid.o
a - it6801/it680x_cec.o
a - it6801/Remote.o
a - AvVideoSrc.o
G++    main.o
In file included from ./it6801/Mhlrx.h:14:0,
                 from AvVideoSrcIn.h:8,
                 from main.cpp:7:
./it6801/config.h:40:35: note: #pragma message: defined _IT6801_
#pragma message("defined _IT6801_")
                                   ^
LDFLAGS        -static -lpthread -L./
arm-hisiv300-linux-g++ -static -lpthread -L./ -o test_it6801 libvsrc.a main.o  
main.o: In function `main':
main.cpp:(.text.startup+0x4): undefined reference to `CAvVideoSrc::instance()'
main.cpp:(.text.startup+0x10): undefined reference to `CAvVideoSrc::Init(AvVideoSrcMode_E)'
main.cpp:(.text.startup+0x18): undefined reference to `CAvVideoSrc::start()'
collect2: error: ld returned 1 exit status
make: *** [test_it6801] Error 1

前面编译已经生产libvsrc.a,为什么后面生产程序已经链接了libvsrc.a还是报错(undefined reference to)?
我来回答
回答0个
时间排序
认可量排序
易百纳技术社区暂无数据
或将文件直接拖到这里
悬赏:
E币
网盘
* 网盘链接:
* 提取码:
悬赏:
E币

Markdown 语法

  • 加粗**内容**
  • 斜体*内容*
  • 删除线~~内容~~
  • 引用> 引用内容
  • 代码`代码`
  • 代码块```编程语言↵代码```
  • 链接[链接标题](url)
  • 无序列表- 内容
  • 有序列表1. 内容
  • 缩进内容
  • 图片![alt](url)
+ 添加网盘链接/附件

Markdown 语法

  • 加粗**内容**
  • 斜体*内容*
  • 删除线~~内容~~
  • 引用> 引用内容
  • 代码`代码`
  • 代码块```编程语言↵代码```
  • 链接[链接标题](url)
  • 无序列表- 内容
  • 有序列表1. 内容
  • 缩进内容
  • 图片![alt](url)
举报反馈

举报类型

  • 内容涉黄/赌/毒
  • 内容侵权/抄袭
  • 政治相关
  • 涉嫌广告
  • 侮辱谩骂
  • 其他

详细说明

易百纳技术社区