Libcurl Library development environment settings under Visual Studio in Cocos Development

Source: Internet
Author: User

Let's introduce the Libcurl Library development environment settings under Visual Studio in Win32.
Cocos2d-x engine has actually had access to the Libcurl library for Win32, Cocos2d-x 3.x in the location of the Libcurl library file is the < Engineering directory >\cocos2d\external\curl\prebuilt\ In the Win32 directory, the header file is in the < catalog >\cocos2d\external\curl\include\win32 directory.
First, we need to configure the header file search path, select the Hellocpp Project, open the menu "project" → "properties" pop-up project Properties dialog box, select "Configuration Properties" → "C + +" → "general", add $ (engineroot) to "additional included directories" to the right external \curl\include\win32, note that you need to separate the configuration items with semicolons.


Configure header File Search path

After you add the search path, you can add the following code to the program to introduce the header file.
#include "curl/curl.h"
The project is then compiled and the configuration succeeds if there is no compilation error.


Next we also need to configure the Libcurl library file to attach dependencies in the linked environment. Open the Project Properties dialog box, select "Configuration Properties" → "connector" → "input", and in the right window, "Additional Dependencies", add content libcurl_imp.lib.





For more information, please pay attention to the first Cocos2d-x 3.2 Edition book "Cocos2d-x: C + + volume"

Book Exchange Discussion website: http://www.cocoagame.net
For more exciting video courses, please follow Cocos class: Http://v.51work6.com

Welcome to join Cocos2d-x Technical discussion group: 257760386

Welcome to Luxgen iOS Classroom public Platform


Libcurl Library development environment settings under Visual Studio in Cocos Development

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.