2020-12-30 12:35:06 +00:00
|
|
|
# GNSS-SDR is a Global Navigation Satellite System software-defined receiver.
|
2013-07-05 17:00:48 +00:00
|
|
|
# This file is part of GNSS-SDR.
|
|
|
|
#
|
2020-12-30 12:35:06 +00:00
|
|
|
# SPDX-FileCopyrightText: 2010-2020 C. Fernandez-Prades cfernandez(at)cttc.es
|
|
|
|
# SPDX-License-Identifier: BSD-3-Clause
|
2013-07-05 17:00:48 +00:00
|
|
|
|
2013-10-23 18:27:40 +00:00
|
|
|
|
2020-06-12 22:32:40 +00:00
|
|
|
if(USE_CMAKE_TARGET_SOURCES)
|
2020-06-08 18:04:01 +00:00
|
|
|
add_library(front_end_cal_lib STATIC)
|
|
|
|
target_sources(front_end_cal_lib
|
|
|
|
PRIVATE
|
|
|
|
front_end_cal.cc
|
|
|
|
PUBLIC
|
|
|
|
front_end_cal.h
|
|
|
|
)
|
|
|
|
else()
|
|
|
|
source_group(Headers FILES front_end_cal.h)
|
|
|
|
add_library(front_end_cal_lib front_end_cal.cc front_end_cal.h)
|
|
|
|
endif()
|
2015-10-27 19:18:48 +00:00
|
|
|
|
2018-11-21 23:35:21 +00:00
|
|
|
target_link_libraries(front_end_cal_lib
|
2019-02-03 18:24:44 +00:00
|
|
|
PUBLIC
|
|
|
|
Armadillo::armadillo
|
2019-02-07 08:28:20 +00:00
|
|
|
Threads::Threads
|
2019-02-10 17:34:28 +00:00
|
|
|
acquisition_adapters
|
2019-02-03 18:24:44 +00:00
|
|
|
gnss_sdr_flags
|
2019-02-10 17:34:28 +00:00
|
|
|
channel_libs
|
|
|
|
algorithms_libs
|
|
|
|
core_receiver
|
|
|
|
core_libs
|
2019-02-03 18:24:44 +00:00
|
|
|
PRIVATE
|
2019-09-07 10:36:19 +00:00
|
|
|
Boost::headers
|
2019-02-07 08:28:20 +00:00
|
|
|
Gflags::gflags
|
2019-02-03 18:24:44 +00:00
|
|
|
Glog::glog
|
|
|
|
Gnuradio::blocks
|
|
|
|
Gnuradio::runtime
|
2015-10-27 19:18:48 +00:00
|
|
|
)
|
2018-11-18 20:24:54 +00:00
|
|
|
|
2019-02-21 10:42:56 +00:00
|
|
|
if(ENABLE_CLANG_TIDY)
|
|
|
|
if(CLANG_TIDY_EXE)
|
|
|
|
set_target_properties(front_end_cal_lib
|
|
|
|
PROPERTIES
|
|
|
|
CXX_CLANG_TIDY "${DO_CLANG_TIDY}"
|
|
|
|
)
|
|
|
|
endif()
|
|
|
|
endif()
|
|
|
|
|
2020-06-12 22:32:40 +00:00
|
|
|
if(USE_CMAKE_TARGET_SOURCES)
|
2020-06-08 18:04:01 +00:00
|
|
|
add_executable(front-end-cal)
|
|
|
|
target_sources(front-end-cal PRIVATE main.cc)
|
|
|
|
else()
|
|
|
|
add_executable(front-end-cal main.cc)
|
|
|
|
endif()
|
2014-11-04 20:28:01 +00:00
|
|
|
|
2018-11-21 23:35:21 +00:00
|
|
|
target_link_libraries(front-end-cal
|
2020-06-08 18:04:01 +00:00
|
|
|
PRIVATE
|
2019-02-10 17:34:28 +00:00
|
|
|
core_receiver
|
2021-01-16 13:37:19 +00:00
|
|
|
algorithms_libs
|
2019-02-03 18:24:44 +00:00
|
|
|
front_end_cal_lib
|
|
|
|
gnss_sdr_flags
|
2019-09-07 10:36:19 +00:00
|
|
|
Boost::headers
|
2019-02-03 18:24:44 +00:00
|
|
|
Glog::glog
|
|
|
|
)
|
|
|
|
|
2020-04-02 21:59:35 +00:00
|
|
|
if(GNURADIO_USES_STD_POINTERS)
|
|
|
|
target_compile_definitions(front-end-cal
|
2020-06-08 18:04:01 +00:00
|
|
|
PRIVATE -DGNURADIO_USES_STD_POINTERS=1
|
2020-04-02 21:59:35 +00:00
|
|
|
)
|
|
|
|
endif()
|
|
|
|
|
2019-02-03 18:24:44 +00:00
|
|
|
target_compile_definitions(front-end-cal
|
2020-06-08 18:04:01 +00:00
|
|
|
PRIVATE -DGNSS_SDR_VERSION="${VERSION}"
|
|
|
|
PRIVATE -DGNSSSDR_INSTALL_DIR="${CMAKE_INSTALL_PREFIX}"
|
2015-10-27 19:18:48 +00:00
|
|
|
)
|
|
|
|
|
2020-06-12 22:32:40 +00:00
|
|
|
if(USE_GENERIC_LAMBDAS)
|
2020-04-25 20:17:15 +00:00
|
|
|
set(has_generic_lambdas HAS_GENERIC_LAMBDA=1)
|
|
|
|
set(no_has_generic_lambdas HAS_GENERIC_LAMBDA=0)
|
|
|
|
target_compile_definitions(front-end-cal
|
|
|
|
PRIVATE
|
|
|
|
"$<$<COMPILE_FEATURES:cxx_generic_lambdas>:${has_generic_lambdas}>"
|
|
|
|
"$<$<NOT:$<COMPILE_FEATURES:cxx_generic_lambdas>>:${no_has_generic_lambdas}>"
|
|
|
|
)
|
|
|
|
else()
|
|
|
|
target_compile_definitions(front-end-cal
|
|
|
|
PRIVATE
|
|
|
|
-DHAS_GENERIC_LAMBDA=0
|
|
|
|
)
|
|
|
|
endif()
|
2020-04-25 19:41:04 +00:00
|
|
|
|
2020-06-12 22:32:40 +00:00
|
|
|
if(USE_BOOST_BIND_PLACEHOLDERS)
|
2020-05-18 20:50:34 +00:00
|
|
|
target_compile_definitions(front-end-cal
|
|
|
|
PRIVATE
|
2020-06-12 22:32:40 +00:00
|
|
|
-DUSE_BOOST_BIND_PLACEHOLDERS=1
|
2020-05-18 20:50:34 +00:00
|
|
|
)
|
|
|
|
endif()
|
|
|
|
|
2021-10-30 03:43:22 +00:00
|
|
|
if(PMT_USES_BOOST_ANY)
|
|
|
|
target_compile_definitions(front-end-cal
|
|
|
|
PRIVATE
|
|
|
|
-DPMT_USES_BOOST_ANY=1
|
|
|
|
)
|
|
|
|
endif()
|
|
|
|
|
2024-04-13 07:03:46 +00:00
|
|
|
include(XcodeRemoveWarningDuplicates)
|
|
|
|
xcode_remove_warning_duplicates(front-end-cal)
|
2024-04-12 16:15:33 +00:00
|
|
|
|
2020-06-10 15:22:03 +00:00
|
|
|
if(ENABLE_STRIP)
|
|
|
|
set_target_properties(front-end-cal PROPERTIES LINK_FLAGS "-s")
|
|
|
|
endif()
|
|
|
|
|
2019-02-21 10:42:56 +00:00
|
|
|
if(ENABLE_CLANG_TIDY)
|
|
|
|
if(CLANG_TIDY_EXE)
|
|
|
|
set_target_properties(front-end-cal
|
|
|
|
PROPERTIES
|
|
|
|
CXX_CLANG_TIDY "${DO_CLANG_TIDY}"
|
|
|
|
)
|
|
|
|
endif()
|
|
|
|
endif()
|
|
|
|
|
2019-02-04 07:11:28 +00:00
|
|
|
add_custom_command(TARGET front-end-cal POST_BUILD
|
|
|
|
COMMAND ${CMAKE_COMMAND} -E copy $<TARGET_FILE:front-end-cal>
|
2020-06-23 09:06:26 +00:00
|
|
|
${LOCAL_INSTALL_BASE_DIR}/install/$<TARGET_FILE_NAME:front-end-cal>
|
|
|
|
)
|
2019-02-04 07:11:28 +00:00
|
|
|
|
2015-10-27 19:18:48 +00:00
|
|
|
install(TARGETS front-end-cal
|
2018-11-21 23:35:21 +00:00
|
|
|
RUNTIME DESTINATION bin
|
|
|
|
COMPONENT "front-end-cal"
|
2015-10-27 19:18:48 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
find_program(GZIP gzip
|
2018-11-21 23:35:21 +00:00
|
|
|
/bin
|
|
|
|
/usr/bin
|
|
|
|
/usr/local/bin
|
|
|
|
/opt/local/bin
|
|
|
|
/sbin
|
|
|
|
)
|
2014-12-15 18:21:14 +00:00
|
|
|
|
2015-10-27 19:18:48 +00:00
|
|
|
if(NOT GZIP_NOTFOUND)
|
2022-07-28 08:37:36 +00:00
|
|
|
execute_process(COMMAND gzip -9 -c ${GNSSSDR_SOURCE_DIR}/docs/manpage/front-end-cal-manpage
|
|
|
|
WORKING_DIRECTORY ${GNSSSDR_BINARY_DIR} OUTPUT_FILE "${GNSSSDR_BINARY_DIR}/front-end-cal.1.gz"
|
2020-06-23 09:06:26 +00:00
|
|
|
)
|
2022-07-28 08:37:36 +00:00
|
|
|
install(FILES ${GNSSSDR_BINARY_DIR}/front-end-cal.1.gz DESTINATION share/man/man1)
|
2018-11-24 17:40:34 +00:00
|
|
|
endif()
|