1
0
mirror of https://github.com/gnss-sdr/gnss-sdr synced 2025-12-06 16:48:06 +00:00

CMake: centralize find paths in a single file

Improve Macports/Homebrew detection. Do not hardcode /opt/local or /opt/homebrew
This commit is contained in:
Carles Fernandez
2025-02-16 22:10:20 +01:00
parent a6daa5ad7e
commit fa1e9209c5
46 changed files with 471 additions and 501 deletions

View File

@@ -1,7 +1,7 @@
# GNSS-SDR is a Global Navigation Satellite System software-defined receiver.
# This file is part of GNSS-SDR.
#
# SPDX-FileCopyrightText: 2011-2020 C. Fernandez-Prades cfernandez(at)cttc.es
# SPDX-FileCopyrightText: 2011-2025 C. Fernandez-Prades cfernandez(at)cttc.es
# SPDX-License-Identifier: BSD-3-Clause
# Tries to find gr-osmosdr.
@@ -31,14 +31,14 @@ if(NOT COMMAND feature_summary)
include(FeatureSummary)
endif()
if(NOT GNSSSDR_LIB_PATHS)
include(GnsssdrLibPaths)
endif()
if(NOT PKG_CONFIG_FOUND)
include(FindPkgConfig)
endif()
if(NOT GNSSSDR_LIB_PATHS)
include(GnsssdrFindPaths)
endif()
pkg_check_modules(GROSMOSDR_PKG gnuradio-osmosdr)
if(NOT GROSMOSDR_ROOT)
@@ -61,9 +61,7 @@ find_path(GROSMOSDR_INCLUDE_DIR
${GROSMOSDR_PKG_INCLUDEDIR}
PATHS
${GROSMOSDR_ROOT_USER_DEFINED}/include
/usr/include
/usr/local/include
/opt/local/include
${GNSSSDR_INCLUDE_PATHS}
)
find_library(GROSMOSDR_LIBRARIES