Commit Graph

6 Commits

Author SHA1 Message Date
Claude
230a614bb1 build(cmake): build bundled GoogleTest with FetchContent
- Add the bundled GoogleTest with FetchContent and OVERRIDE_FIND_PACKAGE,
  so it uses the compiler and flags of the FairMQ build
- Build it in a block() without gmock, install and static analysis
- Replace build_bundled() with fairmq_init_submodule(), which runs
  git submodule update only if the submodule folder is empty, and stops
  with a clear error if it stays empty
- Install the bundled FairCMakeModules into the build directory with its
  tests off, as before
- Use the bundled PicoSHA2 headers directly from the source tree
- With USE_EXTERNAL_GTEST, GTest is a private dependency and no longer
  in FairMQ_PACKAGE_DEPENDENCIES

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 10:21:32 +01:00
Claude
0dfbb73d86 refactor(cmake): use PROJECT_SOURCE_DIR and PROJECT_BINARY_DIR
- CMAKE_SOURCE_DIR and CMAKE_BINARY_DIR point to the top-level project
  and break add_subdirectory() and FetchContent
- Find the helper modules relative to the CMakeLists.txt that includes them
- Replace @CMAKE_BINARY_DIR@ in the example test scripts

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 10:21:32 +01:00
Claude
7d268912ae fix(cmake): find git with find_package(Git)
- The old check dereferenced GIT_EXECUTABLE, so it tested an empty name
  and re-ran find_program every time by accident
- FindGit provides the same GIT_EXECUTABLE variable

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 10:21:31 +01:00
Dennis Klein
2cf49cc50d ci: fix thread-sanitizer build with lld and PIC googletest
- tsan build failed at link with GNU ld:
  "failed to set dynamic section sizes: bad value" (known binutils +
  ThreadSanitizer incompatibility); install lld and select it via
  -fuse-ld=lld for the tsan job only
- pass -fuse-ld=lld through cxx-flags so it reaches the link line,
  avoiding the semicolon-list pitfall of
  list(APPEND CMAKE_EXE_LINKER_FLAGS ...)
- build the bundled googletest with CMAKE_POSITION_INDEPENDENT_CODE=ON:
  lld rejects R_X86_64_32 relocations from the non-PIC libgtest.a when
  producing the position-independent tsan executable; the bundle is built
  by a separate cmake invocation, so the flag must be set there
2026-06-09 23:00:58 +02:00
Dennis Klein
0c4921d650 feat: Drop public bundled dependency to asio 2021-07-16 12:31:17 +02:00
Dennis Klein
20200f02a3 CMake: Refactor into topic-based modules 2021-05-28 10:38:14 +02:00