Unable to set CURL path in xcode with Cocos2dx v3.12

I am getting curl/curl.h file not found error while compiling my cocos2dx project. I have already added curl path in build settings under Header Search Path. The same was working with Cocos2dx v3.6.

I tried everything i can think of but no luck. I have also tried to look into the cpp tests which comes with the Cocos2dx and did the same in my sample but did not work.

Please guide to the correct way to set the curl path in xcode with newer version of cocos2dx v3.12.

Any help will be appreciated. Thanks in advance.

How did you obtain Cocos2d-x? By downloading the .zip or cloning from our GitHub repo?

By downloading the zip file.
Now, the Xcode is able to find curl.h file but when i try to use it in HelloWorldScene.cpp class then i am getting following error:
Undefined symbols for architecture x86_64:
“_curl_easy_cleanup”, referenced from:
HelloWorld::lookup() in HelloWorldScene.o

Following is my code in which I am getting the above error:

CURL *curlHandle;
    CURLcode res;
    long http_code = 0;
    curlHandle = curl_easy_init ( ) ;
    if(!curlHandle)
    {
        return 500;
    }
    curl_easy_setopt(curlHandle, CURLOPT_WRITEFUNCTION, hostLookupCallback);
    curl_easy_setopt(curlHandle, CURLOPT_WRITEDATA, (void *)this);
    curl_easy_setopt(curlHandle, CURLOPT_FOLLOWLOCATION, 1 );
    
    std::string path = "127.0.0.1";
    path.append("?api=");
    path.append("api");
    
    
    curl_easy_setopt(curlHandle, CURLOPT_URL, path.c_str());
    
    res = curl_easy_perform( curlHandle );
    if(res == CURLE_OK)
    {
        curl_easy_getinfo (curlHandle, CURLINFO_RESPONSE_CODE, &http_code);
    }
    else
    {
        http_code = 500;
    }
    
    curl_easy_cleanup( curlHandle ); 

Please help me with this, I am stuck at it and not able to proceed further.
Thanks in advance.

are you including curl.h?

Yes, I am including curl.h as follows:
#include “curl/curl.h”

if you right click on curl_easy_cleanup and say Jump To Definition does it do it or return a symbol not found?

Yes, I am able to locate curl_easy_cleanup inside easy.h class