Skip to content

Commit cefd815

Browse files
committed
Merge remote-tracking branch 'origin/main' into feature_add_cmake_package_components
2 parents 70c3232 + 4ecafb6 commit cefd815

File tree

5 files changed

+47
-25
lines changed

5 files changed

+47
-25
lines changed

.github/workflows/ci.yml

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -301,21 +301,21 @@ jobs:
301301
run: |
302302
./ci/do_ci.sh cmake.with_async_export.test
303303
304-
cmake_abseil_stl_test:
305-
name: CMake test (with abseil)
306-
runs-on: ubuntu-20.04
307-
steps:
308-
- uses: actions/checkout@v4
309-
with:
310-
submodules: 'recursive'
311-
- name: setup
312-
run: |
313-
sudo -E ./ci/setup_googletest.sh
314-
sudo -E ./ci/setup_ci_environment.sh
315-
- name: run cmake tests (enable abseil-cpp)
316-
run: |
317-
sudo ./ci/install_abseil.sh
318-
./ci/do_ci.sh cmake.abseil.test
304+
# cmake_abseil_stl_test:
305+
# name: CMake test (with abseil)
306+
# runs-on: ubuntu-20.04
307+
# steps:
308+
# - uses: actions/checkout@v4
309+
# with:
310+
# submodules: 'recursive'
311+
# - name: setup
312+
# run: |
313+
# sudo -E ./ci/setup_googletest.sh
314+
# sudo -E ./ci/setup_ci_environment.sh
315+
# - name: run cmake tests (enable abseil-cpp)
316+
# run: |
317+
# sudo ./ci/install_abseil.sh
318+
# ./ci/do_ci.sh cmake.abseil.test
319319

320320
cmake_opentracing_shim_test:
321321
name: CMake test (with opentracing-shim)
@@ -333,7 +333,7 @@ jobs:
333333

334334
cmake_test_cxx14_gcc:
335335
name: CMake C++14 test(GCC)
336-
runs-on: ubuntu-20.04
336+
runs-on: ubuntu-22.04
337337
steps:
338338
- uses: actions/checkout@v4
339339
with:
@@ -349,7 +349,7 @@ jobs:
349349

350350
cmake_test_cxx17_gcc:
351351
name: CMake C++17 test(GCC)
352-
runs-on: ubuntu-20.04
352+
runs-on: ubuntu-22.04
353353
steps:
354354
- uses: actions/checkout@v4
355355
with:
@@ -365,7 +365,7 @@ jobs:
365365

366366
cmake_test_cxx20_gcc:
367367
name: CMake C++20 test(GCC)
368-
runs-on: ubuntu-20.04
368+
runs-on: ubuntu-22.04
369369
steps:
370370
- uses: actions/checkout@v4
371371
with:
@@ -465,7 +465,7 @@ jobs:
465465

466466
cmake_otprotocol_test:
467467
name: CMake test (with otlp-exporter)
468-
runs-on: ubuntu-20.04
468+
runs-on: ubuntu-22.04
469469
steps:
470470
- uses: actions/checkout@v4
471471
with:
@@ -515,7 +515,7 @@ jobs:
515515
516516
cmake_do_not_install_test:
517517
name: CMake do not install test (with otlp-exporter)
518-
runs-on: ubuntu-20.04
518+
runs-on: ubuntu-22.04
519519
steps:
520520
- uses: actions/checkout@v4
521521
with:
@@ -531,7 +531,7 @@ jobs:
531531
532532
cmake_otprotocol_shared_libs_with_static_grpc_test:
533533
name: CMake test (build shared libraries with otlp-exporter and static gRPC)
534-
runs-on: ubuntu-20.04
534+
runs-on: ubuntu-22.04
535535
steps:
536536
- uses: actions/checkout@v4
537537
with:
@@ -790,7 +790,7 @@ jobs:
790790

