LNK1104 Visual Studio 2015年 [英] LNK1104 Visual studio 2015

查看:105
本文介绍了LNK1104 Visual Studio 2015年的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用Windows构建Caffe深度学习网络解决方案,并且确实尝试了所有方法以使其正常工作。

I am trying to build Caffe Deep Learning Network solution using Windows and I have literally tried everything to make it work.

我发现了类似的问题,但是他们正在使用VS 2010或2013,我在大多数答案中都没有列出任何选项。

I found similar questions, but they were using VS 2010 or 2013 and I don't have any of the options listed in most of the answers.

首先:
我正在使用VS 2015,cudNN和最新的Caffe,我正在尝试使用Windows x64进行构建。

Firstly: I am using VS 2015, cudNN and latest Caffe, and I am trying to build it using Windows x64.

第二次:
我尝试了两种方法(在两种情况下都以添加cudNN路径开始)

Secondly: I have tried two approaches (started off with adding cudNN path in both cases)

1)
参考: http://embedonix.com/articles/machine-learning/compiling-caffe-with-cuda-and-cudnn- support-on-windows-from-source / 2 /

我使用了以下命令:

nuget restore Caffe.sln -PackagesDirectory ..\..\NugetPackages -ConfigFile nuget.config

然后启动Visual Studio并尝试构建解决方案,但出现此错误:

then launched Visual Studio and tried to build the solution, but I get this error:

LNK1104 cannot open file 'libboost_date_time-vc140-mt-gd-1_59.lib'  classification  

2)我尝试使用此方法: https://github.com/BVLC/caffe/tree/windows

2) I tried using this method:https://github.com/BVLC/caffe/tree/windows, which is from their oficial website.

但是我收到了错误消息:过程入口point_CrtSetCheckCOunt不能位于动态链接库中……protoc.exe

But I am getting error: "The procedure entry point_CrtSetCheckCOunt could not be located in the dynamic link library... protoc.exe"

有人可以解决所有这些问题,所以我可以安装它吗?

Does anyone have a solution of how to solve any of these issues,so I could install it?

推荐答案

我正面临一个类似的问题。
您的代码所依赖的库之一确实取决于boost。

I am facing a simmilar issue. One of the libraries your code depends on does depend on boost.

您的代码现在也需要导入boost。

Your code now also needs to import boost.

幸运的是,可以通过nuget获得增强包。您需要递归地手动检查它们,直到错误消失。第一个是 boost_date_time

Luckily there are boost packages available via nuget. You need to recursibely manually check them all out until the errors are gone. The first one would be boost_date_time.

我的软件包文件现在看起来像这样:

My packages file now looks like this:

  <packages>
    <package id="boost" version="1.63.0.0" targetFramework="native" />
    <package id="boost_atomic-vc140" version="1.63.0.0" targetFramework="native" />
    <package id="boost_chrono-vc140" version="1.63.0.0" targetFramework="native" />
    <package id="boost_date_time-vc140" version="1.63.0.0" targetFramework="native" />
    <package id="boost_filesystem-vc140" version="1.63.0.0" targetFramework="native" />
    <package id="googletest" version="1.8.0.0" targetFramework="native" />
  </packages>

之所以有效,是因为现在扩展了项目目标,并且您获得了lib目录的路径文件作为添加到项目中的附加库目录。

This works because the project targets are now beeing extended and you get the path to the directory of the lib file as additional library directory added to the project.

您现在可能会遇到的下一个错误是LNK2019,它将连接到boost库中的全部或部分链接动态地依赖于您。对于我来说,这里的解决方案与您这里使用的解决方案有所不同-但我确信有特定于Caffe的解决方案可用。

The next error you may get now is LNK2019 and that would be connected to all or parts of the boost library beeing linked in dynamically in your dependency. The solution for me is different for the solution for you here - but I am sure there is a Caffe specific solution available.

这篇关于LNK1104 Visual Studio 2015年的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