summaryrefslogtreecommitdiff
path: root/indra/cmake/NGHTTP2.cmake
blob: 5215af5dd9a41b8969343f336fb4398b302d3c08 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
include(Prebuilt)

if( TARGET nghttp2::nghttp2 )
  return()
endif()
create_target( nghttp2::nghttp2 )

if (USESYSTEMLIBS)
  include(FindNGHTTP2)
else (USESYSTEMLIBS)
  use_prebuilt_binary(nghttp2)
  if (WINDOWS)
    set_target_libraries( nghttp2::nghttp2 ${ARCH_PREBUILT_DIRS_RELEASE}/nghttp2.lib)
  elseif (DARWIN)
    set_target_libraries( nghttp2::nghttp2 libnghttp2.dylib)
  else (WINDOWS)
    set_target_libraries( nghttp2::nghttp2 libnghttp2.a )
  endif (WINDOWS)
  set_target_include_dirs( nghttp2::nghttp2 ${LIBS_PREBUILT_DIR}/include/nghttp2)
endif (USESYSTEMLIBS)