Skip to content

Commit

Permalink
out_s3: windows: Link neccessary libraries for SHCreateDirectoryExA
Browse files Browse the repository at this point in the history
Signed-off-by: Hiroshi Hatake <[email protected]>
  • Loading branch information
cosmo0920 committed Jun 19, 2024
1 parent 582d5d3 commit b4c8c53
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
10 changes: 10 additions & 0 deletions plugins/out_s3/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,14 @@ set(src
s3_store.c
s3_multipart.c)

set(libs "")

if(${CMAKE_SYSTEM_NAME} MATCHES "Windows")
set(libs
${libs}
Shell32.lib
Shlwapi.lib)
endif()

FLB_PLUGIN(out_s3 "${src}" "")
target_link_libraries(flb-plugin-out_s3 ${libs})
4 changes: 4 additions & 0 deletions plugins/out_s3/s3.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@

#include <msgpack.h>

#ifdef FLB_SYSTEM_WINDOWS
#include <Shlobj.h>
#endif

#include "s3.h"
#include "s3_store.h"

Expand Down

0 comments on commit b4c8c53

Please sign in to comment.