From 723729922a5e420c5ee19cebcec3ff4b3be74549 Mon Sep 17 00:00:00 2001 From: Matthew Silverman Date: Fri, 26 Feb 2021 16:25:50 -0500 Subject: [PATCH 1/2] update tracing libraries remove unused boost_static option --- images/nginx/rootfs/build.sh | 26 ++++++++++++-------------- 1 file changed, 12 insertions(+), 14 deletions(-) diff --git a/images/nginx/rootfs/build.sh b/images/nginx/rootfs/build.sh index 167485a46b..8e6645bfe0 100755 --- a/images/nginx/rootfs/build.sh +++ b/images/nginx/rootfs/build.sh @@ -24,12 +24,12 @@ export SETMISC_VERSION=0.32 export MORE_HEADERS_VERSION=0.33 export NGINX_DIGEST_AUTH=cd8641886c873cf543255aeda20d23e4cd603d05 export NGINX_SUBSTITUTIONS=bc58cb11844bc42735bbaef7085ea86ace46d05b -export NGINX_OPENTRACING_VERSION=0.10.0 -export OPENTRACING_CPP_VERSION=1.5.1 -export ZIPKIN_CPP_VERSION=0.5.2 -export JAEGER_VERSION=0.4.2 +export NGINX_OPENTRACING_VERSION=0.11.0 +export OPENTRACING_CPP_VERSION=1.6.0 +export ZIPKIN_CPP_VERSION=f69593138ff84ca2f6bc115992e18ca3d35f344a +export JAEGER_VERSION=0.7.0 export MSGPACK_VERSION=3.2.1 -export DATADOG_CPP_VERSION=1.2.0 +export DATADOG_CPP_VERSION=7b560e5c13324c0581476dad3bd8ac4ac5f64045 export MODSECURITY_VERSION=22e53aba4e3ae8c7d59a3672d6727e49246afe96 export MODSECURITY_LIB_VERSION=v3.0.4 export OWASP_MODSECURITY_CRS_VERSION=v3.3.0 @@ -138,19 +138,19 @@ get_src fe683831f832aae4737de1e1026a4454017c2d5f98cb88b08c5411dc380062f8 \ get_src 618551948ab14cac51d6e4ad00452312c7b09938f59ebff4f93875013be31f2d \ "https://github.com/yaoweibin/ngx_http_substitutions_filter_module/archive/$NGINX_SUBSTITUTIONS.tar.gz" -get_src d580efc71809cc1cd9138c1940f4f20766a0631cacf45b99c07facd93583260d \ +get_src a0087c61e82651dbdeeef1ceec375ce103f0ce571a1c8b35863cff4e596434a6 \ "https://github.com/opentracing-contrib/nginx-opentracing/archive/v$NGINX_OPENTRACING_VERSION.tar.gz" -get_src 015c4187f7a6426a2b5196f0ccd982aa87f010cf61f507ae3ce5c90523f92301 \ +get_src 5b170042da4d1c4c231df6594da120875429d5231e9baa5179822ee8d1054ac3 \ "https://github.com/opentracing/opentracing-cpp/archive/v$OPENTRACING_CPP_VERSION.tar.gz" -get_src 30affaf0f3a84193f7127cc0135da91773ce45d902414082273dae78914f73df \ - "https://github.com/rnburn/zipkin-cpp-opentracing/archive/v$ZIPKIN_CPP_VERSION.tar.gz" +get_src 71de3d0658935db7ccea20e006b35e58ddc7e4c18878b9523f2addc2371e9270 \ + "https://github.com/rnburn/zipkin-cpp-opentracing/archive/$ZIPKIN_CPP_VERSION.tar.gz" get_src 38f2ae43fceda683f652065e13a80b14a580ede476a4b44eb0ddd85665380360 \ "https://github.com/SpiderLabs/ModSecurity-nginx/archive/$MODSECURITY_VERSION.tar.gz" -get_src 21257af93a64fee42c04ca6262d292b2e4e0b7b0660c511db357b32fd42ef5d3 \ +get_src 3a3a03060bf5e3fef52c9a2de02e6035cb557f389453d8f3b0c1d3d570636994 \ "https://github.com/jaegertracing/jaeger-client-cpp/archive/v$JAEGER_VERSION.tar.gz" get_src 464f46744a6be778626d11452c4db3c2d09461080c6db42e358e21af19d542f6 \ @@ -168,8 +168,8 @@ get_src 2a69815e4ae01aa8b170941a8e1a10b6f6a9aab699dee485d58f021dd933829a \ get_src f74a0821b079ea1fd63dd8659064356fc3f421ff4b35c17877140d2b2841cc3b \ "https://github.com/openresty/luajit2/archive/v$LUAJIT_VERSION.tar.gz" -get_src 3e6fe45f467d653870985cc52a1c2cf81a8a2c7a7bcf7ffcfedfd305a47a1eca \ - "https://github.com/DataDog/dd-opentracing-cpp/archive/v$DATADOG_CPP_VERSION.tar.gz" +get_src 40cc298f22bc29621024b68503335dcce464e42bcf02246f5864d7f8f2f5c379 \ + "https://github.com/DataDog/dd-opentracing-cpp/archive/$DATADOG_CPP_VERSION.tar.gz" get_src 1af5a5632dc8b00ae103d51b7bf225de3a7f0df82f5c6a401996c080106e600e \ "https://github.com/influxdata/nginx-influxdb-module/archive/$NGINX_INFLUXDB_VERSION.tar.gz" @@ -254,7 +254,6 @@ cd .build cmake -DCMAKE_BUILD_TYPE=Release \ -DBUILD_TESTING=OFF \ - -DWITH_BOOST_STATIC=ON \ -DBUILD_SHARED_LIBS=OFF \ -DBUILD_MOCKTRACER=OFF \ -DBUILD_STATIC_LIBS=ON \ @@ -315,7 +314,6 @@ cd .build cmake -DCMAKE_BUILD_TYPE=Release \ -DBUILD_SHARED_LIBS=OFF \ - -DWITH_BOOST_STATIC=ON \ -DBUILD_PLUGIN=ON \ -DBUILD_TESTING=OFF \ -DCMAKE_POSITION_INDEPENDENT_CODE:BOOL=true \ From 5794a9360ac1c7e435edfb33379858ee09f79578 Mon Sep 17 00:00:00 2001 From: Matthew Silverman Date: Tue, 23 Mar 2021 19:42:03 -0400 Subject: [PATCH 2/2] build yaml-cpp lib in image builder --- images/nginx/rootfs/build.sh | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/images/nginx/rootfs/build.sh b/images/nginx/rootfs/build.sh index 8e6645bfe0..3084037cce 100755 --- a/images/nginx/rootfs/build.sh +++ b/images/nginx/rootfs/build.sh @@ -27,6 +27,7 @@ export NGINX_SUBSTITUTIONS=bc58cb11844bc42735bbaef7085ea86ace46d05b export NGINX_OPENTRACING_VERSION=0.11.0 export OPENTRACING_CPP_VERSION=1.6.0 export ZIPKIN_CPP_VERSION=f69593138ff84ca2f6bc115992e18ca3d35f344a +export YAML_CPP_VERSION=yaml-cpp-0.6.3 export JAEGER_VERSION=0.7.0 export MSGPACK_VERSION=3.2.1 export DATADOG_CPP_VERSION=7b560e5c13324c0581476dad3bd8ac4ac5f64045 @@ -150,6 +151,9 @@ get_src 71de3d0658935db7ccea20e006b35e58ddc7e4c18878b9523f2addc2371e9270 \ get_src 38f2ae43fceda683f652065e13a80b14a580ede476a4b44eb0ddd85665380360 \ "https://github.com/SpiderLabs/ModSecurity-nginx/archive/$MODSECURITY_VERSION.tar.gz" +get_src 77ea1b90b3718aa0c324207cb29418f5bced2354c2e483a9523d98c3460af1ed \ + "https://github.com/jbeder/yaml-cpp/archive/$YAML_CPP_VERSION.tar.gz" + get_src 3a3a03060bf5e3fef52c9a2de02e6035cb557f389453d8f3b0c1d3d570636994 \ "https://github.com/jaegertracing/jaeger-client-cpp/archive/v$JAEGER_VERSION.tar.gz" @@ -263,9 +267,29 @@ cmake -DCMAKE_BUILD_TYPE=Release \ make make install +# build yaml-cpp +# TODO @timmysilv: remove this and jaeger sed calls once it is fixed in jaeger-client-cpp +cd "$BUILD_PATH/yaml-cpp-$YAML_CPP_VERSION" +mkdir .build +cd .build + +cmake -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_POSITION_INDEPENDENT_CODE:BOOL=true \ + -DYAML_BUILD_SHARED_LIBS=ON \ + -DYAML_CPP_BUILD_TESTS=OFF \ + -DYAML_CPP_BUILD_TOOLS=OFF \ + .. + +make +make install + # build jaeger lib cd "$BUILD_PATH/jaeger-client-cpp-$JAEGER_VERSION" sed -i 's/-Werror/-Wno-psabi/' CMakeLists.txt +# use the above built yaml-cpp instead until a new version of jaeger-client-cpp fixes the yaml-cpp issue +# tl;dr new hunter is needed for new yaml-cpp, but new hunter has a conflict with old Thrift and new Boost +sed -i 's/hunter_add_package(yaml-cpp)/#hunter_add_package(yaml-cpp)/' CMakeLists.txt +sed -i 's/yaml-cpp::yaml-cpp/yaml-cpp/' CMakeLists.txt cat < export.map {