在 vs c++ 2017 中链接 libjpeg-turbo [英] Link libjpeg-turbo in vs c++ 2017

查看:22
本文介绍了在 vs c++ 2017 中链接 libjpeg-turbo的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的问题相当简单.我无法在我的项目中链接 libjpeg-turbo.

我想试试

我不确定我做错了什么:

解决方案

您可以从 github 下载 vcpkg 并在 Powershell 提示符下运行 vcpkg.exe(以管理模式打开).vcpkg 可以安装许多开源项目(支持静态和动态库)作为准备在 VS 2017 和 VS 2015 (SP3) IDE 中使用的包.您可以选择 x86 或 x64 平台,在某些情况下甚至允许选择工具集(例如 .\vcpkg install boost:x64-windows-v141 ).如果您使用集成安装"作为 vcpkg 命令行,所有库将自动与您的项目链接,项目 .dll 文件将自动复制到您的应用程序文件夹.

因此,在您的情况下,在安装 vcpkg.exe 后,您键入 .\vcpkg install libjpeg-turbo:x64-windows-static 并在安装后键入 .\vcpkg 集成安装.jpeg 库将自动链接到您的项目(重新启动您的 VS 2017 并享受).

my problem is fairly simple.. I'm not able to link libjpeg-turbo in my project.

I'm looking to try this exemple, but i'm not able to compile :

I'm not sure what i'm doing wrong :

解决方案

You can download vcpkg from github and run vcpkg.exe in the Powershell prompt( opened in administrative mode) . vcpkg can install many open source projects (both static and dynamic libraries are supported) as packages ready for use in VS 2017 and VS 2015 (SP3) IDE. You can use choose x86 or x64 platform and in some cases even allows selection of toolset ( eg .\vcpkg install boost:x64-windows-v141 ). If you use 'integrate install' as the vcpkg command line, all the libraries will be automatically linked with your project and the project .dll files will be automatically copied to your application folder.

So, in your case, after the the installation of vcpkg.exe, you type .\vcpkg install libjpeg-turbo:x64-windows-static and after installation type .\vcpkg integrate install. The jpeg library will be linked automatically to your project (Restart your VS 2017 and enjoy).

这篇关于在 vs c++ 2017 中链接 libjpeg-turbo的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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