Fix broken CMake-generated pkg-config files#172150
Fix broken CMake-generated pkg-config files#172150alexshpilkin wants to merge 99 commits intoNixOS:stagingfrom
Conversation
|
I don’t even have the disk space to run nixpkgs-review on this, so if someone would do that I’d be grateful :-/ |
|
Running
|
|
@gador Thanks! (Also, damn it, I’ve already read enough CMake today to last me a year... I’ll get to those as well, I promise, I really will.) Right, my system also had kwayland, I forgot about that. The KDE people use some sort of .pc generator written in CMake that seems to produce uniformly broken pkg-config files, except I’m not sure if they are actually shipping them. Someone more versed in CMake should probably have a look at it. |
|
Either we find the package that is causing so many rebuilds or we send everything trough staging. |
|
@SuperSandro2000 My money is on either libjxl or spirv-tools being deep in the dependency tree of some desktop environment or widget toolkit, but I’m honestly clueless here. Is there even a way to view the list ofborg computed? |
You can click on
in the Github Actions list: That brings up the changed paths: https://gist.github.com/GrahamcOfBorg/67f0505e1d8f9c25d56caa663fbb64ad |
Yes, |
|
@nh2 Right, the smiley! ^^ I knew I saw that list at one point, but could not guess which line of the report to poke at and started doubting myself. @SuperSandro2000 So, I was right that this is a GUI cascade but wrong about the source. The majority of the rebuilds are because of both gtk4 and phonon-backend-gstreamer depending on gst-plugins-bad (which this touches in an incidental drive-by manner) which in turn depends on wildmidi (which this touches in an essential manner). Some of the Qt stuff is triggered by libkdegames depending on openal-soft (which this also touches, indepenently). Other parts of the Qt stuff seem to be spurious as they’re marked broken. Overall, I think punting the wildmidi and the gst-plugins-bad changes to staging should redirect most of the avalanche—or we can just give up and decide this is going to be a large rebuild. Again, I’m clueless here, so please tell me if you want me to cherry-pick some things to a separate branch or something like that. |
|
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/extend-include-search-path-for-a-specific-package/19438/2 |
| let | ||
|
|
||
| joinpaths-src = fetchurl { | ||
| url = "https://AnotherFoxGuy.com/CMakeCM/modules/JoinPaths.cmake"; |
There was a problem hiding this comment.
Might be better to fetch it from a stable URL: https://github.com/AnotherFoxGuy/CMakeCM/raw/afe41f4536ae21f6f11f83e8c0b8b8c450ef1332/modules/JoinPaths.cmake
This reverts commit 5eff4f4.
|
fix'd up and resolved conflicts #181875 |
|
Merged #181875 |

Description of changes
Fixes #167528 and several other cases of similarly broken pkg-config files generated with CMake. The case of zxing-cpp was discussed in review comments of #172046.
I tried to patch things in such a way that the build won’t break even once an upstream fix is in place.
Upstream bugs: jiixyj/libebur128#121, libjxl/libjxl#1400, kcat/openal-soft#696, sctplab/usrsctp#662, Mindwerks/wildmidi#236, zxing-cpp/zxing-cpp#335, KhronosGroup/SPIRV-Tools#3905, openobex#66, dirkvdb/ffmpegthumbnailer#215, Matroska-Org/libmatroska#62, extra-cmake-modules!268, Matroska-Org/libebml#97.
I only patched things that I found by grepping the Nix store on my machine, so it’s probable there are many more cases of this problem in CMake build systems. Someone who has access to a full build of Nixpkgs should probably make a systematic review (
rg -g '*.pc' '}//nix' /nix/storewill probably find most cases).Things done
sandbox = trueset innix.conf? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/)nixos/doc/manual/md-to-db.shto update generated release notes