visual-c++ - 类 'boost::shared_ptr<T>' 需要有 dll 接口(interface)才能由类 'boost::signals::connection' 的客户端使用

标签 visual-c++ warnings boost-signals

编译代码时出现以下错误。

c:\boost_1_48_0\boost\signals\connection.hpp(118) : warning C4251: 'boost::signals::connection::con' : class 'boost
::shared_ptr<T>' needs to have dll-interface to be used by clients of class 'boost::signals::connection'

代码中的信号定义为

boost::signal<void (long long int)> totalTimeChanged;
boost::signal<void (unsigned int)> curTimeChanged;

连接完成

GStreamer::totalTimeChanged.connect(boost::bind(&MainWindow\
            ::total_time_changed, &player, _1));

编译成功,但是如何摆脱这些编译器警告?

最佳答案

关于visual-c++ - 类 'boost::shared_ptr<T>' 需要有 dll 接口(interface)才能由类 'boost::signals::connection' 的客户端使用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11734510/

相关文章:

windows - 如何更改自定义打印对话框属性

java - 如何抑制 m2e 警告?

c# - MSIL 或 native 代码中的 "Unreachable code detected"

c++ - 我可以使用 Boost Signals2 和 Threads 在 C++ 中创建软件看门狗计时器线程吗?

c++ - 如何复制 boost 信号的槽

c++ - CLR C++ VS C++ (pstsdk)

c++ - 从 stringstream 获取所有内容

c++ - 通过取消引用迭代器将 Vector 写入文件

android - 由于窗口没有焦点而丢弃事件