Merge pull request #5 from pop-os/osd-portal

Start `cosmic-osd`, `xdg-desktop-portal-cosmic`, with privileged sockets
This commit is contained in:
Lucy 2022-08-24 11:05:30 -04:00 committed by GitHub
commit 9c57475bb6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 24 additions and 1 deletions

3
debian/control vendored
View file

@ -19,4 +19,7 @@ Depends:
cosmic-panel,
cosmic-applet-host,
cosmic-applets,
cosmic-osd,
cosmic-settings-daemon,
xdg-desktop-portal-cosmic,
Description: The session for the COSMIC desktop

View file

@ -90,7 +90,6 @@ async fn main() -> Result<()> {
env,
vec![fd],
);
socket_tx.send(sockets).unwrap();
generic::run_executable(
token.child_token(),
info_span!(parent: None, "cosmic-settings-daemon"),
@ -99,6 +98,27 @@ async fn main() -> Result<()> {
vec![],
vec![],
);
let (env, fd) = comp::create_privileged_socket(&mut sockets, &env_vars)
.wrap_err("failed to create applet host")?;
generic::run_executable(
token.child_token(),
info_span!(parent: None, "cosmic-osd"),
"cosmic-osd",
vec![],
env,
vec![fd],
);
let (env, fd) = comp::create_privileged_socket(&mut sockets, &env_vars)
.wrap_err("failed to create applet host")?;
generic::run_executable(
token.child_token(),
info_span!(parent: None, "xdg-desktop-portal-cosmic"),
"/usr/libexec/xdg-desktop-portal-cosmic",
vec![],
env,
vec![fd],
);
socket_tx.send(sockets).unwrap();
let (exit_tx, exit_rx) = oneshot::channel();
let _ = ConnectionBuilder::session()?