mirror of
https://github.com/chuangzhu/nixpkgs-gnome-mobile.git
synced 2024-12-28 16:06:02 +01:00
58 lines
1.8 KiB
Diff
58 lines
1.8 KiB
Diff
|
diff --git a/js/dbusServices/dbus-service.in b/js/dbusServices/dbus-service.in
|
||
|
old mode 100644
|
||
|
new mode 100755
|
||
|
index 5c698f58a..1ed61a7e3
|
||
|
--- a/js/dbusServices/dbus-service.in
|
||
|
+++ b/js/dbusServices/dbus-service.in
|
||
|
@@ -1,3 +1,9 @@
|
||
|
+#!@gjs@ -m
|
||
|
+
|
||
|
+// gjs determines the package name from argv[0], which is .*-wrapped
|
||
|
+// so we need to override it to the original one.
|
||
|
+imports.package._findEffectiveEntryPointName = () => '@service@'
|
||
|
+
|
||
|
import {programInvocationName, programArgs} from 'system';
|
||
|
|
||
|
imports.package.init({
|
||
|
diff --git a/js/dbusServices/dbus-service.service.in b/js/dbusServices/dbus-service.service.in
|
||
|
index 3b0d09abe..4fd4bb66d 100644
|
||
|
--- a/js/dbusServices/dbus-service.service.in
|
||
|
+++ b/js/dbusServices/dbus-service.service.in
|
||
|
@@ -1,3 +1,3 @@
|
||
|
[D-BUS Service]
|
||
|
Name=@service@
|
||
|
-Exec=@gjs@ -m @pkgdatadir@/@service@
|
||
|
+Exec=@pkgdatadir@/@service@
|
||
|
diff --git a/js/dbusServices/meson.build b/js/dbusServices/meson.build
|
||
|
index eb941ed90..552051e5a 100644
|
||
|
--- a/js/dbusServices/meson.build
|
||
|
+++ b/js/dbusServices/meson.build
|
||
|
@@ -2,6 +2,7 @@ launcherconf = configuration_data()
|
||
|
launcherconf.set('PACKAGE_NAME', meson.project_name())
|
||
|
launcherconf.set('prefix', prefix)
|
||
|
launcherconf.set('libdir', libdir)
|
||
|
+launcherconf.set('gjs', gjs.full_path())
|
||
|
|
||
|
dbus_services = {
|
||
|
'org.gnome.Shell.Extensions': 'extensions',
|
||
|
@@ -18,16 +19,17 @@ endif
|
||
|
config_dir = '@0@/..'.format(meson.current_build_dir())
|
||
|
|
||
|
foreach service, dir : dbus_services
|
||
|
+ svc_launcherconf = launcherconf
|
||
|
+ svc_launcherconf.set('service', service)
|
||
|
configure_file(
|
||
|
input: 'dbus-service.in',
|
||
|
output: service,
|
||
|
- configuration: launcherconf,
|
||
|
+ configuration: svc_launcherconf,
|
||
|
install_dir: pkgdatadir,
|
||
|
)
|
||
|
|
||
|
serviceconf = configuration_data()
|
||
|
serviceconf.set('service', service)
|
||
|
- serviceconf.set('gjs', gjs.full_path())
|
||
|
serviceconf.set('pkgdatadir', pkgdatadir)
|
||
|
|
||
|
configure_file(
|