From 917e71c6b2b61add945b0c616ba6432bd4c03845 Mon Sep 17 00:00:00 2001 From: Florian Uhlig <f.uhlig@gsi.de> Date: Tue, 8 Apr 2025 11:12:12 +0200 Subject: [PATCH] Fix compilation on Apple arm64 SSE is not available for arm64, so fallback to use Scalar Vc mode when compiling on arm64. --- algo/kf/core/CMakeLists.txt | 6 +++++- algo/kf/core/KfCoreOfflineNoSSELinkDef.h | 22 ++++++++++++++++++++++ 2 files changed, 27 insertions(+), 1 deletion(-) create mode 100644 algo/kf/core/KfCoreOfflineNoSSELinkDef.h diff --git a/algo/kf/core/CMakeLists.txt b/algo/kf/core/CMakeLists.txt index 1d3bfb4b2..d2bfdf6d5 100644 --- a/algo/kf/core/CMakeLists.txt +++ b/algo/kf/core/CMakeLists.txt @@ -64,7 +64,11 @@ target_link_libraries(KfCore ##### Offline version without the NO_ROOT in order to get standard logger! ############################################# if (NOT CBM_ONLINE_STANDALONE) set(LIBRARY_NAME KfCoreOffline) - set(LINKDEF ${LIBRARY_NAME}LinkDef.h) + if (SSE_FOUND) + set(LINKDEF ${LIBRARY_NAME}LinkDef.h) + else() + set(LINKDEF ${LIBRARY_NAME}NoSSELinkDef.h) + endif() list(APPEND HEADERS data/KfTrackParam.h ) diff --git a/algo/kf/core/KfCoreOfflineNoSSELinkDef.h b/algo/kf/core/KfCoreOfflineNoSSELinkDef.h new file mode 100644 index 000000000..b5abd4a0d --- /dev/null +++ b/algo/kf/core/KfCoreOfflineNoSSELinkDef.h @@ -0,0 +1,22 @@ +/* Copyright (C) 2025 GSI Helmholtzzentrum fuer Schwerionenforschung, Darmstadt + SPDX-License-Identifier: GPL-3.0-only + Authors: Sergei Zharko [committer] */ + + +#ifdef __CINT__ + +#pragma link off all globals; +#pragma link off all classes; +#pragma link off all functions; + +#pragma link C++ class cbm::algo::kf::TrackParamBaseScalar<float> + ; +#pragma link C++ class cbm::algo::kf::TrackParamBaseScalar<double> + ; + +#pragma link C++ class cbm::algo::kf::TrackParamBase<float> + ; +#pragma link C++ class cbm::algo::kf::TrackParamBase<double> + ; +#pragma link C++ class cbm::algo::kf::TrackParamBase<Vc_1::Vector<float, Vc_1::VectorAbi::Scalar> > + ; + +#pragma link C++ class cbm::algo::kf::TrackParam<float> + ; +#pragma link C++ class cbm::algo::kf::TrackParam<double> + ; +#pragma link C++ class cbm::algo::kf::TrackParam<Vc_1::Vector<float, Vc_1::VectorAbi::Scalar> > + ; +#endif -- GitLab