x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Using libcurl within a Plugin

Hello everyone.

I've been trying to use libcurl in my plugin, but I've hit several brick walls.

First, I've tried to use the included libcurl, but no dice.

Secondly, I grabbed the libcurl and plopped it in the project's ThirdParty folder, and then adding it to my plugin's Build.cs via PublicIncludePaths.Add and PublicAdditionalLibraries.Add, but again it failed.

The error messages that I'm getting over and over are these:

   [2017.12.15-10.09.38:241][751]CompilerResultsLog: New page: Compilation - 15 Dec 2017 14:09:38
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Compiling game modules for hot reload
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Performing 4 actions (4 in parallel)
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Module.TiniestAnalytics.cpp
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Module.TiniestAnalytics.gen.cpp
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\winnt.h(536): warning C4005: 'TEXT': macro redefinition
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/Platform.h(839) : note: see previous definition of 'TEXT'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\winnt.h(17005): warning C4668: '_APISET_RTLSUPPORT_VER' is not defined as a preprocessor macro, replacing with '0' for '#if/#elif'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\interlockedapi.h(73): warning C4668: '_APISET_INTERLOCKED_VER' is not defined as a preprocessor macro, replacing with '0' for '#if/#elif'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\processthreadsapi.h(1170): warning C4668: '_WIN32_WINNT_WINTHRESHOLD' is not defined as a preprocessor macro, replacing with '0' for '#if/#elif'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\securitybaseapi.h(357): warning C4668: '_APISET_SECURITYBASE_VER' is not defined as a preprocessor macro, replacing with '0' for '#if/#elif'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\securitybaseapi.h(472): warning C4668: '_APISET_SECURITYBASE_VER' is not defined as a preprocessor macro, replacing with '0' for '#if/#elif'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\securitybaseapi.h(1302): warning C4668: '_APISET_SECURITYBASE_VER' is not defined as a preprocessor macro, replacing with '0' for '#if/#elif'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\winbase.h(8618): warning C4668: 'NTDDI_WIN7SP1' is not defined as a preprocessor macro, replacing with '0' for '#if/#elif'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(67) : error C2039: '_InterlockedIncrement': is not a member of 'FWindowsPlatformAtomics'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: C:\Program Files\Epic Games\UE_4.17\Engine\Source\Runtime\Core\Public\Windows/WindowsPlatformAtomics.h(14) : note: see declaration of 'FWindowsPlatformAtomics'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(67) : error C2665: '_InterlockedIncrement': none of the 4 overloads could convert all the argument types
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\winbase.h(8844): note: could be 'unsigned __int64 _InterlockedIncrement(volatile unsigned __int64 *)'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\winbase.h(8833): note: or       'unsigned long _InterlockedIncrement(volatile unsigned long *)'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\winbase.h(8824): note: or       'unsigned int _InterlockedIncrement(volatile unsigned int *)'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.11.25503\INCLUDE\intrin0.h(186): note: or       'long _InterlockedIncrement(volatile long *)'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(67) : note: while trying to match the argument list '(volatile int64 *)'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(79) : error C2039: '_InterlockedAdd': is not a member of 'FWindowsPlatformAtomics'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: C:\Program Files\Epic Games\UE_4.17\Engine\Source\Runtime\Core\Public\Windows/WindowsPlatformAtomics.h(14) : note: see declaration of 'FWindowsPlatformAtomics'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(79) : error C2664: 'LONG _InterlockedAdd(volatile LONG *,LONG)': cannot convert argument 1 from 'volatile int64 *' to 'volatile LONG *'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(79) : note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(90) : error C2039: '_InterlockedDecrement': is not a member of 'FWindowsPlatformAtomics'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: C:\Program Files\Epic Games\UE_4.17\Engine\Source\Runtime\Core\Public\Windows/WindowsPlatformAtomics.h(14) : note: see declaration of 'FWindowsPlatformAtomics'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(90) : error C2665: '_InterlockedDecrement': none of the 4 overloads could convert all the argument types
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\winbase.h(8875): note: could be 'unsigned __int64 _InterlockedDecrement(volatile unsigned __int64 *)'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\winbase.h(8864): note: or       'unsigned long _InterlockedDecrement(volatile unsigned long *)'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\winbase.h(8855): note: or       'unsigned int _InterlockedDecrement(volatile unsigned int *)'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.11.25503\INCLUDE\intrin0.h(151): note: or       'long _InterlockedDecrement(volatile long *)'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(90) : note: while trying to match the argument list '(volatile int64 *)'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(102) : error C2039: '_InterlockedAdd': is not a member of 'FWindowsPlatformAtomics'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: C:\Program Files\Epic Games\UE_4.17\Engine\Source\Runtime\Core\Public\Windows/WindowsPlatformAtomics.h(14) : note: see declaration of 'FWindowsPlatformAtomics'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(102) : error C2664: 'LONG _InterlockedAdd(volatile LONG *,LONG)': cannot convert argument 1 from 'volatile int64 *' to 'volatile LONG *'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(102) : note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(114) : error C2039: '_InterlockedExchange': is not a member of 'FWindowsPlatformAtomics'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: C:\Program Files\Epic Games\UE_4.17\Engine\Source\Runtime\Core\Public\Windows/WindowsPlatformAtomics.h(14) : note: see declaration of 'FWindowsPlatformAtomics'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(114) : error C2665: '_InterlockedExchange': none of the 4 overloads could convert all the argument types
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\winbase.h(8910): note: could be 'unsigned __int64 _InterlockedExchange(volatile unsigned __int64 *,unsigned __int64)'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\winbase.h(8898): note: or       'unsigned long _InterlockedExchange(volatile unsigned long *,unsigned long)'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\winbase.h(8888): note: or       'unsigned int _InterlockedExchange(volatile unsigned int *,unsigned int)'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.11.25503\INCLUDE\intrin0.h(153): note: or       'long _InterlockedExchange(volatile long *,long)'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(114) : note: while trying to match the argument list '(volatile int64 *, int64)'
   [2017.12.15-10.09.38:242][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(125) : error C2039: '_InterlockedExchange': is not a member of 'FWindowsPlatformAtomics'
   [2017.12.15-10.09.38:243][751]CompilerResultsLog: Error: C:\Program Files\Epic Games\UE_4.17\Engine\Source\Runtime\Core\Public\Windows/WindowsPlatformAtomics.h(14) : note: see declaration of 'FWindowsPlatformAtomics'
   [2017.12.15-10.09.38:243][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(125) : error C2665: '_InterlockedExchange': none of the 4 overloads could convert all the argument types
   [2017.12.15-10.09.38:243][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\winbase.h(8910): note: could be 'unsigned __int64 _InterlockedExchange(volatile unsigned __int64 *,unsigned __int64)'
   [2017.12.15-10.09.38:243][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\winbase.h(8898): note: or       'unsigned long _InterlockedExchange(volatile unsigned long *,unsigned long)'
   [2017.12.15-10.09.38:243][751]CompilerResultsLog: C:\Program Files (x86)\Windows Kits\8.1\include\um\winbase.h(8888): note: or       'unsigned int _InterlockedExchange(volatile unsigned int *,unsigned int)'
   [2017.12.15-10.09.38:243][751]CompilerResultsLog: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.11.25503\INCLUDE\intrin0.h(153): note: or       'long _InterlockedExchange(volatile long *,long)'
   [2017.12.15-10.09.38:243][751]CompilerResultsLog: Error: c:\program files\epic games\ue_4.17\engine\source\runtime\core\public\HAL/ThreadSafeCounter64.h(125) : note: while trying to match the argument list '(volatile int64 *, int)'
   [2017.12.15-10.09.38:243][751]CompilerResultsLog: Error: C:\Program Files\Epic Games\UE_4.17\Engine\Source\Runtime\Engine\Classes\Engine/TextureCube.h(69) : error C3668: 'UTextureCube::UpdateResourceW': method with override specifier 'override' did not override any base class methods
   [2017.12.15-10.09.38:243][751]CompilerResultsLog: Error: C:\Program Files\Epic Games\UE_4.17\Engine\Source\Runtime\Engine\Classes\Engine/CanvasRenderTarget2D.h(43) : error C3668: 'UCanvasRenderTarget2D::UpdateResourceW': method with override specifier 'override' did not override any base class methods
   [2017.12.15-10.09.38:243][751]CompilerResultsLog: ERROR: UBT ERROR: Failed to produce item: C:\Users\alexg\Documents\Unreal Projects\PluginDevelopment\Plugins\TiniestAnalytics\Binaries\Win64\UE4Editor-TiniestAnalytics-6443.dll
   [2017.12.15-10.09.38:243][751]CompilerResultsLog: Total build time: 15.62 seconds (Local executor: 0.00 seconds)
Product Version: UE 4.17
Tags:
more ▼

asked Dec 15 '17 at 03:56 PM in C++ Programming

avatar image

DickKickem.
28 2 5 9

avatar image Shadowriver Dec 15 '17 at 09:07 PM
avatar image DickKickem. Dec 16 '17 at 10:17 AM

Yeah, I am. But the library I'm trying to port is heavily dependant on libcurl. I'd rather not rewrite the whole thing if UE4 offers libcurl.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

try adding this to build script

 AddEngineThirdPartyPrivateStaticDependencies(Target, "libcurl");

Also you have soem missing definition like you bypassing make system for library you use, you should build the library with it's own build system. I once tried to use third party library and by using this i was able to build it based on it's own build system:

https://wiki.unrealengine.com/Linking_Static_Libraries_Using_The_Build_System

more ▼

answered Dec 16 '17 at 08:05 PM

avatar image

Shadowriver
35.7k 926 168 1104

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question