Skip to content

Commit

Permalink
Allow using obexd without systemd in the user session
Browse files Browse the repository at this point in the history
Not all sessions run systemd --user and in some cases one may be missing
systemd all together.

Provide the correct path instead of /bin/false, allowing dbus to start
the service in such cases.

DBUS implementations can ignore the Exec line all together when run in
systemd aware mode - at least the OG dbus does that. So ultimately this
change is a no-op for the systemd --user case.

On my system, this is literally the only non-system service which uses
/bin/false.
  • Loading branch information
Giovanni Campagna authored and Vudentz committed Feb 13, 2024
1 parent be0e796 commit b16b198
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
4 changes: 1 addition & 3 deletions Makefile.obexd
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,10 @@ install-data-hook:

uninstall-hook:
rm -f $(DESTDIR)$(SYSTEMD_USERUNITDIR)/dbus-org.bluez.obex.service
endif

dbussessionbusdir = $(DBUS_SESSIONBUSDIR)
dbussessionbus_DATA = obexd/src/org.bluez.obex.service
endif

EXTRA_DIST += obexd/src/org.bluez.obex.service

if OBEX

Expand Down
1 change: 1 addition & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -457,6 +457,7 @@ AC_CONFIG_FILES(
mesh/bluetooth-meshd.rst
mesh/bluetooth-mesh.service
obexd/src/obex.service
obexd/src/org.bluez.obex.service
src/bluetoothd.rst
src/bluetooth.service
tools/bluetooth-logger.service
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[D-BUS Service]
Name=org.bluez.obex
Exec=/bin/false
Exec=@exec_prefix@/bluetooth/obexd
SystemdService=dbus-org.bluez.obex.service

0 comments on commit b16b198

Please sign in to comment.