about summary refs log tree commit diff
path: root/pkgs/development/libraries/webkitgtk
diff options
context:
space:
mode:
authorColin <colin@uninsane.org>2023-11-07 00:17:21 +0000
committerColin <colin@uninsane.org>2023-11-07 00:17:21 +0000
commit72b3e9b5a0d838ff3a374f9e35e9da0880c01b85 (patch)
treef253bf5fce1e04c4d46918ec76f6c9c2ad0e8daa /pkgs/development/libraries/webkitgtk
parent0d930cd6bbfeda4bef5be62eca5d7f83380c55a6 (diff)
webkitgtk: support cross compilation
which previously errored near the end of compilation with:
```
/nix/store/nnnn-wayland-aarch64-unknown-linux-gnu-1.22.0-bin/bin/wayland-scanner: line 0: syntax error: unexpected word (expecting ")")
```

that is, the build was trying to invoke the host `wayland-scanner`: both
host and build wayland-scanner are made available to the build
environment and the build script isn't smart enough to choose the right
one. fix by explicitly instructing which `wayland-scanner` to use.
Diffstat (limited to 'pkgs/development/libraries/webkitgtk')
-rw-r--r--pkgs/development/libraries/webkitgtk/default.nix4
1 files changed, 2 insertions, 2 deletions
diff --git a/pkgs/development/libraries/webkitgtk/default.nix b/pkgs/development/libraries/webkitgtk/default.nix
index 1db2f4ce6d8cf..07bf66aedc6ac 100644
--- a/pkgs/development/libraries/webkitgtk/default.nix
+++ b/pkgs/development/libraries/webkitgtk/default.nix
@@ -1,5 +1,6 @@
 { lib
 , stdenv
+, buildPackages
 , runCommand
 , fetchurl
 , perl
@@ -122,8 +123,6 @@ stdenv.mkDerivation (finalAttrs: {
     gi-docgen
     glib # for gdbus-codegen
     unifdef
-  ] ++ lib.optionals stdenv.isLinux [
-    wayland # for wayland-scanner
   ];
 
   buildInputs = [
@@ -206,6 +205,7 @@ stdenv.mkDerivation (finalAttrs: {
     # https://github.com/WebKit/WebKit/commit/a84036c6d1d66d723f217a4c29eee76f2039a353
     "-DBWRAP_EXECUTABLE=${lib.getExe bubblewrap}"
     "-DDBUS_PROXY_EXECUTABLE=${lib.getExe xdg-dbus-proxy}"
+    "-DWAYLAND_SCANNER=${buildPackages.wayland-scanner}/bin/wayland-scanner"
   ] ++ lib.optionals stdenv.isDarwin [
     "-DENABLE_GAMEPAD=OFF"
     "-DENABLE_GTKDOC=OFF"