Skip to content

Commit 036953b

Browse files
Remove CPDB backend info file (#26)
The frontend libraries now use only the D-Bus to find available backends. This makes sure that everything works also if the frontend and/or any of the backends are installed via sanboxed packaging (like Snap for example) where the components cannot read each other's file systems.
1 parent b930eb8 commit 036953b

4 files changed

Lines changed: 1 addition & 14 deletions

File tree

configure.ac

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,6 @@ PKG_CHECK_VAR([DBUS_SERVICES_DIR], [dbus-1], [session_bus_services_dir],
3535
AC_MSG_FAILURE([cannot locate session_bus_services_dir])
3636
)
3737

38-
# The info directory which will be read by the frontend
39-
AC_MSG_CHECKING([CPDB backend info path])
40-
PKG_CHECK_VAR([INFO_DIR], [cpdb], [cpdb_backend_info_dir],
41-
AC_MSG_RESULT($INFO_DIR),
42-
AC_MSG_FAILURE([cannot locate cpdb_backend_info_dir])
43-
)
44-
4538
# The directory for the backend executables
4639
AC_MSG_CHECKING([CPDB backend executables path])
4740
PKG_CHECK_VAR([CPDB_BACKEND_DIR], [cpdb], [cpdb_backend_exec_dir],

data/Makefile.am

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
EXTRA_DIST = \
22
org.cups.cupsd.Notifier.xml \
3-
org.openprinting.Backend.CUPS \
43
org.openprinting.Backend.CUPS.service.in
54

65
# Dbus service file
@@ -11,8 +10,5 @@ service_DATA = $(service_in_files:.service.in=.service)
1110
$(service_DATA): $(service_in_files) Makefile
1211
@sed -e "s|\@cpdb_backend_dir\@|$(CPDB_BACKEND_DIR)|" $<> $@
1312

14-
info_backenddir = $(INFO_DIR)
15-
info_backend_DATA = org.openprinting.Backend.CUPS
16-
1713
clean-local:
1814
rm -rf $(service_DATA)

data/org.openprinting.Backend.CUPS

Lines changed: 0 additions & 1 deletion
This file was deleted.

src/print_backend_cups.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212

1313
#define _CUPS_NO_DEPRECATED 1
1414
#define BUS_NAME "org.openprinting.Backend.CUPS"
15-
#define OBJECT_PATH "/"
1615

1716
static void
1817
on_name_acquired(GDBusConnection *connection,
@@ -164,7 +163,7 @@ on_name_acquired(GDBusConnection *connection,
164163
b->dbus_connection = connection;
165164
b->skeleton = print_backend_skeleton_new();
166165
connect_to_signals();
167-
connect_to_dbus(b, OBJECT_PATH);
166+
connect_to_dbus(b, CPDB_BACKEND_OBJ_PATH);
168167
}
169168

170169
static gboolean on_handle_get_printer_list(PrintBackend *interface,

0 commit comments

Comments
 (0)