on xenial help sign in
Lazily start indicators, and only once unity8 is ready to receive them
f4ede85Michael Terry
data/CMakeLists.txt+5−2
@@ -10,9 +10,12 @@ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${SHELL_APP}.desktop ${CMAKE_CURRENT_B
10install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${GREETER_APP}.desktop
10install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${GREETER_APP}.desktop
11 DESTINATION ${CMAKE_INSTALL_DATADIR}/lightdm/greeters
11 DESTINATION ${CMAKE_INSTALL_DATADIR}/lightdm/greeters
12 )
12 )
13−install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/51-${GREETER_APP}.conf
13+install(FILES 51-${GREETER_APP}.conf
14 DESTINATION ${CMAKE_INSTALL_DATADIR}/lightdm/lightdm.conf.d
14 DESTINATION ${CMAKE_INSTALL_DATADIR}/lightdm/lightdm.conf.d
15 )
15 )
16−install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/${GREETER_APP}-wrapper
16+install(FILES ${GREETER_APP}-wrapper
17 DESTINATION ${CMAKE_INSTALL_BINDIR}
17 DESTINATION ${CMAKE_INSTALL_BINDIR}
18 )
18 )
19+install(FILES unity8-greeter-init.conf
20+ DESTINATION ${CMAKE_INSTALL_DATADIR}/upstart/sessions
21+ )
plugins/LightDM/unity8-greeter-init.conf → data/unity8-greeter-init.confrenamed−1
@@ -6,7 +6,6 @@ emits indicator-services-start
6task
6task
7
7
8script
8script
9− initctl emit --no-wait indicator-services-start
10 initctl start --no-wait ofono-setup || true
9 initctl start --no-wait ofono-setup || true
11 initctl start --no-wait maliit-server || true
10 initctl start --no-wait maliit-server || true
12end script
11end script
data/unity8-greeter-wrapper+5−1
@@ -56,8 +56,12 @@ fi
56# session would. So it's inconvenient to live within an upstart session.
56# session would. So it's inconvenient to live within an upstart session.
57# But... we still want to use Upstart for some services. So launch here.
57# But... we still want to use Upstart for some services. So launch here.
58MIR_SOCKET=$SUB_SOCKET $TOUCH_WRAPPER /sbin/init --user --startup-event=unity8-greeter-started &
58MIR_SOCKET=$SUB_SOCKET $TOUCH_WRAPPER /sbin/init --user --startup-event=unity8-greeter-started &
59+INIT_PID=$!
60+while [ ! -e "$XDG_RUNTIME_DIR/upstart/sessions/$INIT_PID.session" ]; do sleep 0.1; done
61+export UPSTART_SESSION=$(/sbin/initctl list-sessions | grep "^$INIT_PID " | cut -d' ' -f2)
59
62
63+export MIR_SERVER_FILE=$SUB_SOCKET
60−exec $TOUCH_WRAPPER $@ --file=$SUB_SOCKET &
64+exec $TOUCH_WRAPPER $@ &
61CMD_PID=$!
65CMD_PID=$!
62wait $CMD_PID
66wait $CMD_PID
63CMD_PID=
67CMD_PID=
plugins/LightDM/CMakeLists.txt−4
@@ -37,7 +37,3 @@ qt5_use_modules(LightDM-qml DBus Qml)
37# export the qmldir qmltypes and plugin files
37# export the qmldir qmltypes and plugin files
38export_qmlfiles(LightDM LightDM)
38export_qmlfiles(LightDM LightDM)
39export_qmlplugin(LightDM 0.1 LightDM TARGETS LightDM-qml)
39export_qmlplugin(LightDM 0.1 LightDM TARGETS LightDM-qml)
40−
41−install(FILES unity8-greeter-init.conf
42− DESTINATION ${CMAKE_INSTALL_DATADIR}/upstart/sessions
43− )