Skip to content

Commit

Permalink
librist: fix darwin
Browse files Browse the repository at this point in the history
https://code.videolan.org/rist/librist/-/tags/v0.2.11 uses `brew` to
augment the include path which breaks with nixpkgs
  • Loading branch information
paparodeo committed Dec 15, 2024
1 parent 49472e2 commit c516d10
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
14 changes: 14 additions & 0 deletions pkgs/by-name/li/librist/no-brew-darwin.diff
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
diff --git a/meson.build b/meson.build
index 05d00b3..b923958 100755
--- a/meson.build
+++ b/meson.build
@@ -39,7 +39,8 @@ deps = []
platform_files = []
inc = []
inc += include_directories('.', 'src', 'include/librist', 'include', 'contrib')
-if (host_machine.system() == 'darwin')
+if (host_machine.system() == 'darwin'
+ and find_program('brew', required : false).found())
r = run_command('brew', '--prefix', check: true)
brewoutput = r.stdout().strip()
inc += include_directories(brewoutput + '/include')
5 changes: 5 additions & 0 deletions pkgs/by-name/li/librist/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ stdenv.mkDerivation rec {
hash = "sha256-xWqyQl3peB/ENReMcDHzIdKXXCYOJYbhhG8tcSh36dY=";
};

patches = [
# https://code.videolan.org/rist/librist/-/issues/192
./no-brew-darwin.diff
];

nativeBuildInputs = [
meson
ninja
Expand Down

0 comments on commit c516d10

Please sign in to comment.