Compare commits

...

5 Commits

Author SHA1 Message Date
Timur A. Fatkhullin
2f80bcc78b ... 2026-02-18 00:08:19 +03:00
Timur A. Fatkhullin
408d23c376 ... 2026-02-17 23:54:46 +03:00
Timur A. Fatkhullin
b98063b229 ... 2026-02-17 23:22:46 +03:00
Timur A. Fatkhullin
00c7641d50 ... 2026-02-17 22:35:56 +03:00
Timur A. Fatkhullin
af5d852db9 ... 2026-02-17 22:02:27 +03:00
4 changed files with 17 additions and 5 deletions

View File

@@ -265,6 +265,7 @@ endif()
if(USE_BSPLINE_PCM)
target_compile_definitions(${PROJECT_NAME} INTERFACE USE_BSPLINE_PCM)
target_link_libraries(${PROJECT_NAME} INTERFACE fitpack)
target_link_directories(${PROJECT_NAME} INTERFACE "$<BUILD_INTERFACE:${CMAKE_BINARY_DIR}/fitpack>")
endif()
if(USE_ASIO)
@@ -273,6 +274,8 @@ endif()
if(USE_SPDLOG)
target_link_libraries(${PROJECT_NAME} INTERFACE spdlog::spdlog_header_only)
# target_compile_definitions(${PROJECT_NAME} INTERFACE SPDLOG_USE_STD_FORMAT=1 SPDLOG_FMT_EXTERNAL=0)
target_compile_definitions(${PROJECT_NAME} INTERFACE SPDLOG_USE_STD_FORMAT=1)
endif()
if(BUILD_TESTS)

View File

@@ -32,7 +32,8 @@ FortranCInterface_VERIFY(CXX)
# include_directories(${BSPLINES_INCLUDE_DIR})
# add_library(fitpack_project STATIC EXCLUDE_FROM_ALL ${src_files} mcc_bsplines.h)
add_library(fitpack_project STATIC EXCLUDE_FROM_ALL ${src_files})
# add_library(fitpack_project STATIC EXCLUDE_FROM_ALL ${src_files})
add_library(fitpack_project STATIC ${src_files})
add_library(fitpack STATIC IMPORTED GLOBAL)
set_target_properties(
@@ -44,6 +45,7 @@ set_target_properties(
fitpack
PROPERTIES
INTERFACE_INCLUDE_DIRECTORIES
"${CMAKE_CURRENT_SOURCE_DIR};${CMAKE_CURRENT_BINARY_DIR}"
"${CMAKE_CURRENT_BINARY_DIR}"
# "${CMAKE_CURRENT_SOURCE_DIR};${CMAKE_CURRENT_BINARY_DIR}"
)
add_dependencies(fitpack fitpack_project)

View File

@@ -68,7 +68,7 @@ constexpr static std::string_view trimSpaces(const char* r, TrimType type = Trim
}
template <typename T, std::ranges::contiguous_range R>
std::optional<T> numFromStr(R&& r)
static std::optional<T> numFromStr(R&& r)
requires((std::integral<T> || std::floating_point<T>) &&
std::same_as<char, std::remove_cvref_t<std::ranges::range_value_t<R>>>)
{
@@ -340,7 +340,10 @@ static std::string AZZD_rad2sxg(double az, double zd, std::string_view delim = "
// "12:43:23.423, 102:43:12.124"
// " 12.3453467, 102:43:12.124 "
template <mcc::traits::mcc_input_char_range R>
std::pair<double, double> parseAnglePair(R&& str, bool hms1 = false, bool hms2 = false, std::string_view delim = ",")
static std::pair<double, double> parseAnglePair(R&& str,
bool hms1 = false,
bool hms2 = false,
std::string_view delim = ",")
{
std::pair<double, double> res{std::numeric_limits<double>::quiet_NaN(), std::numeric_limits<double>::quiet_NaN()};
auto found1 = std::ranges::search(std::forward<R>(str), delim);
@@ -382,7 +385,10 @@ std::pair<double, double> parseAnglePair(R&& str, bool hms1 = false, bool hms2 =
// 1st element: difference along co-latitude axis
// 2nd element: distance
std::tuple<double, double, double> distanceOnSphere(double co_lon1, double co_lat1, double co_lon2, double co_lat2)
static std::tuple<double, double, double> distanceOnSphere(double co_lon1,
double co_lat1,
double co_lon2,
double co_lat2)
{
std::tuple<double, double, double> res{};

View File

@@ -15,6 +15,7 @@ static std::uniform_real_distribution<double> xs_distrib(100, 700);
static std::uniform_real_distribution<double> ys_distrib(100, 700);
struct hw_t {
static constexpr mcc::MccMountType mountType{mcc::MccMountType::ALTAZ_TYPE};
static constexpr std::string_view hardwareName{"HW-TEST"};
typedef int error_t;