Skip to content

Commit

Permalink
Merge pull request #34 from KurtPattyn/bugfix/findPackageInConfig
Browse files Browse the repository at this point in the history
Do not place find_package here.
  • Loading branch information
frederikvannoote authored Aug 27, 2018
2 parents 3cb6f0a + 03ec045 commit 31da745
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
3 changes: 3 additions & 0 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ make
## Usage
Include the following in your `CMakeLists.txt` file
```CMake
find_package(Qt5Core)
find_package(Qt5NetWork)
find_package(Qt5WebSockets)
find_package(Qt5Mqtt)
target_link_libraries(<target> Qt5::Mqtt)
Expand Down
6 changes: 0 additions & 6 deletions src/cmake/config.cmake.in
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,6 @@

include("${CMAKE_CURRENT_LIST_DIR}/@[email protected]")

# find_package will silently look for the dependencies and set the correct
# include directories and link libraries
find_package(Qt@QT_MAJOR_VERSION_REQUIRED@Core QUIET)
find_package(Qt@QT_MAJOR_VERSION_REQUIRED@NetWork QUIET)
find_package(Qt@QT_MAJOR_VERSION_REQUIRED@WebSockets QUIET)

check_required_components(Qt@QT_MAJOR_VERSION_REQUIRED@Core
Qt@QT_MAJOR_VERSION_REQUIRED@Network
Qt@QT_MAJOR_VERSION_REQUIRED@WebSockets)
Expand Down

0 comments on commit 31da745

Please sign in to comment.