# command for install dependency lib

**URL:** https://discourse.cmake.org/t/command-for-install-dependency-lib/3780
**Category:** Code
**Tags:** os:linux
**Created:** [July 19, 2021, 11:19am UTC](https://discourse.cmake.org/t/command-for-install-dependency-lib/3780 "2021-07-19T11:19:00Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![alice](https://discourse.cmake.org/user_avatar/discourse.cmake.org/alice/32/1615_2.png) [@alice](https://discourse.cmake.org/u/alice)
#### Post date: [July 19, 2021, 11:19am UTC](https://discourse.cmake.org/t/command-for-install-dependency-lib/3780/1 "2021-07-19T11:19:00Z")

</div>

If my project have the dependency lib and my system doesnt install it, how to process it with cmake when double click .deb file?

---

<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: [July 19, 2021, 12:32pm UTC](https://discourse.cmake.org/t/command-for-install-dependency-lib/3780/2 "2021-07-19T12:32:18Z")

</div>

It sounds like you are using CPack’s DEB generator? If so, you want [`CPACK_DEBIAN_PACKAGE_DEPENDS`](https://cmake.org/cmake/help/latest/cpack_gen/deb.html#variable:CPACK_DEBIAN_PACKAGE_DEPENDS). If you’re aiming to ship such dependencies yourself, you want [`file(GET_RUNTIME_DEPENDENCIES)`](https://cmake.org/cmake/help/latest/command/file.html#get-runtime-dependencies) and/or CMake 3.21’s [`install(RUNTIME_DEPENDENCY_SET)`](https://cmake.org/cmake/help/latest/command/install.html#runtime-dependency-set).

Cc: @kyle.edwards

---

<div class="post-metadata">

### Author: ![alice](https://discourse.cmake.org/user_avatar/discourse.cmake.org/alice/32/1615_2.png) [@alice](https://discourse.cmake.org/u/alice)
#### Post date: [July 19, 2021, 3:20pm UTC](https://discourse.cmake.org/t/command-for-install-dependency-lib/3780/3 "2021-07-19T15:20:37Z")

</div>

In fact , I know my project ( \*.deb) need xxx.lib and I just do “apt install xxx”. It can success install \*.deb with double click.  
But some linux system maybe not the xxx.lib, some linux system have the xxx.lib.  
How to check the system have the xxx.lib that I need. If not find it ,just install it.

Here is the sample probelm.

> <https://askubuntu.com/questions/58202/how-to-automatically-fetch-missing-dependencies-when-installing-software-from-d>
