# How to Properly setup cmake library

**URL:** https://discourse.cmake.org/t/how-to-properly-setup-cmake-library/10127
**Category:** Usage
**Tags:** os:linux, gen:makefiles
**Created:** [February 17, 2024, 9:18pm UTC](https://discourse.cmake.org/t/how-to-properly-setup-cmake-library/10127 "2024-02-17T21:18:43Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![IronFractal](https://discourse.cmake.org/user_avatar/discourse.cmake.org/ironfractal/32/4321_2.png) [@IronFractal](https://discourse.cmake.org/u/IronFractal)
#### Post date: [February 17, 2024, 9:18pm UTC](https://discourse.cmake.org/t/how-to-properly-setup-cmake-library/10127/1 "2024-02-17T21:18:43Z")

</div>

[project on github](https://github.com/IronFractal/ifl_log)  
I am new to cmake and I am having trouble trying to figure out how to setup a library project. The issue is that I am not able to include the libraries header files in projects that use the library. For example, my project in ./test/src/main.cpp is not able to include ./include/log.hpp. The source file ./src/log.cpp can include ./include/log.hpp.

---

<div class="post-metadata">

### Author: ![ClausKlein](https://discourse.cmake.org/user_avatar/discourse.cmake.org/clausklein/32/352_2.png) [@ClausKlein](https://discourse.cmake.org/u/ClausKlein)
#### Post date: [February 17, 2024, 11:23pm UTC](https://discourse.cmake.org/t/how-to-properly-setup-cmake-library/10127/2 "2024-02-17T23:23:53Z")

</div>

see [Using PUBLIC FILE\_SET HEADERS with dependent targets - #5 by ClausKlein](https://discourse.cmake.org/t/using-public-file-set-headers-with-dependent-targets/10031/5)
