1include(CMakeParseArguments) 2include(GNUInstallDirs) 3 4set(ABSL_INTERNAL_DLL_FILES 5 "algorithm/algorithm.h" 6 "algorithm/container.h" 7 "base/attributes.h" 8 "base/call_once.h" 9 "base/casts.h" 10 "base/config.h" 11 "base/const_init.h" 12 "base/dynamic_annotations.h" 13 "base/internal/atomic_hook.h" 14 "base/internal/cycleclock.cc" 15 "base/internal/cycleclock.h" 16 "base/internal/cycleclock_config.h" 17 "base/internal/direct_mmap.h" 18 "base/internal/endian.h" 19 "base/internal/errno_saver.h" 20 "base/internal/fast_type_id.h" 21 "base/internal/hide_ptr.h" 22 "base/internal/identity.h" 23 "base/internal/invoke.h" 24 "base/internal/inline_variable.h" 25 "base/internal/low_level_alloc.cc" 26 "base/internal/low_level_alloc.h" 27 "base/internal/low_level_scheduling.h" 28 "base/internal/nullability_impl.h" 29 "base/internal/per_thread_tls.h" 30 "base/prefetch.h" 31 "base/internal/pretty_function.h" 32 "base/internal/raw_logging.cc" 33 "base/internal/raw_logging.h" 34 "base/internal/scheduling_mode.h" 35 "base/internal/scoped_set_env.cc" 36 "base/internal/scoped_set_env.h" 37 "base/internal/strerror.h" 38 "base/internal/strerror.cc" 39 "base/internal/spinlock.cc" 40 "base/internal/spinlock.h" 41 "base/internal/spinlock_wait.cc" 42 "base/internal/spinlock_wait.h" 43 "base/internal/sysinfo.cc" 44 "base/internal/sysinfo.h" 45 "base/internal/thread_identity.cc" 46 "base/internal/thread_identity.h" 47 "base/internal/throw_delegate.cc" 48 "base/internal/throw_delegate.h" 49 "base/internal/tsan_mutex_interface.h" 50 "base/internal/unaligned_access.h" 51 "base/internal/unscaledcycleclock.cc" 52 "base/internal/unscaledcycleclock.h" 53 "base/internal/unscaledcycleclock_config.h" 54 "base/log_severity.cc" 55 "base/log_severity.h" 56 "base/macros.h" 57 "base/no_destructor.h" 58 "base/nullability.h" 59 "base/optimization.h" 60 "base/options.h" 61 "base/policy_checks.h" 62 "base/port.h" 63 "base/thread_annotations.h" 64 "cleanup/cleanup.h" 65 "cleanup/internal/cleanup.h" 66 "container/btree_map.h" 67 "container/btree_set.h" 68 "container/hash_container_defaults.h" 69 "container/fixed_array.h" 70 "container/flat_hash_map.h" 71 "container/flat_hash_set.h" 72 "container/inlined_vector.h" 73 "container/internal/btree.h" 74 "container/internal/btree_container.h" 75 "container/internal/common.h" 76 "container/internal/common_policy_traits.h" 77 "container/internal/compressed_tuple.h" 78 "container/internal/container_memory.h" 79 "container/internal/hash_function_defaults.h" 80 "container/internal/hash_policy_traits.h" 81 "container/internal/hashtable_debug.h" 82 "container/internal/hashtable_debug_hooks.h" 83 "container/internal/hashtablez_sampler.cc" 84 "container/internal/hashtablez_sampler.h" 85 "container/internal/hashtablez_sampler_force_weak_definition.cc" 86 "container/internal/inlined_vector.h" 87 "container/internal/layout.h" 88 "container/internal/node_slot_policy.h" 89 "container/internal/raw_hash_map.h" 90 "container/internal/raw_hash_set.cc" 91 "container/internal/raw_hash_set.h" 92 "container/internal/tracked.h" 93 "container/node_hash_map.h" 94 "container/node_hash_set.h" 95 "crc/crc32c.cc" 96 "crc/crc32c.h" 97 "crc/internal/cpu_detect.cc" 98 "crc/internal/cpu_detect.h" 99 "crc/internal/crc32c.h" 100 "crc/internal/crc32c_inline.h" 101 "crc/internal/crc32_x86_arm_combined_simd.h" 102 "crc/internal/crc.cc" 103 "crc/internal/crc.h" 104 "crc/internal/crc_cord_state.cc" 105 "crc/internal/crc_cord_state.h" 106 "crc/internal/crc_internal.h" 107 "crc/internal/crc_x86_arm_combined.cc" 108 "crc/internal/crc_memcpy_fallback.cc" 109 "crc/internal/crc_memcpy.h" 110 "crc/internal/crc_memcpy_x86_arm_combined.cc" 111 "crc/internal/crc_non_temporal_memcpy.cc" 112 "crc/internal/crc_x86_arm_combined.cc" 113 "crc/internal/non_temporal_arm_intrinsics.h" 114 "crc/internal/non_temporal_memcpy.h" 115 "debugging/failure_signal_handler.cc" 116 "debugging/failure_signal_handler.h" 117 "debugging/leak_check.h" 118 "debugging/stacktrace.cc" 119 "debugging/stacktrace.h" 120 "debugging/symbolize.cc" 121 "debugging/symbolize.h" 122 "debugging/internal/address_is_readable.cc" 123 "debugging/internal/address_is_readable.h" 124 "debugging/internal/demangle.cc" 125 "debugging/internal/demangle.h" 126 "debugging/internal/demangle_rust.cc" 127 "debugging/internal/demangle_rust.h" 128 "debugging/internal/elf_mem_image.cc" 129 "debugging/internal/elf_mem_image.h" 130 "debugging/internal/examine_stack.cc" 131 "debugging/internal/examine_stack.h" 132 "debugging/internal/stack_consumption.cc" 133 "debugging/internal/stack_consumption.h" 134 "debugging/internal/stacktrace_config.h" 135 "debugging/internal/symbolize.h" 136 "debugging/internal/vdso_support.cc" 137 "debugging/internal/vdso_support.h" 138 "functional/any_invocable.h" 139 "functional/internal/front_binder.h" 140 "functional/bind_front.h" 141 "functional/function_ref.h" 142 "functional/internal/any_invocable.h" 143 "functional/internal/function_ref.h" 144 "functional/overload.h" 145 "hash/hash.h" 146 "hash/internal/city.h" 147 "hash/internal/city.cc" 148 "hash/internal/hash.h" 149 "hash/internal/hash.cc" 150 "hash/internal/spy_hash_state.h" 151 "hash/internal/low_level_hash.h" 152 "hash/internal/low_level_hash.cc" 153 "log/absl_check.h" 154 "log/absl_log.h" 155 "log/absl_vlog_is_on.h" 156 "log/check.h" 157 "log/die_if_null.cc" 158 "log/die_if_null.h" 159 "log/globals.cc" 160 "log/globals.h" 161 "log/internal/append_truncated.h" 162 "log/internal/check_impl.h" 163 "log/internal/check_op.cc" 164 "log/internal/check_op.h" 165 "log/internal/conditions.cc" 166 "log/internal/conditions.h" 167 "log/internal/config.h" 168 "log/internal/fnmatch.h" 169 "log/internal/fnmatch.cc" 170 "log/internal/globals.cc" 171 "log/internal/globals.h" 172 "log/internal/log_format.cc" 173 "log/internal/log_format.h" 174 "log/internal/log_impl.h" 175 "log/internal/log_message.cc" 176 "log/internal/log_message.h" 177 "log/internal/log_sink_set.cc" 178 "log/internal/log_sink_set.h" 179 "log/internal/nullguard.cc" 180 "log/internal/nullguard.h" 181 "log/internal/nullstream.h" 182 "log/internal/proto.h" 183 "log/internal/proto.cc" 184 "log/internal/strip.h" 185 "log/internal/structured.h" 186 "log/internal/vlog_config.cc" 187 "log/internal/vlog_config.h" 188 "log/internal/voidify.h" 189 "log/initialize.cc" 190 "log/initialize.h" 191 "log/log.h" 192 "log/log_entry.cc" 193 "log/log_entry.h" 194 "log/log_sink.cc" 195 "log/log_sink.h" 196 "log/log_sink_registry.h" 197 "log/log_streamer.h" 198 "log/structured.h" 199 "log/vlog_is_on.h" 200 "memory/memory.h" 201 "meta/type_traits.h" 202 "numeric/bits.h" 203 "numeric/int128.cc" 204 "numeric/int128.h" 205 "numeric/internal/bits.h" 206 "numeric/internal/representation.h" 207 "profiling/internal/exponential_biased.cc" 208 "profiling/internal/exponential_biased.h" 209 "profiling/internal/periodic_sampler.cc" 210 "profiling/internal/periodic_sampler.h" 211 "profiling/internal/sample_recorder.h" 212 "random/bernoulli_distribution.h" 213 "random/beta_distribution.h" 214 "random/bit_gen_ref.h" 215 "random/discrete_distribution.cc" 216 "random/discrete_distribution.h" 217 "random/distributions.h" 218 "random/exponential_distribution.h" 219 "random/gaussian_distribution.cc" 220 "random/gaussian_distribution.h" 221 "random/internal/distribution_caller.h" 222 "random/internal/fastmath.h" 223 "random/internal/fast_uniform_bits.h" 224 "random/internal/generate_real.h" 225 "random/internal/iostream_state_saver.h" 226 "random/internal/nonsecure_base.h" 227 "random/internal/pcg_engine.h" 228 "random/internal/platform.h" 229 "random/internal/pool_urbg.cc" 230 "random/internal/pool_urbg.h" 231 "random/internal/randen.cc" 232 "random/internal/randen.h" 233 "random/internal/randen_detect.cc" 234 "random/internal/randen_detect.h" 235 "random/internal/randen_engine.h" 236 "random/internal/randen_hwaes.cc" 237 "random/internal/randen_hwaes.h" 238 "random/internal/randen_round_keys.cc" 239 "random/internal/randen_slow.cc" 240 "random/internal/randen_slow.h" 241 "random/internal/randen_traits.h" 242 "random/internal/salted_seed_seq.h" 243 "random/internal/seed_material.cc" 244 "random/internal/seed_material.h" 245 "random/internal/sequence_urbg.h" 246 "random/internal/traits.h" 247 "random/internal/uniform_helper.h" 248 "random/internal/wide_multiply.h" 249 "random/log_uniform_int_distribution.h" 250 "random/poisson_distribution.h" 251 "random/random.h" 252 "random/seed_gen_exception.cc" 253 "random/seed_gen_exception.h" 254 "random/seed_sequences.cc" 255 "random/seed_sequences.h" 256 "random/uniform_int_distribution.h" 257 "random/uniform_real_distribution.h" 258 "random/zipf_distribution.h" 259 "status/internal/status_internal.h" 260 "status/internal/status_internal.cc" 261 "status/internal/statusor_internal.h" 262 "status/status.h" 263 "status/status.cc" 264 "status/statusor.h" 265 "status/statusor.cc" 266 "status/status_payload_printer.h" 267 "status/status_payload_printer.cc" 268 "strings/ascii.cc" 269 "strings/ascii.h" 270 "strings/charconv.cc" 271 "strings/charconv.h" 272 "strings/charset.h" 273 "strings/cord.cc" 274 "strings/cord.h" 275 "strings/cord_analysis.cc" 276 "strings/cord_analysis.h" 277 "strings/cord_buffer.cc" 278 "strings/cord_buffer.h" 279 "strings/escaping.cc" 280 "strings/escaping.h" 281 "strings/internal/charconv_bigint.cc" 282 "strings/internal/charconv_bigint.h" 283 "strings/internal/charconv_parse.cc" 284 "strings/internal/charconv_parse.h" 285 "strings/internal/cord_data_edge.h" 286 "strings/internal/cord_internal.cc" 287 "strings/internal/cord_internal.h" 288 "strings/internal/cord_rep_btree.cc" 289 "strings/internal/cord_rep_btree.h" 290 "strings/internal/cord_rep_btree_navigator.cc" 291 "strings/internal/cord_rep_btree_navigator.h" 292 "strings/internal/cord_rep_btree_reader.cc" 293 "strings/internal/cord_rep_btree_reader.h" 294 "strings/internal/cord_rep_crc.cc" 295 "strings/internal/cord_rep_crc.h" 296 "strings/internal/cord_rep_consume.h" 297 "strings/internal/cord_rep_consume.cc" 298 "strings/internal/cord_rep_flat.h" 299 "strings/internal/cordz_functions.cc" 300 "strings/internal/cordz_functions.h" 301 "strings/internal/cordz_handle.cc" 302 "strings/internal/cordz_handle.h" 303 "strings/internal/cordz_info.cc" 304 "strings/internal/cordz_info.h" 305 "strings/internal/cordz_sample_token.cc" 306 "strings/internal/cordz_sample_token.h" 307 "strings/internal/cordz_statistics.h" 308 "strings/internal/cordz_update_scope.h" 309 "strings/internal/cordz_update_tracker.h" 310 "strings/internal/damerau_levenshtein_distance.h" 311 "strings/internal/damerau_levenshtein_distance.cc" 312 "strings/internal/stl_type_traits.h" 313 "strings/internal/string_constant.h" 314 "strings/internal/stringify_sink.h" 315 "strings/internal/stringify_sink.cc" 316 "strings/internal/has_absl_stringify.h" 317 "strings/has_absl_stringify.h" 318 "strings/has_ostream_operator.h" 319 "strings/match.cc" 320 "strings/match.h" 321 "strings/numbers.cc" 322 "strings/numbers.h" 323 "strings/str_format.h" 324 "strings/str_cat.cc" 325 "strings/str_cat.h" 326 "strings/str_join.h" 327 "strings/str_replace.cc" 328 "strings/str_replace.h" 329 "strings/str_split.cc" 330 "strings/str_split.h" 331 "strings/string_view.cc" 332 "strings/string_view.h" 333 "strings/strip.h" 334 "strings/substitute.cc" 335 "strings/substitute.h" 336 "strings/internal/escaping.h" 337 "strings/internal/escaping.cc" 338 "strings/internal/memutil.cc" 339 "strings/internal/memutil.h" 340 "strings/internal/ostringstream.cc" 341 "strings/internal/ostringstream.h" 342 "strings/internal/pow10_helper.cc" 343 "strings/internal/pow10_helper.h" 344 "strings/internal/resize_uninitialized.h" 345 "strings/internal/str_format/arg.cc" 346 "strings/internal/str_format/arg.h" 347 "strings/internal/str_format/bind.cc" 348 "strings/internal/str_format/bind.h" 349 "strings/internal/str_format/checker.h" 350 "strings/internal/str_format/constexpr_parser.h" 351 "strings/internal/str_format/extension.cc" 352 "strings/internal/str_format/extension.h" 353 "strings/internal/str_format/float_conversion.cc" 354 "strings/internal/str_format/float_conversion.h" 355 "strings/internal/str_format/output.cc" 356 "strings/internal/str_format/output.h" 357 "strings/internal/str_format/parser.cc" 358 "strings/internal/str_format/parser.h" 359 "strings/internal/str_join_internal.h" 360 "strings/internal/str_split_internal.h" 361 "strings/internal/utf8.cc" 362 "strings/internal/utf8.h" 363 "synchronization/barrier.cc" 364 "synchronization/barrier.h" 365 "synchronization/blocking_counter.cc" 366 "synchronization/blocking_counter.h" 367 "synchronization/mutex.cc" 368 "synchronization/mutex.h" 369 "synchronization/notification.cc" 370 "synchronization/notification.h" 371 "synchronization/internal/create_thread_identity.cc" 372 "synchronization/internal/create_thread_identity.h" 373 "synchronization/internal/futex.h" 374 "synchronization/internal/futex_waiter.h" 375 "synchronization/internal/futex_waiter.cc" 376 "synchronization/internal/graphcycles.cc" 377 "synchronization/internal/graphcycles.h" 378 "synchronization/internal/kernel_timeout.h" 379 "synchronization/internal/kernel_timeout.cc" 380 "synchronization/internal/per_thread_sem.cc" 381 "synchronization/internal/per_thread_sem.h" 382 "synchronization/internal/pthread_waiter.h" 383 "synchronization/internal/pthread_waiter.cc" 384 "synchronization/internal/sem_waiter.h" 385 "synchronization/internal/sem_waiter.cc" 386 "synchronization/internal/stdcpp_waiter.h" 387 "synchronization/internal/stdcpp_waiter.cc" 388 "synchronization/internal/thread_pool.h" 389 "synchronization/internal/waiter.h" 390 "synchronization/internal/waiter_base.h" 391 "synchronization/internal/waiter_base.cc" 392 "synchronization/internal/win32_waiter.h" 393 "synchronization/internal/win32_waiter.cc" 394 "time/civil_time.cc" 395 "time/civil_time.h" 396 "time/clock.cc" 397 "time/clock.h" 398 "time/duration.cc" 399 "time/format.cc" 400 "time/time.cc" 401 "time/time.h" 402 "time/internal/cctz/include/cctz/civil_time.h" 403 "time/internal/cctz/include/cctz/civil_time_detail.h" 404 "time/internal/cctz/include/cctz/time_zone.h" 405 "time/internal/cctz/include/cctz/zone_info_source.h" 406 "time/internal/cctz/src/civil_time_detail.cc" 407 "time/internal/cctz/src/time_zone_fixed.cc" 408 "time/internal/cctz/src/time_zone_fixed.h" 409 "time/internal/cctz/src/time_zone_format.cc" 410 "time/internal/cctz/src/time_zone_if.cc" 411 "time/internal/cctz/src/time_zone_if.h" 412 "time/internal/cctz/src/time_zone_impl.cc" 413 "time/internal/cctz/src/time_zone_impl.h" 414 "time/internal/cctz/src/time_zone_info.cc" 415 "time/internal/cctz/src/time_zone_info.h" 416 "time/internal/cctz/src/time_zone_libc.cc" 417 "time/internal/cctz/src/time_zone_libc.h" 418 "time/internal/cctz/src/time_zone_lookup.cc" 419 "time/internal/cctz/src/time_zone_posix.cc" 420 "time/internal/cctz/src/time_zone_posix.h" 421 "time/internal/cctz/src/tzfile.h" 422 "time/internal/cctz/src/zone_info_source.cc" 423 "types/any.h" 424 "types/bad_any_cast.cc" 425 "types/bad_any_cast.h" 426 "types/bad_optional_access.cc" 427 "types/bad_optional_access.h" 428 "types/bad_variant_access.cc" 429 "types/bad_variant_access.h" 430 "types/compare.h" 431 "types/internal/variant.h" 432 "types/optional.h" 433 "types/internal/optional.h" 434 "types/span.h" 435 "types/internal/span.h" 436 "types/variant.h" 437 "utility/internal/if_constexpr.h" 438 "utility/utility.h" 439 "debugging/leak_check.cc" 440) 441 442if(NOT MSVC) 443 list(APPEND ABSL_INTERNAL_DLL_FILES 444 "flags/commandlineflag.cc" 445 "flags/commandlineflag.h" 446 "flags/config.h" 447 "flags/declare.h" 448 "flags/flag.h" 449 "flags/internal/commandlineflag.cc" 450 "flags/internal/commandlineflag.h" 451 "flags/internal/flag.cc" 452 "flags/internal/flag.h" 453 "flags/internal/parse.h" 454 "flags/internal/path_util.h" 455 "flags/internal/private_handle_accessor.cc" 456 "flags/internal/private_handle_accessor.h" 457 "flags/internal/program_name.cc" 458 "flags/internal/program_name.h" 459 "flags/internal/registry.h" 460 "flags/internal/sequence_lock.h" 461 "flags/internal/usage.cc" 462 "flags/internal/usage.h" 463 "flags/marshalling.cc" 464 "flags/marshalling.h" 465 "flags/parse.cc" 466 "flags/parse.h" 467 "flags/reflection.cc" 468 "flags/reflection.h" 469 "flags/usage.cc" 470 "flags/usage.h" 471 "flags/usage_config.cc" 472 "flags/usage_config.h" 473 "log/flags.cc" 474 "log/flags.h" 475 "log/internal/flags.h" 476 ) 477endif() 478 479set(ABSL_INTERNAL_DLL_TARGETS 480 "absl_check" 481 "absl_log" 482 "algorithm" 483 "algorithm_container" 484 "any" 485 "any_invocable" 486 "atomic_hook" 487 "bad_any_cast" 488 "bad_any_cast_impl" 489 "bad_optional_access" 490 "bad_variant_access" 491 "base" 492 "base_internal" 493 "bind_front" 494 "bits" 495 "btree" 496 "check" 497 "city" 498 "civil_time" 499 "compare" 500 "compressed_tuple" 501 "config" 502 "container" 503 "container_common" 504 "container_memory" 505 "cord" 506 "cord_internal" 507 "cordz_functions" 508 "cordz_handle" 509 "cordz_info" 510 "cordz_sample_token" 511 "core_headers" 512 "counting_allocator" 513 "crc_cord_state" 514 "crc_cpu_detect" 515 "crc_internal" 516 "crc32c" 517 "debugging" 518 "debugging_internal" 519 "demangle_internal" 520 "die_if_null" 521 "dynamic_annotations" 522 "endian" 523 "examine_stack" 524 "exponential_biased" 525 "failure_signal_handler" 526 "fixed_array" 527 "flat_hash_map" 528 "flat_hash_set" 529 "function_ref" 530 "graphcycles_internal" 531 "hash" 532 "hash_function_defaults" 533 "hash_policy_traits" 534 "hashtable_debug" 535 "hashtable_debug_hooks" 536 "hashtablez_sampler" 537 "inlined_vector" 538 "inlined_vector_internal" 539 "int128" 540 "kernel_timeout_internal" 541 "layout" 542 "leak_check" 543 "log_internal_check_impl" 544 "log_internal_check_op" 545 "log_internal_conditions" 546 "log_internal_config" 547 "log_internal_fnmatch" 548 "log_internal_format" 549 "log_internal_globals" 550 "log_internal_log_impl" 551 "log_internal_proto" 552 "log_internal_message" 553 "log_internal_log_sink_set" 554 "log_internal_nullguard" 555 "log_internal_nullstream" 556 "log_internal_strip" 557 "log_internal_voidify" 558 "log_internal_append_truncated" 559 "log_globals" 560 "log_initialize" 561 "log" 562 "log_entry" 563 "log_sink" 564 "log_sink_registry" 565 "log_streamer" 566 "log_internal_structured" 567 "log_severity" 568 "log_structured" 569 "low_level_hash" 570 "malloc_internal" 571 "memory" 572 "meta" 573 "node_hash_map" 574 "node_hash_set" 575 "node_slot_policy" 576 "non_temporal_arm_intrinsics" 577 "non_temporal_memcpy" 578 "numeric" 579 "optional" 580 "periodic_sampler" 581 "pow10_helper" 582 "pretty_function" 583 "random_bit_gen_ref" 584 "random_distributions" 585 "random_internal_distribution_caller" 586 "random_internal_distributions" 587 "random_internal_explicit_seed_seq" 588 "random_internal_fastmath" 589 "random_internal_fast_uniform_bits" 590 "random_internal_generate_real" 591 "random_internal_iostream_state_saver" 592 "random_internal_nonsecure_base" 593 "random_internal_pcg_engine" 594 "random_internal_platform" 595 "random_internal_pool_urbg" 596 "random_internal_randen" 597 "random_internal_randen_engine" 598 "random_internal_randen_hwaes" 599 "random_internal_randen_hwaes_impl" 600 "random_internal_randen_slow" 601 "random_internal_salted_seed_seq" 602 "random_internal_seed_material" 603 "random_internal_sequence_urbg" 604 "random_internal_traits" 605 "random_internal_uniform_helper" 606 "random_internal_wide_multiply" 607 "random_random" 608 "random_seed_gen_exception" 609 "random_seed_sequences" 610 "raw_hash_map" 611 "raw_hash_set" 612 "raw_logging_internal" 613 "sample_recorder" 614 "scoped_set_env" 615 "span" 616 "spinlock_wait" 617 "spy_hash_state" 618 "stack_consumption" 619 "stacktrace" 620 "status" 621 "statusor" 622 "str_format" 623 "str_format_internal" 624 "strerror" 625 "strings" 626 "strings_internal" 627 "string_view" 628 "symbolize" 629 "synchronization" 630 "thread_pool" 631 "throw_delegate" 632 "time" 633 "time_zone" 634 "tracked" 635 "type_traits" 636 "utility" 637 "variant" 638 "vlog_config_internal" 639) 640 641if(NOT MSVC) 642 list(APPEND ABSL_INTERNAL_DLL_TARGETS 643 "flags" 644 "flags_commandlineflag" 645 "flags_commandlineflag_internal" 646 "flags_config" 647 "flags_internal" 648 "flags_marshalling" 649 "flags_parse" 650 "flags_path_util" 651 "flags_private_handle_accessor" 652 "flags_program_name" 653 "flags_reflection" 654 "flags_usage" 655 "flags_usage_internal" 656 "log_internal_flags" 657 "log_flags" 658 ) 659endif() 660 661set(ABSL_INTERNAL_TEST_DLL_FILES 662 "hash/hash_testing.h" 663 "log/scoped_mock_log.cc" 664 "log/scoped_mock_log.h" 665 "random/internal/chi_square.cc" 666 "random/internal/chi_square.h" 667 "random/internal/distribution_test_util.cc" 668 "random/internal/distribution_test_util.h" 669 "random/internal/mock_helpers.h" 670 "random/internal/mock_overload_set.h" 671 "random/mocking_bit_gen.h" 672 "random/mock_distributions.h" 673 "status/status_matchers.h" 674 "status/internal/status_matchers.cc" 675 "status/internal/status_matchers.h" 676 "strings/cordz_test_helpers.h" 677 "strings/cord_test_helpers.h" 678) 679 680set(ABSL_INTERNAL_TEST_DLL_TARGETS 681 "cord_test_helpers" 682 "cordz_test_helpers" 683 "hash_testing" 684 "random_mocking_bit_gen" 685 "random_internal_distribution_test_util" 686 "random_internal_mock_overload_set" 687 "scoped_mock_log" 688 "status_matchers" 689) 690 691include(CheckCXXSourceCompiles) 692 693check_cxx_source_compiles( 694 [==[ 695#ifdef _MSC_VER 696# if _MSVC_LANG < 201703L 697# error "The compiler defaults or is configured for C++ < 17" 698# endif 699#elif __cplusplus < 201703L 700# error "The compiler defaults or is configured for C++ < 17" 701#endif 702int main() { return 0; } 703]==] 704 ABSL_INTERNAL_AT_LEAST_CXX17) 705 706check_cxx_source_compiles( 707 [==[ 708#ifdef _MSC_VER 709# if _MSVC_LANG < 202002L 710# error "The compiler defaults or is configured for C++ < 20" 711# endif 712#elif __cplusplus < 202002L 713# error "The compiler defaults or is configured for C++ < 20" 714#endif 715int main() { return 0; } 716]==] 717 ABSL_INTERNAL_AT_LEAST_CXX20) 718 719if(ABSL_INTERNAL_AT_LEAST_CXX20) 720 set(ABSL_INTERNAL_CXX_STD_FEATURE cxx_std_20) 721elseif(ABSL_INTERNAL_AT_LEAST_CXX17) 722 set(ABSL_INTERNAL_CXX_STD_FEATURE cxx_std_17) 723else() 724 set(ABSL_INTERNAL_CXX_STD_FEATURE cxx_std_14) 725endif() 726 727function(absl_internal_dll_contains) 728 cmake_parse_arguments(ABSL_INTERNAL_DLL 729 "" 730 "OUTPUT;TARGET" 731 "" 732 ${ARGN} 733 ) 734 735 STRING(REGEX REPLACE "^absl::" "" _target ${ABSL_INTERNAL_DLL_TARGET}) 736 737 if (_target IN_LIST ABSL_INTERNAL_DLL_TARGETS) 738 set(${ABSL_INTERNAL_DLL_OUTPUT} 1 PARENT_SCOPE) 739 else() 740 set(${ABSL_INTERNAL_DLL_OUTPUT} 0 PARENT_SCOPE) 741 endif() 742endfunction() 743 744function(absl_internal_test_dll_contains) 745 cmake_parse_arguments(ABSL_INTERNAL_TEST_DLL 746 "" 747 "OUTPUT;TARGET" 748 "" 749 ${ARGN} 750 ) 751 752 STRING(REGEX REPLACE "^absl::" "" _target ${ABSL_INTERNAL_TEST_DLL_TARGET}) 753 754 if (_target IN_LIST ABSL_INTERNAL_TEST_DLL_TARGETS) 755 set(${ABSL_INTERNAL_TEST_DLL_OUTPUT} 1 PARENT_SCOPE) 756 else() 757 set(${ABSL_INTERNAL_TEST_DLL_OUTPUT} 0 PARENT_SCOPE) 758 endif() 759endfunction() 760 761function(absl_internal_dll_targets) 762 cmake_parse_arguments(ABSL_INTERNAL_DLL 763 "" 764 "OUTPUT" 765 "DEPS" 766 ${ARGN} 767 ) 768 769 set(_deps "") 770 foreach(dep IN LISTS ABSL_INTERNAL_DLL_DEPS) 771 absl_internal_dll_contains(TARGET ${dep} OUTPUT _dll_contains) 772 absl_internal_test_dll_contains(TARGET ${dep} OUTPUT _test_dll_contains) 773 if (_dll_contains) 774 list(APPEND _deps abseil_dll) 775 elseif (_test_dll_contains) 776 list(APPEND _deps abseil_test_dll) 777 else() 778 list(APPEND _deps ${dep}) 779 endif() 780 endforeach() 781 782 # Because we may have added the DLL multiple times 783 list(REMOVE_DUPLICATES _deps) 784 set(${ABSL_INTERNAL_DLL_OUTPUT} "${_deps}" PARENT_SCOPE) 785endfunction() 786 787function(absl_make_dll) 788 cmake_parse_arguments(ABSL_INTERNAL_MAKE_DLL 789 "" 790 "TEST" 791 "" 792 ${ARGN} 793 ) 794 795 if (ABSL_INTERNAL_MAKE_DLL_TEST) 796 set(_dll "abseil_test_dll") 797 set(_dll_files ${ABSL_INTERNAL_TEST_DLL_FILES}) 798 set(_dll_libs "abseil_dll" "GTest::gtest" "GTest::gmock") 799 set(_dll_compile_definitions "GTEST_LINKED_AS_SHARED_LIBRARY=1") 800 set(_dll_includes ${absl_gtest_src_dir}/googletest/include ${absl_gtest_src_dir}/googlemock/include) 801 set(_dll_consume "ABSL_CONSUME_TEST_DLL") 802 set(_dll_build "ABSL_BUILD_TEST_DLL") 803 else() 804 set(_dll "abseil_dll") 805 set(_dll_files ${ABSL_INTERNAL_DLL_FILES}) 806 set(_dll_libs 807 Threads::Threads 808 # TODO(#1495): Use $<LINK_LIBRARY:FRAMEWORK,CoreFoundation> once our 809 # minimum CMake version >= 3.24 810 $<$<PLATFORM_ID:Darwin>:-Wl,-framework,CoreFoundation> 811 ) 812 set(_dll_compile_definitions "") 813 set(_dll_includes "") 814 set(_dll_consume "ABSL_CONSUME_DLL") 815 set(_dll_build "ABSL_BUILD_DLL") 816 endif() 817 818 add_library( 819 ${_dll} 820 SHARED 821 ${_dll_files} 822 ) 823 target_link_libraries( 824 ${_dll} 825 PRIVATE 826 ${_dll_libs} 827 ${ABSL_DEFAULT_LINKOPTS} 828 ) 829 set_target_properties(${_dll} PROPERTIES 830 LINKER_LANGUAGE "CXX" 831 SOVERSION ${ABSL_SOVERSION} 832 ) 833 target_include_directories( 834 ${_dll} 835 PUBLIC 836 "$<BUILD_INTERFACE:${ABSL_COMMON_INCLUDE_DIRS}>" 837 $<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}> 838 PRIVATE 839 ${_dll_includes} 840 ) 841 842 target_compile_options( 843 ${_dll} 844 PRIVATE 845 ${ABSL_DEFAULT_COPTS} 846 ) 847 848 foreach(cflag ${ABSL_CC_LIB_COPTS}) 849 if(${cflag} MATCHES "^(-Wno|/wd)") 850 # These flags are needed to suppress warnings that might fire in our headers. 851 set(PC_CFLAGS "${PC_CFLAGS} ${cflag}") 852 elseif(${cflag} MATCHES "^(-W|/w[1234eo])") 853 # Don't impose our warnings on others. 854 else() 855 set(PC_CFLAGS "${PC_CFLAGS} ${cflag}") 856 endif() 857 endforeach() 858 string(REPLACE ";" " " PC_LINKOPTS "${ABSL_CC_LIB_LINKOPTS}") 859 860 FILE(GENERATE OUTPUT "${CMAKE_BINARY_DIR}/lib/pkgconfig/${_dll}.pc" CONTENT "\ 861prefix=${CMAKE_INSTALL_PREFIX}\n\ 862exec_prefix=\${prefix}\n\ 863libdir=${CMAKE_INSTALL_FULL_LIBDIR}\n\ 864includedir=${CMAKE_INSTALL_FULL_INCLUDEDIR}\n\ 865\n\ 866Name: ${_dll}\n\ 867Description: Abseil DLL library\n\ 868URL: https://abseil.io/\n\ 869Version: ${absl_VERSION}\n\ 870Libs: -L\${libdir} $<$<NOT:$<BOOL:${ABSL_CC_LIB_IS_INTERFACE}>>:-l${_dll}> ${PC_LINKOPTS}\n\ 871Cflags: -I\${includedir}${PC_CFLAGS}\n") 872 INSTALL(FILES "${CMAKE_BINARY_DIR}/lib/pkgconfig/${_dll}.pc" 873 DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig") 874 875 target_compile_definitions( 876 ${_dll} 877 PUBLIC 878 ${_dll_compile_definitions} 879 PRIVATE 880 ${_dll_build} 881 NOMINMAX 882 INTERFACE 883 ${ABSL_CC_LIB_DEFINES} 884 ${_dll_consume} 885 ) 886 887 if(ABSL_PROPAGATE_CXX_STD) 888 # Abseil libraries require C++14 as the current minimum standard. When 889 # compiled with a higher minimum (either because it is the compiler's 890 # default or explicitly requested), then Abseil requires that standard. 891 target_compile_features(${_dll} PUBLIC ${ABSL_INTERNAL_CXX_STD_FEATURE}) 892 endif() 893 894 install(TARGETS ${_dll} EXPORT ${PROJECT_NAME}Targets 895 RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} 896 LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} 897 ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} 898 ) 899 900 add_library(absl::${_dll} ALIAS ${_dll}) 901endfunction() 902