Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 872254 - app-arch/zstd: cmake config file is unavailable
Summary: app-arch/zstd: cmake config file is unavailable
Status: UNCONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo's Team for Core System packages
URL: https://bugs.debian.org/cgi-bin/bugre...
Whiteboard:
Keywords:
Depends on:
Blocks: 873526
  Show dependency tree
 
Reported: 2022-09-21 20:41 UTC by emacsray
Modified: 2024-03-18 20:00 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description emacsray 2022-09-21 20:41:57 UTC
Dear Maintainer,

The main branch of llvm-project (milestone: 16.0.0) defaults LLVM_ENABLE_ZSTD to on and searches for zstd's cmake files.
Since libzstd-dev does not provide cmake files like zstdConfig.cmake, llvm-project does not have support for zstd compressed debug sections.
(Search ZSTD on https://github.com/llvm/llvm-project/blob/main/llvm/cmake/config-ix.cmake)
The issue applies to many other packages using CMake and find_package(zstd): they can't make use of the system zstd.

zstd has provided build/cmake for a long time (since around 2016). If one builds zstd with cmake, cmake files like zstdConfig.cmake will be available.
See https://github.com/archlinux/svntogit-packages/blob/packages/zstd/trunk/PKGBUILD#L36 for a configure example.

Reproducible: Always
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-09-21 21:03:26 UTC
The problem is CMake is not an official build system for zstd (nor is meson), so I'm reluctant to use it. Other distros may not be using it either (at last check, some went *back* to the makefiles after the "time/benchmark scandal": https://www.phoronix.com/news/Arch-Linux-Bizarre-Zstd (even though it was harmless in the end)).
Comment 2 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-09-21 21:08:28 UTC
I suggest LLVM falls back to pkg_check_modules given the config files' existence can't be assumed.
Comment 3 Ionen Wolkens gentoo-dev 2022-09-22 08:43:20 UTC
fwiw pcsx2 uses the cmake files too, but I too had mixed feelings about this, so I never opened an issue here and made it use alias_library(Zstd::Zstd PkgConfig::zstd) for now.

Pretty sure many distros skip this file as well so I find it amazing it's being relied on, albeit in pcsx2's case they bundle zstd and use it via cmake themselves making the whole thing a bit awkward.
Comment 4 Sv. Lockal 2024-03-18 20:00:34 UTC
sci-libs/miopen-6.0.2 also wants zstdConfig.cmake, zstd-config.cmake or Findzstd.cmake (note: in lowercase) as optional dependency.