Skip to content

Commit c88c85f

Browse files
authored
Merge pull request #755 from krasznaa/macOSFixes-main-20241026
macOS Fixes, main branch (2024.10.26.)
2 parents 36be249 + 6470016 commit c88c85f

File tree

5 files changed

+29
-12
lines changed

5 files changed

+29
-12
lines changed

.github/workflows/builds.yml

+17-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ concurrency:
1717
cancel-in-progress: true
1818

1919
jobs:
20-
builds:
20+
containers:
2121
name: ${{ matrix.platform.name }}-${{ matrix.build }}
2222
runs-on: ubuntu-latest
2323
container: ${{ matrix.platform.container }}
@@ -117,3 +117,19 @@ jobs:
117117
if: "matrix.platform.name == 'CUDA' && matrix.build == 'Debug'"
118118
continue-on-error: true
119119
run: ${GITHUB_WORKSPACE}/.github/find_f64_ptx.py --source ${GITHUB_WORKSPACE} --build build $(find build -name "*.ptx")
120+
121+
macos:
122+
runs-on: macos-14
123+
name: macOS-Release
124+
steps:
125+
- uses: actions/checkout@v4
126+
- name: Install dependencies
127+
run: brew install boost
128+
- name: Configure
129+
run: cmake --preset base -S ${GITHUB_WORKSPACE} -B build
130+
- name: Build
131+
run: cmake --build build
132+
- name: Download data files
133+
run: ${GITHUB_WORKSPACE}/data/traccc_data_get_files.sh
134+
- name: Test
135+
run: ctest --test-dir build --output-on-failure

benchmarks/CMakeLists.txt

+4-4
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@
88
include( traccc-compiler-options-cpp )
99

1010
# Set up a common library, shared by all of the tests.
11-
add_library( traccc_benchmarks_common STATIC
11+
add_library( traccc_benchmarks_common INTERFACE
1212
"common/benchmarks/toy_detector_benchmark.hpp" )
1313
target_include_directories( traccc_benchmarks_common
14-
PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/common )
14+
INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}/common )
1515
target_link_libraries( traccc_benchmarks_common
16-
PUBLIC benchmark::benchmark benchmark::benchmark_main
17-
traccc::core traccc::io traccc::simulation detray::core detray::test_utils
16+
INTERFACE benchmark::benchmark benchmark::benchmark_main
17+
traccc::core traccc::io traccc::simulation detray::core detray::test_utils
1818
vecmem::core Boost::filesystem)
1919

2020
add_subdirectory(cpu)

core/include/traccc/utils/seed_generator.hpp

+4-4
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ struct seed_generator {
4141
const std::array<scalar, e_bound_size>& stddevs,
4242
const std::size_t sd = 0)
4343
: m_detector(det), m_stddevs(stddevs) {
44-
generator.seed(sd);
44+
m_generator.seed(static_cast<std::mt19937::result_type>(sd));
4545
}
4646

4747
/// Seed generator operation
@@ -80,7 +80,7 @@ struct seed_generator {
8080
for (std::size_t i = 0; i < e_bound_size; i++) {
8181

8282
bound_param[i] = std::normal_distribution<scalar>(
83-
bound_param[i], m_stddevs[i])(generator);
83+
bound_param[i], m_stddevs[i])(m_generator);
8484

8585
matrix_operator().element(bound_param.covariance(), i, i) =
8686
m_stddevs[i] * m_stddevs[i];
@@ -91,8 +91,8 @@ struct seed_generator {
9191

9292
private:
9393
// Random generator
94-
std::random_device rd{};
95-
std::mt19937 generator{rd()};
94+
std::random_device m_rd{};
95+
std::mt19937 m_generator{m_rd()};
9696

9797
// Detector object
9898
const detector_t& m_detector;

performance/include/traccc/resolution/fitting_performance_writer.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/** TRACCC library, part of the ACTS project (R&D line)
22
*
3-
* (c) 2022 CERN for the benefit of the ACTS project
3+
* (c) 2022-2024 CERN for the benefit of the ACTS project
44
*
55
* Mozilla Public License Version 2.0
66
*/
@@ -75,7 +75,7 @@ class fitting_performance_writer {
7575

7676
// Find the contributing particle
7777
// @todo: Use identify_contributing_particles function
78-
std::map<particle, uint64_t> contributing_particles =
78+
std::map<particle, std::size_t> contributing_particles =
7979
meas_to_ptc_map[meas];
8080

8181
const particle ptc = contributing_particles.begin()->first;

performance/src/performance/details/is_same_angle.cpp

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/** TRACCC library, part of the ACTS project (R&D line)
22
*
3-
* (c) 2022 CERN for the benefit of the ACTS project
3+
* (c) 2022-2024 CERN for the benefit of the ACTS project
44
*
55
* Mozilla Public License Version 2.0
66
*/
@@ -10,6 +10,7 @@
1010

1111
// System include(s).
1212
#include <cmath>
13+
#include <numbers>
1314

1415
namespace {
1516

0 commit comments

Comments
 (0)