Skip to content

Commit c071c6e

Browse files
authored
impl(v3): remove backward compatibility cmake proto libs (#15931)
1 parent 56d7714 commit c071c6e

4 files changed

Lines changed: 28 additions & 24 deletions

File tree

ci/cloudbuild/builds/lib/quickstart.sh

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,15 @@ source module ci/cloudbuild/builds/lib/cmake.sh
3131
source module ci/etc/quickstart-config.sh
3232
source module ci/lib/io.sh
3333

34+
quickstart_program=""
35+
3436
function cleanup() {
3537
local exit_status=$?
3638
io::log_h2 "cleanup on EXIT with exit_status=${exit_status}"
37-
io::run find . -name '*core*'
39+
if ((exit_status != 0)); then
40+
io::run find . -name 'core'
41+
gdb --exec="${quickstart_program}" --core=./core --eval-command="bt full"
42+
fi
3843
}
3944

4045
trap 'cleanup' INT TERM EXIT
@@ -136,6 +141,7 @@ function quickstart::run_one_quickstart() {
136141

137142
io::log "[ CMake ]"
138143
local cmake_bin_dir="${PROJECT_ROOT}/cmake-out/quickstart/cmake-${bin_dir_suffix}"
144+
quickstart_program="${cmake_bin_dir}/quickstart"
139145
if command -v /usr/bin/valgrind >/dev/null 2>&1; then
140146
io::run valgrind --leak-check=full "${cmake_bin_dir}/quickstart" "${run_args[@]}"
141147
else

ci/verify_current_targets/CMakeLists.txt

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -79,23 +79,13 @@ endforeach ()
7979

8080
# Verify backwards compatible proto libraries are installed. See #8022 for more
8181
# details.
82-
foreach (library "dialogflow_es" "iam" "monitoring" "speech" "texttospeech"
83-
"trace")
82+
foreach (library "iam")
8483
find_package(google_cloud_cpp_${library})
8584
endforeach ()
8685

8786
set(backwards_compat_proto_libraries
8887
# cmake-format: sortable
89-
"cloud_dialogflow_v2_protos"
90-
"cloud_speech_protos"
91-
"cloud_texttospeech_protos"
92-
"devtools_cloudtrace_v2_trace_protos"
93-
"devtools_cloudtrace_v2_tracing_protos"
94-
"iam_v1_iam_policy_protos"
95-
"iam_v1_options_protos"
96-
"iam_v1_policy_protos"
97-
"logging_type_protos"
98-
"logging_type_type_protos")
88+
"iam_v1_iam_policy_protos" "iam_v1_options_protos" "iam_v1_policy_protos")
9989

10090
foreach (library ${backwards_compat_proto_libraries})
10191
add_test_case(test_cmake_${library} google-cloud-cpp::common

cmake/GoogleCloudCppLibrary.cmake

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -222,17 +222,6 @@ function (google_cloud_cpp_add_gapic_library library display_name)
222222
list(TRANSFORM shared_proto_dep_targets PREPEND "google_cloud_cpp_")
223223
list(TRANSFORM shared_proto_dep_targets APPEND "_protos")
224224

225-
# We used to offer the proto library by another name. Maintain backwards
226-
# compatibility by providing an interface library with that name. Also make
227-
# sure we install it as part of google_cloud_cpp_${library}-targets.
228-
unset(backwards_compat_proto_targets)
229-
foreach (old_protos IN LISTS _opt_BACKWARDS_COMPAT_PROTO_TARGETS)
230-
google_cloud_cpp_backwards_compat_protos_library("${old_protos}"
231-
"${library}_protos")
232-
list(APPEND backwards_compat_proto_targets
233-
"google_cloud_cpp_${old_protos}")
234-
endforeach ()
235-
236225
file(
237226
GLOB source_files
238227
RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}"

doc/v3-migration-guide.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,25 @@ module which can be added to your `MODULE.bazel` file as a dependency.
4242

4343
### CMake
4444

45+
<details>
46+
<summary>Removed backward compatible proto interface libraries.</summary>
47+
48+
If your application links directly to one of these decommissioned proto
49+
libraries, the CMakeLists.txt should be updated with the preferred proto library
50+
name.
51+
52+
| Library | Decommissioned Proto Library | Preferred Proto Library |
53+
| -------------------------- | ------------------------------------- | -------------------------------------- |
54+
| google/cloud/dialogflow_es | cloud_dialogflow_v2_protos | google-cloud-cpp::dialogflow_es_protos |
55+
| google/cloud/logging | logging_type_protos | google-cloud-cpp::logging_protos |
56+
| google/cloud/logging | logging_type_type_protos | google-cloud-cpp::logging_protos |
57+
| google/cloud/speech | cloud_speech_protos | google-cloud-cpp::speech_protos |
58+
| google/cloud/texttospeech | cloud_texttospeech_protos | google-cloud-cpp::texttospeech_protos |
59+
| google/cloud/trace | devtools_cloudtrace_v2_tracing_protos | google-cloud-cpp::trace_protos |
60+
| google/cloud/trace | devtools_cloudtrace_v2_trace_protos | google-cloud-cpp::trace_protos |
61+
62+
</details>
63+
4564
### Common
4665

4766
<details>

0 commit comments

Comments
 (0)