791791
copyright:
792792
name: Copyright
793-
runs-on: ubuntu-20.04
793+
runs-on: ubuntu-22.04
794794
steps:
795795
- uses: actions/checkout@v4
796796
- name: check copyright

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,9 @@ For edit access, get in touch on
9595
[Approvers](https://github.com/open-telemetry/community/blob/main/community-membership.md#approver)
9696
([@open-telemetry/cpp-approvers](https://github.com/orgs/open-telemetry/teams/cpp-approvers)):
9797

98+
* [Doug Barker](https://github.com/dbarker)
9899
* [Josh Suereth](https://github.com/jsuereth), Google
100+
* [Pranav Sharma](https://github.com/psx95), Google
99101
* [WenTao Ou](https://github.com/owent), Tencent
100102

101103
[Emeritus

ci/install_abseil.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,9 @@ ABSEIL_CPP_BUILD_OPTIONS=(
2121
)
2222

2323
if [ ! -z "${CXX_STANDARD}" ]; then
24-
ABSEIL_CPP_BUILD_OPTIONS=(${ABSEIL_CPP_BUILD_OPTIONS[@]} "-DCMAKE_CXX_STANDARD=${CXX_STANDARD}")
24+
ABSEIL_CPP_BUILD_OPTIONS+=("-DCMAKE_CXX_STANDARD=${CXX_STANDARD}")
25+
ABSEIL_CPP_BUILD_OPTIONS+=("-DCMAKE_CXX_STANDARD_REQUIRED=ON")
26+
ABSEIL_CPP_BUILD_OPTIONS+=("-DCMAKE_CXX_EXTENSIONS=OFF")
2527
fi
2628

2729
#
@@ -59,6 +61,9 @@ else
5961
echo "Not patching abseil"
6062
fi
6163

64+
echo "Building abseil ${ABSEIL_CPP_VERSION}"
65+
echo "CMake build options:" "${ABSEIL_CPP_BUILD_OPTIONS[@]}"
66+
6267
mkdir build && pushd build
6368
cmake "${ABSEIL_CPP_BUILD_OPTIONS[@]}" ..
6469
make -j $(nproc)

ci/install_protobuf.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,9 @@ CPP_PROTOBUF_BUILD_OPTIONS=(
3838
)
3939

4040
if [ ! -z "${CXX_STANDARD}" ]; then
41-
CPP_PROTOBUF_BUILD_OPTIONS=(${CPP_PROTOBUF_BUILD_OPTIONS[@]} "-DCMAKE_CXX_STANDARD=${CXX_STANDARD}")
41+
CPP_PROTOBUF_BUILD_OPTIONS+=("-DCMAKE_CXX_STANDARD=${CXX_STANDARD}")
42+
CPP_PROTOBUF_BUILD_OPTIONS+=("-DCMAKE_CXX_STANDARD_REQUIRED=ON")
43+
CPP_PROTOBUF_BUILD_OPTIONS+=("-DCMAKE_CXX_EXTENSIONS=OFF")
4244
fi
4345

4446
# After protobuf 22/4.22, protobuf depends on absl and we can use
@@ -59,6 +61,9 @@ cd /tmp
5961
wget https://github.com/google/protobuf/releases/download/v${PROTOBUF_VERSION}/${CPP_PROTOBUF_PACKAGE_NAME}.tar.gz
6062
tar zxf ${CPP_PROTOBUF_PACKAGE_NAME}.tar.gz --no-same-owner
6163

64+
echo "Building protobuf ${CPP_PROTOBUF_VERSION}"
65+
echo "CMake build options:" "${CPP_PROTOBUF_BUILD_OPTIONS[@]}"
66+
6267
mkdir protobuf-${CPP_PROTOBUF_VERSION}/build && pushd protobuf-${CPP_PROTOBUF_VERSION}/build
6368
if [ -e "../CMakeLists.txt" ]; then
6469
cmake .. "${CPP_PROTOBUF_BUILD_OPTIONS[@]}"

ci/setup_grpc.sh

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,9 @@ while getopts ":v:hi:mp:r:s:TH" o; do
5050
elif [ "${OPTARG}" == "abseil-cpp" ]; then
5151
GRPC_BUILD_OPTIONS=(${GRPC_BUILD_OPTIONS[@]} "-DgRPC_ABSL_PROVIDER=package")
5252
build_internal_abseil_cpp=0
53+
else
54+
usage
55+
exit 1;
5356
fi
5457
;;
5558
r)
@@ -102,6 +105,8 @@ if [[ $build_internal_abseil_cpp -ne 0 ]]; then
102105
ABSEIL_CPP_BUILD_OPTIONS=(
103106
-DCMAKE_BUILD_TYPE=Release
104107
-DCMAKE_CXX_STANDARD=${std_version}
108+
-DCMAKE_CXX_STANDARD_REQUIRED=ON
109+
-DCMAKE_CXX_EXTENSIONS=OFF
105110
-DCMAKE_POSITION_INDEPENDENT_CODE=TRUE
106111
-DCMAKE_INSTALL_PREFIX=$INSTALL_DIR
107112
)
@@ -117,12 +122,14 @@ GRPC_BUILD_OPTIONS=(
117122
${GRPC_BUILD_OPTIONS[@]}
118123
-DgRPC_INSTALL=ON
119124
-DCMAKE_CXX_STANDARD=${std_version}
125+
-DCMAKE_CXX_STANDARD_REQUIRED=ON
126+
-DCMAKE_CXX_EXTENSIONS=OFF
120127
-DgRPC_BUILD_TESTS=OFF
128+
-DgRPC_BUILD_GRPC_CPP_PLUGIN=ON
121129
-DgRPC_BUILD_GRPC_CSHARP_PLUGIN=OFF
122130
-DgRPC_BUILD_GRPC_OBJECTIVE_C_PLUGIN=OFF
123131
-DgRPC_BUILD_GRPC_PHP_PLUGIN=OFF
124132
-DgRPC_BUILD_GRPC_NODE_PLUGIN=OFF
125-
-DgRPC_BUILD_GRPC_JAVA_PLUGIN=OFF
126133
-DgRPC_BUILD_GRPC_PYTHON_PLUGIN=OFF
127134
-DgRPC_BUILD_GRPC_RUBY_PLUGIN=OFF
128135
-DgRPC_BUILD_GRPCPP_OTEL_PLUGIN=OFF
@@ -133,6 +140,9 @@ if [ ! -z "$build_shared_libs" ]; then
133140
GRPC_BUILD_OPTIONS=(${GRPC_BUILD_OPTIONS[@]} "-DBUILD_SHARED_LIBS=$build_shared_libs")
134141
fi
135142

143+
echo "Building gRPC ${install_grpc_version}"
144+
echo "CMake build options:" "${GRPC_BUILD_OPTIONS[@]}"
145+
136146
cmake "${GRPC_BUILD_OPTIONS[@]}" ..
137147
cmake --build . -j$(nproc)
138148
cmake --install .

0 commit comments

Comments
 (0)