Skip to content

Commit e12128d

Browse files
committed
Update, workaround for libxml2 soname break
1 parent 31ed2cf commit e12128d

File tree

2 files changed

+17
-3
lines changed

2 files changed

+17
-3
lines changed

flake.lock

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.nix

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
stdenv,
44
callPackage,
55
fetchurl,
6+
auto-patchelf,
67
autoPatchelfHook,
78
makeWrapper,
89
makeDesktopItem,
@@ -17,6 +18,7 @@
1718
wayland,
1819
kdePackages,
1920
python3,
21+
libxml2,
2022

2123
binaryNinjaEdition ? "personal",
2224
forceWayland ? false,
@@ -43,6 +45,7 @@ stdenv.mkDerivation {
4345
src = source;
4446
nativeBuildInputs = [
4547
makeWrapper
48+
auto-patchelf
4649
autoPatchelfHook
4750
python3.pkgs.wrapPython
4851
kdePackages.wrapQtAppsHook
@@ -63,6 +66,7 @@ stdenv.mkDerivation {
6366
libxkbcommon
6467
dbus
6568
wayland
69+
libxml2.out
6670
];
6771
pythonDeps = [ python3.pkgs.pip ];
6872
appendRunpaths = [ "${lib.getLib python3}/lib" ];
@@ -109,6 +113,16 @@ stdenv.mkDerivation {
109113
110114
runHook postInstall
111115
'';
116+
117+
# libxml2 soname changes now follow ABI breaks.
118+
# https://gitlab.gnome.org/GNOME/libxml2/-/issues/751
119+
# This is of course ultimately good, but we can't recompile binja
120+
# So let's just force it to use whatever NixOS has. It's Probably Fine™
121+
preFixup = ''
122+
patchelf $out/opt/binaryninja/plugins/lldb/lib/liblldb.so.* \
123+
--replace-needed libxml2.so.2 libxml2.so
124+
'';
125+
112126
dontWrapQtApps = true;
113127
meta = {
114128
mainProgram = "binaryninja";

0 commit comments

Comments
 (0)