blob: f2fe2d6b727c01c596fb48c6f03b86a943f032b6 [file] [log] [blame]
Miroslav Zagorac70230c62020-12-09 16:54:31 +01001#!/bin/sh
2#
3_ARG_DIR="${1:-.}"
4
5
6get ()
7{
8 local _arg_tracer="${1}"
9 local _arg_version="${2}"
10 local _arg_url="${3}"
11 local _arg_file="${4}"
12 local _var_tmpfile="_tmpfile_"
13 local _var_plugin="lib${_arg_tracer}_opentracing_plugin-${_arg_version}.so"
14
15 test -e "${_var_plugin}" && return 0
16
17 wget "https://github.com/${_arg_url}/releases/download/v${_arg_version}/${_arg_file}" -O "${_var_tmpfile}" || {
18 rm "${_var_tmpfile}"
19 return 1
20 }
21
22 case "$(file ${_var_tmpfile})" in
23 *shared\ object*)
24 mv "${_var_tmpfile}" "${_var_plugin}" ;;
25
26 *gzip\ compressed\ data*)
27 gzip -cd "${_var_tmpfile}" > "${_var_plugin}"
28 rm "${_var_tmpfile}" ;;
29 esac
30}
31
32
33mkdir -p "${_ARG_DIR}" && cd "${_ARG_DIR}" || exit 1
34
35get dd 1.1.2 DataDog/dd-opentracing-cpp linux-amd64-libdd_opentracing_plugin.so.gz
36get dd 1.2.0 DataDog/dd-opentracing-cpp linux-amd64-libdd_opentracing_plugin.so.gz
37
38get jaeger 0.4.2 jaegertracing/jaeger-client-cpp libjaegertracing_plugin.linux_amd64.so
39#et jaeger 0.5.0 jaegertracing/jaeger-client-cpp libjaegertracing_plugin.linux_amd64.so
40#et jaeger 0.6.0 jaegertracing/jaeger-client-cpp libjaegertracing_plugin.linux_amd64.so
41
42get lightstep 0.12.0 lightstep/lightstep-tracer-cpp linux-amd64-liblightstep_tracer_plugin.so.gz
43get lightstep 0.13.0 lightstep/lightstep-tracer-cpp linux-amd64-liblightstep_tracer_plugin.so.gz
44
45get zipkin 0.5.2 rnburn/zipkin-cpp-opentracing linux-amd64-libzipkin_opentracing_plugin.so.gz