summary refs log tree commit diff
path: root/pkgs/development/libraries/wayland
diff options
context:
space:
mode:
authorMichael Weiss <dev.primeos@gmail.com>2021-05-05 21:59:13 +0200
committerGitHub <noreply@github.com>2021-05-05 21:59:13 +0200
commit62b0f89f4e64a42f53dcf0d79b76a681099932c5 (patch)
treee5d998c2f75954f581c868212f2635954700cc26 /pkgs/development/libraries/wayland
parentf0bd2732139ba3d5d426d3798be2292b55c86c16 (diff)
parentb062135493d524de32106e2c70864c3e2d449e3f (diff)
downloadnixpkgs-62b0f89f4e64a42f53dcf0d79b76a681099932c5.tar
nixpkgs-62b0f89f4e64a42f53dcf0d79b76a681099932c5.tar.gz
nixpkgs-62b0f89f4e64a42f53dcf0d79b76a681099932c5.tar.bz2
nixpkgs-62b0f89f4e64a42f53dcf0d79b76a681099932c5.tar.lz
nixpkgs-62b0f89f4e64a42f53dcf0d79b76a681099932c5.tar.xz
nixpkgs-62b0f89f4e64a42f53dcf0d79b76a681099932c5.tar.zst
nixpkgs-62b0f89f4e64a42f53dcf0d79b76a681099932c5.zip
Merge pull request #121726 from primeos/wayland-scanner-fix-cross-compilation
wayland{.bin,-scanner}: Add a pkg-config file for cross-compilation
Diffstat (limited to 'pkgs/development/libraries/wayland')
-rw-r--r--pkgs/development/libraries/wayland/default.nix16
1 files changed, 14 insertions, 2 deletions
diff --git a/pkgs/development/libraries/wayland/default.nix b/pkgs/development/libraries/wayland/default.nix
index 07671ddebdd..4a685b43073 100644
--- a/pkgs/development/libraries/wayland/default.nix
+++ b/pkgs/development/libraries/wayland/default.nix
@@ -5,7 +5,7 @@
 , meson
 , pkg-config
 , ninja
-, wayland
+, wayland-scanner
 , expat
 , libxml2
 , withLibraries ? stdenv.isLinux
@@ -64,7 +64,7 @@ stdenv.mkDerivation rec {
     pkg-config
     ninja
   ] ++ lib.optionals isCross [
-    wayland # For wayland-scanner during the build
+    wayland-scanner
   ] ++ lib.optionals withDocumentation [
     (graphviz-nox.override { pango = null; }) # To avoid an infinite recursion
     doxygen
@@ -85,6 +85,18 @@ stdenv.mkDerivation rec {
     docbook_xml_dtd_42
   ];
 
+  postFixup = ''
+    # The pkg-config file is required for cross-compilation:
+    mkdir -p $bin/lib/pkgconfig/
+    cat <<EOF > $bin/lib/pkgconfig/wayland-scanner.pc
+    wayland_scanner=$bin/bin/wayland-scanner
+
+    Name: Wayland Scanner
+    Description: Wayland scanner
+    Version: ${version}
+    EOF
+  '';
+
   meta = with lib; {
     description = "Core Wayland window system code and protocol";
     longDescription = ''