abseil / abseil/abseil-cpp

use vcpkg install absl dll lib link error

Aperta
#1,705 2 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
C++
Stelle
18.1k
Fork
3.2k
Merge medio
20h 36m
PR unite (30g)
1

Descrizione

### Describe the issue

txsim-coordinator.lib(sensor_catalog_parser.obj) : error LNK2001: 无法解析的外部符号 "private: static void const * const absl::lts_20240116::hash_internal::MixingHashState::kSeed" (?kSeed@MixingHashState@hash_internal@lts_20240116@absl@@0QEBXEB)
3>txsim-coordinator.lib(traffic_parser.obj) : error LNK2001: 无法解析的外部符号 "private: static void const * const absl::lts_20240116::hash_internal::MixingHashState::kSeed" (?kSeed@MixingHashState@hash_internal@lts_20240116@absl@@0QEBXEB)
3>txsim-coordinator.lib(coordinator.obj) : error LNK2001: 无法解析的外部符号 "private: static void const * const absl::lts_20240116::hash_internal::MixingHashState::kSeed" (?kSeed@MixingHashState@hash_internal@lts_20240116@absl@@0QEBXEB)
3>txsim-coordinator.lib(settings.pb.obj) : error LNK2001: 无法解析的外部符号 "private: static void const * const absl::lts_20240116::hash_internal::MixingHashState::kSeed" (?kSeed@MixingHashState@hash_internal@lts_20240116@absl@@0QEBXEB)
3>txsim-coordinator.lib(scene_sensor_group.pb.obj) : error LNK2001: 无法解析的外部符号 "private: static void const * const absl::lts_20240116::hash_internal::MixingHashState::kSeed" (?kSeed@MixingHashState@hash_internal@lts_20240116@absl@@0QEBXEB)
3>txsim-coordinator.lib(scene_infrastructure_group.pb.obj) : error LNK2001: 无法解析的外部符号 "private: static void const * const absl::lts_20240116::hash_internal::MixingHashState::kSeed" (?kSeed@MixingHashState@hash_internal@lts_20240116@absl@@0QEBXEB)

### Steps to reproduce the problem

cmake already
find_package(absl CONFIG REQUIRED)
link with lib:absl::any absl::log absl::base absl::bits absl::hash absl::strings

### What version of Abseil are you using?

{
"name": "abseil",
"version": "20240116.2",
"port-version": 2,
"description": [
"Abseil is an open-source collection of C++ library code designed to augment the C++ standard library. The Abseil library code is collected from Google's own C++ code base, has been extensively tested and used in production, and is the same code we depend on in our daily coding lives.",
"In some cases, Abseil provides pieces missing from the C++ standard; in others, Abseil provides alternatives to the standard for special needs we've found through usage in the Google code base. We denote those cases clearly within the library code we provide you.",
"Abseil is not meant to be a competitor to the standard library; we've just found that many of these utilities serve a purpose within our code base, and we now want to provide those resources to the C++ community as a whole."
],
"homepage": "https://github.com/abseil/abseil-cpp",
"license": "Apache-2.0",
"dependencies": [
{
"name": "vcpkg-cmake",
"host": true
},
{
"name": "vcpkg-cmake-config",
"host": true
}
],
"features": {
"cxx17": {
"description": "Enable compiler C++17."
}
}
}

### What operating system and version are you using?

win11

### What compiler and version are you using?

vs2022 build x64

### What build system are you using?

windows

### Additional context

vcpkg install absl and link protobuf code error.compile success but link error."
I already define ABSL_CONSUME_DLL
I can find kSeed in abseil_dll.lib
![image](https://github.com/abseil/abseil-cpp/assets/12134859/8b1e0364-8189-40fb-b6d3-da2e95553b9c)
I guess maybe link with abseil_hash.lib but i can't find out in vcpkg install result.

Guida per i contributori

Apri la guida per i contributori

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.