dbus: bump to version 1.10.14
[buildroot-gz.git] / package / dbus / dbus.mk
blobc765e0ae26813b9dfa975987f1ab197023a72bdf
1 ################################################################################
3 # dbus
5 ################################################################################
7 DBUS_VERSION = 1.10.14
8 DBUS_SITE = http://dbus.freedesktop.org/releases/dbus
9 DBUS_LICENSE = AFLv2.1 or GPLv2+ (library, tools), GPLv2+ (tools)
10 DBUS_LICENSE_FILES = COPYING
11 DBUS_INSTALL_STAGING = YES
13 define DBUS_PERMISSIONS
14 /usr/libexec/dbus-daemon-launch-helper f 4755 0 0 - - - - -
15 endef
17 define DBUS_USERS
18 dbus -1 dbus -1 * /var/run/dbus - dbus DBus messagebus user
19 endef
21 DBUS_DEPENDENCIES = host-pkgconf expat
23 DBUS_CONF_ENV = ac_cv_have_abstract_sockets=yes
24 DBUS_CONF_OPTS = \
25 --with-dbus-user=dbus \
26 --disable-tests \
27 --disable-asserts \
28 --enable-abstract-sockets \
29 --disable-selinux \
30 --disable-xml-docs \
31 --disable-doxygen-docs \
32 --disable-dnotify \
33 --with-xml=expat \
34 --with-system-socket=/var/run/dbus/system_bus_socket \
35 --with-system-pid-file=/var/run/messagebus.pid \
36 --with-init-scripts=none
38 ifeq ($(BR2_STATIC_LIBS),y)
39 DBUS_CONF_OPTS += LIBS='-pthread'
40 endif
42 ifeq ($(BR2_microblaze),y)
43 # microblaze toolchain doesn't provide inotify_rm_* but does have sys/inotify.h
44 DBUS_CONF_OPTS += --disable-inotify
45 endif
47 ifeq ($(BR2_PACKAGE_LIBSELINUX),y)
48 DBUS_CONF_OPTS += --enable-selinux
49 DBUS_DEPENDENCIES += libselinux
50 else
51 DBUS_CONF_OPTS += --disable-selinux
52 endif
54 ifeq ($(BR2_PACKAGE_AUDIT)$(BR2_PACKAGE_LIBCAP_NG),yy)
55 DBUS_CONF_OPTS += --enable-libaudit
56 DBUS_DEPENDENCIES += audit libcap-ng
57 else
58 DBUS_CONF_OPTS += --disable-libaudit
59 endif
61 ifeq ($(BR2_PACKAGE_XLIB_LIBX11),y)
62 DBUS_CONF_OPTS += --with-x
63 DBUS_DEPENDENCIES += xlib_libX11
64 ifeq ($(BR2_PACKAGE_XLIB_LIBSM),y)
65 DBUS_DEPENDENCIES += xlib_libSM
66 endif
67 else
68 DBUS_CONF_OPTS += --without-x
69 endif
71 ifeq ($(BR2_INIT_SYSTEMD),y)
72 DBUS_CONF_OPTS += \
73 --enable-systemd \
74 --with-systemdsystemunitdir=/usr/lib/systemd/system
75 DBUS_DEPENDENCIES += systemd
76 else
77 DBUS_CONF_OPTS += --disable-systemd
78 endif
80 # fix rebuild (dbus makefile errors out if /var/lib/dbus is a symlink)
81 define DBUS_REMOVE_VAR_LIB_DBUS
82 rm -rf $(TARGET_DIR)/var/lib/dbus
83 endef
85 DBUS_POST_BUILD_HOOKS += DBUS_REMOVE_VAR_LIB_DBUS
87 define DBUS_REMOVE_DEVFILES
88 rm -rf $(TARGET_DIR)/usr/lib/dbus-1.0
89 endef
91 DBUS_POST_INSTALL_TARGET_HOOKS += DBUS_REMOVE_DEVFILES
93 define DBUS_INSTALL_INIT_SYSV
94 $(INSTALL) -m 0755 -D package/dbus/S30dbus \
95 $(TARGET_DIR)/etc/init.d/S30dbus
97 mkdir -p $(TARGET_DIR)/var/lib
98 rm -rf $(TARGET_DIR)/var/lib/dbus
99 ln -sf /tmp/dbus $(TARGET_DIR)/var/lib/dbus
100 endef
102 define DBUS_INSTALL_INIT_SYSTEMD
103 mkdir -p $(TARGET_DIR)/var/lib/dbus
104 ln -sf /etc/machine-id $(TARGET_DIR)/var/lib/dbus/machine-id
105 endef
107 HOST_DBUS_DEPENDENCIES = host-pkgconf host-expat
108 HOST_DBUS_CONF_OPTS = \
109 --with-dbus-user=dbus \
110 --disable-tests \
111 --disable-asserts \
112 --enable-abstract-sockets \
113 --disable-selinux \
114 --disable-xml-docs \
115 --disable-doxygen-docs \
116 --enable-dnotify \
117 --without-x \
118 --with-xml=expat
120 # dbus for the host
121 DBUS_HOST_INTROSPECT = $(HOST_DBUS_DIR)/introspect.xml
123 HOST_DBUS_GEN_INTROSPECT = \
124 $(HOST_DIR)/usr/bin/dbus-daemon --introspect > $(DBUS_HOST_INTROSPECT)
126 HOST_DBUS_POST_INSTALL_HOOKS += HOST_DBUS_GEN_INTROSPECT
128 $(eval $(autotools-package))
129 $(eval $(host-autotools-package))