shell icon indicating copy to clipboard operation
shell copied to clipboard

[BUG] Build failure on NixOS due to libcava not found

Open Anninzy opened this issue 10 months ago • 11 comments

Step 1. Before you submit

  • [x] I have read the above instructions and am sure that this is supposed to be posted here.
  • [x] I've successfully updated to the latest versions following the updating guide.
  • [x] I've successfully updated the system packages to the latest.
  • [ ] I've ticked the checkboxes without reading their contents

Step 2. Version info

https://github.com/caelestia-dots/shell/commit/7097cdcab8542737d50e424a483c66acc83eda74

Step 3. Describe the issue

Build failure on NixOS after https://github.com/caelestia-dots/shell/commit/7097cdcab8542737d50e424a483c66acc83eda74

Logs
Running phase: qtPreHook
@nix { "action": "setPhase", "phase": "qtPreHook" }
Running phase: unpackPhase
@nix { "action": "setPhase", "phase": "unpackPhase" }
unpacking source archive /nix/store/rafg4dzd1hl5rk1j5c1rl7x7ymqh2s9h-source
source root is source
Running phase: patchPhase
@nix { "action": "setPhase", "phase": "patchPhase" }
Running phase: updateAutotoolsGnuConfigScriptsPhase
@nix { "action": "setPhase", "phase": "updateAutotoolsGnuConfigScriptsPhase" }
Running phase: configurePhase
@nix { "action": "setPhase", "phase": "configurePhase" }
cmake flags: -GNinja -DCMAKE_FIND_USE_SYSTEM_PACKAGE_REGISTRY=OFF -DCMAKE_FIND_USE_PACKAGE_REGISTRY=OFF -DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON -DCMAKE_BUILD_TYPE=RelWithDebInfo -DBUILD_TESTING=OFF -DCMAKE_INSTALL_LOCALEDIR=/nix/store/c6pc5i775rdap1jiczk09fh457kip18a-caelestia-qml-plugin/share/locale -DCMAKE_INSTALL_LIBEXECDIR=/nix/store/c6pc5i775rdap1jiczk09fh457kip18a-caelestia-qml-plugin/libexec -DCMAKE_INSTALL_LIBDIR=/nix/store/c6pc5i775rdap1jiczk09fh457kip18a-caelestia-qml-plugin/lib -DCMAKE_INSTALL_DOCDIR=/nix/store/c6pc5i775rdap1jiczk09fh457kip18a-caelestia-qml-plugin/share/doc/caelestia-shell -DCMAKE_INSTALL_INFODIR=/nix/store/c6pc5i775rdap1jiczk09fh457kip18a-caelestia-qml-plugin/share/info -DCMAKE_INSTALL_MANDIR=/nix/store/c6pc5i775rdap1jiczk09fh457kip18a-caelestia-qml-plugin/share/man -DCMAKE_INSTALL_INCLUDEDIR=/nix/store/c6pc5i775rdap1jiczk09fh457kip18a-caelestia-qml-plugin/include -DCMAKE_INSTALL_SBINDIR=/nix/store/c6pc5i775rdap1jiczk09fh457kip18a-caelestia-qml-plugin/sbin -DCMAKE_INSTALL_BINDIR=/nix/store/c6pc5i775rdap1jiczk09fh457kip18a-caelestia-qml-plugin/bin -DCMAKE_INSTALL_NAME_DIR=/nix/store/c6pc5i775rdap1jiczk09fh457kip18a-caelestia-qml-plugin/lib -DCMAKE_STRIP=/nix/store/6n5r46icm0bl55s9p5z2zgcv93m39r5l-clang-wrapper-21.1.8/bin/strip -DCMAKE_RANLIB=/nix/store/6n5r46icm0bl55s9p5z2zgcv93m39r5l-clang-wrapper-21.1.8/bin/ranlib -DCMAKE_AR=/nix/store/6n5r46icm0bl55s9p5z2zgcv93m39r5l-clang-wrapper-21.1.8/bin/ar -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_INSTALL_PREFIX=/nix/store/c6pc5i775rdap1jiczk09fh457kip18a-caelestia-qml-plugin -DENABLE_MODULES:STRING=plugin -DINSTALL_QMLDIR:STRING=lib/qt-6/qml -DVERSION:STRING=1.0.0 -DGIT_REVISION:STRING=2e68551738d2b3d39b53e6a6437a23aa962f5c3d -DDISTRIBUTOR:STRING=nix-flake
-- The CXX compiler identification is Clang 21.1.8
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /nix/store/6n5r46icm0bl55s9p5z2zgcv93m39r5l-clang-wrapper-21.1.8/bin/clang++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE
-- Performing Test HAVE_STDATOMIC
-- Performing Test HAVE_STDATOMIC - Success
-- Found WrapAtomic: TRUE
-- Found OpenGL: /nix/store/bafh2k71bs9ls9vjzkkvpzfzilqqis8c-libglvnd-1.7.0/lib/libOpenGL.so
-- Found WrapOpenGL: TRUE
-- Found WrapVulkanHeaders: /nix/store/lhzl3zl3mfl46grkmxda6j5921bki81j-vulkan-headers-1.4.335.0/include
-- Found PkgConfig: /nix/store/rvp7qlpf5jqvdckjy1afjb6aha6j8dxg-pkg-config-wrapper-0.29.2/bin/pkg-config (found version "0.29.2")
-- Checking for module 'libqalculate'
--   Found libqalculate, version 5.9.0
-- Checking for module 'libpipewire-0.3'
--   Found libpipewire-0.3, version 1.4.9
-- Checking for module 'aubio'
--   Found aubio, version 0.4.9
-- Checking for module 'libcava'
--   No package 'libcava' found
CMake Error at /nix/store/lxkvigfj5xy6w2bs7h4xwr3d7wb7piqb-cmake-4.1.2/share/cmake-4.1/Modules/FindPkgConfig.cmake:639 (message):
  The following required packages were not found:

   - libcava

