1 diff --git a/js/dbusServices/dbus-service.in b/js/dbusServices/dbus-service.in
4 index 5c698f58a..1ed61a7e3
5 --- a/js/dbusServices/dbus-service.in
6 +++ b/js/dbusServices/dbus-service.in
10 +// gjs determines the package name from argv[0], which is .*-wrapped
11 +// so we need to override it to the original one.
12 +imports.package._findEffectiveEntryPointName = () => '@service@'
14 import {programInvocationName, programArgs} from 'system';
16 imports.package.init({
17 diff --git a/js/dbusServices/dbus-service.service.in b/js/dbusServices/dbus-service.service.in
18 index 3b0d09abe..4fd4bb66d 100644
19 --- a/js/dbusServices/dbus-service.service.in
20 +++ b/js/dbusServices/dbus-service.service.in
24 -Exec=@gjs@ -m @pkgdatadir@/@service@
25 +Exec=@pkgdatadir@/@service@
26 diff --git a/js/dbusServices/meson.build b/js/dbusServices/meson.build
27 index eb941ed90..552051e5a 100644
28 --- a/js/dbusServices/meson.build
29 +++ b/js/dbusServices/meson.build
30 @@ -2,6 +2,7 @@ launcherconf = configuration_data()
31 launcherconf.set('PACKAGE_NAME', meson.project_name())
32 launcherconf.set('prefix', prefix)
33 launcherconf.set('libdir', libdir)
34 +launcherconf.set('gjs', gjs.full_path())
37 'org.gnome.Shell.Extensions': 'extensions',
38 @@ -18,16 +19,17 @@ endif
39 config_dir = '@0@/..'.format(meson.current_build_dir())
41 foreach service, dir : dbus_services
42 + svc_launcherconf = launcherconf
43 + svc_launcherconf.set('service', service)
45 input: 'dbus-service.in',
47 - configuration: launcherconf,
48 + configuration: svc_launcherconf,
49 install_dir: pkgdatadir,
52 serviceconf = configuration_data()
53 serviceconf.set('service', service)
54 - serviceconf.set('gjs', gjs.full_path())
55 serviceconf.set('pkgdatadir', pkgdatadir)