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.
After you add a search path to the configuration header file 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 discussionwebsite: http://www.c ocoagame.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