@@ -55,6 +55,19 @@ end script
55exec ${BINARY:-unity8} $ARGS
55exec ${BINARY:-unity8} $ARGS
57post-start script
57post-start script
58+ # If no MIR_SOCKET was defined on launch, we try to set one here
59+ if [ -z "$(initctl get-env --global UNITY_MIR_SOCKET)" ]; then
60+ if [ -S "$XDG_RUNTIME_DIR/mir_socket" ]; then
61+ mir_socket=$XDG_RUNTIME_DIR/mir_socket
62+ elif [ -S "/tmp/mir_socket" ]; then
63+ mir_socket=/tmp/mir_socket
66+ if [ -n "$mir_socket" ]; then
67+ initctl set-env --global MIR_SOCKET="$mir_socket"
58 initctl emit --no-wait indicator-services-start
71 initctl emit --no-wait indicator-services-start