Skip to content

Blind Fix CMake config file#286

Merged
schuhschuh merged 1 commit intogflags:masterfrom
Mizux:patch-1
Sep 29, 2019
Merged

Blind Fix CMake config file#286
schuhschuh merged 1 commit intogflags:masterfrom
Mizux:patch-1

Conversation

@Mizux
Copy link
Copy Markdown
Contributor

@Mizux Mizux commented Apr 9, 2019

Fix, when integrating prebuilt gflags as

set(GFLAGS_USE_TARGET_NAMESPACE TRUE)
find_package(gflags COMPONENTS static)
...
add_library(awesome "")
target_link_libraries(awesome gflags::gflags_static)

Fix, when integrating prebuilt gflags as
```cmake
set(GFLAGS_USE_TARGET_NAMESPACE TRUE)
find_package(gflags COMPONENTS static)
```
@Mizux
Copy link
Copy Markdown
Contributor Author

Mizux commented Apr 9, 2019

currently I got:

cd my_super_project_using_gflags_build
cmake -S. -Bbuild
...
CMake Error at build/dependencies/install/lib/cmake/gflags/gflags-config.cmake:40 (message):
  Package gflags was installed without required component static!
Call Stack (most recent call first):
  cmake/cpp.cmake:16 (find_package)
  CMakeLists.txt:88 (include)

note: on my way to test the patch

@schuhschuh
Copy link
Copy Markdown
Member

Looks good. Thanks for catching this and submitting a patch!

@schuhschuh schuhschuh merged commit 0b7f8db into gflags:master Sep 29, 2019
@schuhschuh schuhschuh added this to the v2.2.3 milestone Nov 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants