Conversation
50d9ad6 to
24ac38c
Compare
Add DDPROF_FETCH_LIBDATADOG option (ON by default). When OFF, the fetch script is skipped and find_package(Datadog) resolves through standard CMake search paths. This lets build systems like Conan provide libdatadog as a proper dependency. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
24ac38c to
a14f5be
Compare
|
Fair point on elfutils. Dropped the elfutils part entirely -- the musl patches make it hard to support an external provider without CI coverage. This PR now only covers libdatadog, which has no patches and a clean |
| execute_process( | ||
| COMMAND "${CMAKE_SOURCE_DIR}/tools/fetch_libdatadog.sh" ${TAG_LIBDATADOG} ${Datadog_ROOT} | ||
| WORKING_DIRECTORY ${CMAKE_SOURCE_DIR} COMMAND_ERROR_IS_FATAL ANY) | ||
| if(DDPROF_FETCH_LIBDATADOG) |
There was a problem hiding this comment.
are changes in https://github.com/DataDog/ddprof/pull/504/changes enough to point to a relevant libdatadog install ?
There was a problem hiding this comment.
I added an option to iterate locally on libdatadog changes, though maybe this fits both use cases ?
There was a problem hiding this comment.
Humm, our use case is slightly different: Conan injects find_package config through CMAKE_PREFIX_PATH, so there's no single path to set Datadog_LOCAL_ROOT to.
If #504 also sets DataDog_DIR unconditionally (outside the if), then find_package(Datadog) would find it through standard search paths and both use cases would be covered.
Summary
Findlibdatadog.cmakeunconditionally runs a shell script at configure time to download libdatadog. This prevents providing it externally through Conan or system packages.Add a
DDPROF_FETCH_LIBDATADOGcache option (ON by default, no behavior change). When OFF, the download is skipped andfind_package(Datadog)resolves through standard CMake search paths.Elfutils fetching is left unchanged. Its build applies musl patches that make an external-provider path harder to support without CI coverage.
🤖 Generated with Claude Code