Skip to content

Commit

Permalink
cmake: Remove find_package() warnings for CMake >= 3.17.
Browse files Browse the repository at this point in the history
Signed-off-by: Ron Economos <[email protected]>
  • Loading branch information
drmpeg committed Mar 21, 2021
1 parent 07722f2 commit aa98730
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ endif()

# 3rd Party Dependency Stuff
find_package(Qt5 COMPONENTS Core Network Widgets Svg REQUIRED)
include(FindPkgConfig)
find_package(Gnuradio-osmosdr REQUIRED)

set(GR_REQUIRED_COMPONENTS RUNTIME ANALOG AUDIO BLOCKS DIGITAL FILTER FFT PMT)
Expand Down
8 changes: 5 additions & 3 deletions cmake/Modules/FindGnuradio-osmosdr.cmake
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
INCLUDE(FindPkgConfig)
if(NOT PKG_CONFIG_FOUND)
INCLUDE(FindPkgConfig)
endif()
PKG_CHECK_MODULES(PC_GNURADIO_OSMOSDR gnuradio-osmosdr)

FIND_PATH(
Expand All @@ -25,5 +27,5 @@ FIND_LIBRARY(
)

INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(GNURADIO_OSMOSDR DEFAULT_MSG GNURADIO_OSMOSDR_LIBRARIES GNURADIO_OSMOSDR_INCLUDE_DIRS)
MARK_AS_ADVANCED(GNURADIO_OSMOSDR_LIBRARIES GNURADIO_OSMOSDR_INCLUDE_DIRS)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Gnuradio-osmosdr DEFAULT_MSG GNURADIO_OSMOSDR_LIBRARIES GNURADIO_OSMOSDR_INCLUDE_DIRS)
MARK_AS_ADVANCED(GNURADIO_OSMOSDR_LIBRARIES GNURADIO_OSMOSDR_INCLUDE_DIRS)

0 comments on commit aa98730

Please sign in to comment.