Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build Warning on Windows with Clang due to -Wundef Flag #4372

Closed
KlassenH opened this issue Sep 19, 2023 · 0 comments
Closed

Build Warning on Windows with Clang due to -Wundef Flag #4372

KlassenH opened this issue Sep 19, 2023 · 0 comments
Assignees

Comments

@KlassenH
Copy link

Describe the issue

Using the Clang compiler on Windows via Visual Studio to build the form produces these warnings:

...\build\x64-debug\_deps\googletest-src\googletest\include\gtest\internal\gtest-port.h(830,5): warning GC893BB5A: 'GTEST_LINKED_AS_SHARED_LIBRARY' is not defined, evaluates to 0 [-Wundef]
  #if GTEST_LINKED_AS_SHARED_LIBRARY
      ^
...\build\x64-debug\_deps\googletest-src\googletest\include\gtest\internal\gtest-port.h(832,7): warning G3FA67CA8: 'GTEST_CREATE_SHARED_LIBRARY' is not defined, evaluates to 0 [-Wundef]
  
  #elif GTEST_CREATE_SHARED_LIBRARY
  
        ^

Steps to reproduce the problem

CMakeLists.txt

What version of GoogleTest are you using?

f8d7d77

What operating system and version are you using?

Windows 11

What compiler and version are you using?

clang version 16.0.5
Target: x86_64-pc-windows-msvc
Thread model: posix
InstalledDir: C:\Program Files\Microsoft Visual Studio\2022\Preview\VC\Tools\Llvm\x64\bin

What build system are you using?

cmake version 3.26.4-msvc4

Additional context

No response

sergio-nsk pushed a commit to snxd/googletest that referenced this issue Oct 13, 2023
…EST_LINKED_AS_SHARED_LIBRARY` with shared libraries in GoogleTest

Fixes: google#4372
PiperOrigin-RevId: 568327612
Change-Id: Ifc47f1a2a2648c29858a22966331557cc928cc47
kunitoki pushed a commit to kunitoki/googletest that referenced this issue Nov 4, 2023
…EST_LINKED_AS_SHARED_LIBRARY` with shared libraries in GoogleTest

Fixes: google#4372
PiperOrigin-RevId: 568327612
Change-Id: Ifc47f1a2a2648c29858a22966331557cc928cc47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants