File system-wayland.patch of Package nodejs-electron

--- src/third_party/wayland/BUILD.gn.old
+++ src/third_party/wayland/BUILD.gn
@@ -45,7 +45,14 @@
   generator_type = "protocol-client"
 }
 
+pkg_config("system_wayland_client") {
+  packages = [ "wayland-client" ]
+}
+
 source_set("wayland_util") {
+  public_configs = [":system_wayland_client"]
+}
+source_set("xwayland_util") {
   sources = [
     "src/src/wayland-private.h",
     "src/src/wayland-util.c",
@@ -77,7 +84,14 @@
   public_configs = [ ":wayland_config" ]
 }
 
-static_library("wayland_server") {
+pkg_config("system_wayland_server") {
+  packages = [ "wayland-server" ]
+}
+
+source_set("wayland_server") {
+  public_configs = [":system_wayland_server"]
+}
+static_library("xwayland_server") {
   sources = [
     "src/src/event-loop.c",
     "src/src/wayland-server.c",
@@ -104,7 +118,10 @@
   public_configs = [ ":wayland_config" ]
 }
 
-static_library("wayland_client") {
+source_set("wayland_client") {
+  public_configs = [":system_wayland_client"]
+}
+static_library("xwayland_client") {
   sources = [ "src/src/wayland-client.c" ]
 
   deps = [
@@ -124,7 +141,14 @@
   public_configs = [ ":wayland_config" ]
 }
 
-static_library("wayland_egl") {
+pkg_config("system_wayland_egl") {
+  packages = [ "wayland-egl" ]
+}
+
+source_set("wayland_egl") {
+  public_configs = [":system_wayland_egl"]
+}
+static_library("xwayland_egl") {
   sources = [
     "src/egl/wayland-egl-backend.h",
     "src/egl/wayland-egl-core.h",
@@ -143,7 +167,14 @@
   public_configs = [ ":wayland_config" ]
 }
 
-static_library("wayland_cursor") {
+pkg_config("system_wayland_cursor") {
+  packages = [ "wayland-cursor" ]
+}
+
+source_set("wayland_cursor") {
+  public_configs = [":system_wayland_cursor"]
+}
+static_library("xwayland_cursor") {
   sources = [
     "src/cursor/cursor-data.h",
     "src/cursor/os-compatibility.c",
@@ -173,7 +204,11 @@
   include_dirs = [ "include/" ]
 }
 
-executable("wayland_scanner") {
+copy("wayland_scanner") {
+  sources = [ "/usr/bin/wayland-scanner" ]
+  outputs = [ "$root_out_dir/wayland_scanner" ]
+}
+executable("xwayland_scanner") {
   sources = [ "src/src/scanner.c" ]
 
   deps = [
openSUSE Build Service is sponsored by