Call Stack (most recent call first):
  /nix/store/lxkvigfj5xy6w2bs7h4xwr3d7wb7piqb-cmake-4.1.2/share/cmake-4.1/Modules/FindPkgConfig.cmake:867 (_pkg_check_modules_internal)
  plugin/src/Caelestia/CMakeLists.txt:6 (pkg_check_modules)


-- Configuring incomplete, errors occurred!

Reminder

  • [x] I agree that it's usually impossible for others to help me without my logs.

Anninzy avatar Jan 28 '26 14:01 Anninzy

Me and a couple of people have the same issue on discord.

BirgerBrun avatar Jan 28 '26 18:01 BirgerBrun

Same issue here

GiorgeLucas avatar Jan 28 '26 20:01 GiorgeLucas

I have the same issue

theslrrah avatar Jan 29 '26 04:01 theslrrah

Same issue on Arch. Its libcava AND python-materialyoucolor for me.

MrPannibal avatar Jan 29 '26 08:01 MrPannibal

Same issue on NixOS, even after I installed libcava via nixpkgs (libcava and cava commands doesn't work after that btw).

TimotheeRen avatar Jan 29 '26 14:01 TimotheeRen

I just updated libcava via yay, it worked for me after that (Arch)

tr1ckstrr avatar Jan 29 '26 14:01 tr1ckstrr

I have fix the issue by reverting the plugin cmake. Since libcava and cava use the same acces "cava" in nixos, cmake got little confused and refused to build. If you want use "github:KebabObama/shell" to use my fixed version or get this line pkg_check_modules(Cava IMPORTED_TARGET libcava REQUIRED) and change it for pkg_check_modules(Cava IMPORTED_TARGET cava REQUIRED)

KebabObama avatar Jan 29 '26 14:01 KebabObama

#1128 There is the fix. @soramanew

KebabObama avatar Jan 29 '26 15:01 KebabObama

as a temporary fix, i am using caelestia-dots/shell/v1.4.1, which seems to work. i use nixos, i found the cause of this to be that pkg-config tries to look for libcava.pc, which returns as not found, while cava.pc is the actual name of the file it's looking for, in the $PKG_CONFIG_PATH variable.

flareyAw avatar Jan 29 '26 18:01 flareyAw

It's specifically commit b334406 that breaks it, so you can instead revert to the previous commit in your flake for now. b334406

    caelestia-shell = {
      #url = "github:caelestia-dots/shell";
      url = "github:caelestia-dots/shell/b334406";
      inputs.nixpkgs.follows = "nixpkgs";
    };

You could also just set it to @KebabObama's commit by using

url = "github:KebabObama/shell";

Dewm-Bot avatar Jan 29 '26 20:01 Dewm-Bot

Fixed! #1128

soramanew avatar Jan 30 '26 00:01 soramanew