# Find the linking flags of a target

**URL:** https://discourse.cmake.org/t/find-the-linking-flags-of-a-target/10553
**Category:** Usage
**Created:** [April 2, 2024, 7:32am UTC](https://discourse.cmake.org/t/find-the-linking-flags-of-a-target/10553 "2024-04-02T07:32:49Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![k355l3r-5yndr0m3](https://discourse.cmake.org/user_avatar/discourse.cmake.org/k355l3r-5yndr0m3/32/4461_2.png) [@k355l3r-5yndr0m3](https://discourse.cmake.org/u/k355l3r-5yndr0m3)
#### Post date: [April 2, 2024, 7:32am UTC](https://discourse.cmake.org/t/find-the-linking-flags-of-a-target/10553/1 "2024-04-02T07:32:49Z")

</div>

Is there a way to extract the linking flags required to link to a cmake target? I’m working with a different build system and need to link to a library which use cmake.

---

<div class="post-metadata">

### Author: ![ben.boeckel](https://discourse.cmake.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.cmake.org/u/ben.boeckel)
#### Post date: [April 11, 2024, 4:23pm UTC](https://discourse.cmake.org/t/find-the-linking-flags-of-a-target/10553/2 "2024-04-11T16:23:52Z")

</div>

[This script](https://gitlab.kitware.com/paraview/paraview/-/blob/master/Clients/CommandLineExecutables/paraview-config.in) might provide some inspiration. But it’s not something one can statically determine without actually running CMake.
