[GH-ISSUE #49] media-control is not really cross platform #951

Closed
opened 2026-03-14 12:37:48 +03:00 by kerem · 7 comments
Owner

Originally created by @0323pin on GitHub (Jun 6, 2022).
Original GitHub issue: https://github.com/aome510/spotify-player/issues/49

Hi @aome510

I've finally enabled the lyric-finder option and built the package locally. It works really well, thanks!
I've asked internally if https://genius.com/ is an acceptable source of lyrics or, if we have any license concerns with it.
If all is ok, I'll merge an update later enabling this feature.

As for media-control, it will need to be off and not even possible to enable as an optional build feature for now.
Although we do support dbus, souvlaki does not support our OS, according to Cargo-toml,

[target.'cfg(target_os = "windows")'.dependencies]
raw-window-handle = "0.3.3"

[target.'cfg(target_os = "windows")'.dependencies.windows]
version = "0.29.0"
features = [
    "alloc",
	"Foundation",
	"Media",
	"Win32_Foundation",
	"Win32_System_WinRT",
	"Storage_Streams",
]

[target.'cfg(target_os = "macos")'.dependencies]
block = "0.1.6"
cocoa = "0.24.0"
core-graphics = "0.22.2"
dispatch = "0.2.0"
objc = "0.2.7"

[target.'cfg(target_os = "linux")'.dependencies]
dbus = "0.9.5"
dbus-crossroads = "0.5.0"

It's probably possible to fix this by simply adding a target definition but, I haven't looked into this yet.
Looking forward to the cover feature, the viuer and image crates work on NetBSD and should not be a problem to enable this option.

Please keep media-control as an optional feature.
Thanks

Originally created by @0323pin on GitHub (Jun 6, 2022). Original GitHub issue: https://github.com/aome510/spotify-player/issues/49 Hi @aome510 I've finally enabled the `lyric-finder` option and built the package locally. It works really well, thanks! I've asked internally if https://genius.com/ is an acceptable source of lyrics or, if we have any license concerns with it. If all is ok, I'll merge an update later enabling this feature. As for `media-control`, it will need to be off and not even possible to enable as an optional build feature for now. Although we do support dbus, `souvlaki` does not support our OS, according to `Cargo-toml`, ``` [target.'cfg(target_os = "windows")'.dependencies] raw-window-handle = "0.3.3" [target.'cfg(target_os = "windows")'.dependencies.windows] version = "0.29.0" features = [ "alloc", "Foundation", "Media", "Win32_Foundation", "Win32_System_WinRT", "Storage_Streams", ] [target.'cfg(target_os = "macos")'.dependencies] block = "0.1.6" cocoa = "0.24.0" core-graphics = "0.22.2" dispatch = "0.2.0" objc = "0.2.7" [target.'cfg(target_os = "linux")'.dependencies] dbus = "0.9.5" dbus-crossroads = "0.5.0" ``` It's probably possible to fix this by simply adding a target definition but, I haven't looked into this yet. Looking forward to the `cover` feature, the `viuer` and `image` crates work on NetBSD and should not be a problem to enable this option. Please keep `media-control` as an optional feature. Thanks
kerem closed this issue 2026-03-14 12:37:53 +03:00
Author
Owner

@aome510 commented on GitHub (Jun 6, 2022):

As for media-control, it will need to be off and not even possible to enable as an optional build feature for now.
Although we do support dbus, souvlaki does not support our OS, according to Cargo-toml,

That's unfortunate. I'll disable media-control feature by default for the next release.

In the meantime, can you raise an issue upstream in https://github.com/Sinono3/souvlaki? I guess if NetBSD supports DBus, adding a new target to that crate will not be a problem.

<!-- gh-comment-id:1147510298 --> @aome510 commented on GitHub (Jun 6, 2022): > As for media-control, it will need to be off and not even possible to enable as an optional build feature for now. Although we do support dbus, souvlaki does not support our OS, according to Cargo-toml, That's unfortunate. I'll disable `media-control` feature by default for the next release. In the meantime, can you raise an issue upstream in https://github.com/Sinono3/souvlaki? I guess if NetBSD supports DBus, adding a new target to that crate will not be a problem.
Author
Owner

@0323pin commented on GitHub (Jun 6, 2022):

@aome510 Thanks, but you don't need to disable it by default. As long as it's an optional feature, like it is now, I can disable it at build time. No worries, it was just an heads-up.

In the meantime, can you raise an issue upstream in https://github.com/Sinono3/souvlaki? I guess if NetBSD supports DBus, adding a new target to that crate will not be a problem.

I was just looking at src/platforms/linux/mod.rs to see if there was anything Linux specific 😄
I think adding a new target might be all that is needed.

One last question if you don't mind. Did you get permission from Genius to use their API?
Regards

<!-- gh-comment-id:1147517542 --> @0323pin commented on GitHub (Jun 6, 2022): @aome510 Thanks, but you don't need to disable it by default. As long as it's an optional feature, like it is now, I can disable it at build time. No worries, it was just an heads-up. > In the meantime, can you raise an issue upstream in https://github.com/Sinono3/souvlaki? I guess if NetBSD supports DBus, adding a new target to that crate will not be a problem. I was just looking at `src/platforms/linux/mod.rs` to see if there was anything Linux specific 😄 I think adding a new target might be all that is needed. One last question if you don't mind. Did you get permission from Genius to use their API? Regards
Author
Owner

@aome510 commented on GitHub (Jun 6, 2022):

Thanks, but you don't need to disable it by default. As long as it's an optional feature, like it is now, I can disable it at build time. No worries, it was just an heads-up.

Ah, thanks for the clarification.

One last question if you don't mind. Did you get permission from Genius to use their API?

No, I use their public search API (no permission required AFAIK) and web crawling to get lyric data. I'm not an expert on this, so not sure if that will be a legal problem. FYI, I was inspired by youtube-music. Maybe we can get some information from there.

<!-- gh-comment-id:1147530863 --> @aome510 commented on GitHub (Jun 6, 2022): > Thanks, but you don't need to disable it by default. As long as it's an optional feature, like it is now, I can disable it at build time. No worries, it was just an heads-up. Ah, thanks for the clarification. > One last question if you don't mind. Did you get permission from Genius to use their API? No, I use their public search API (no permission required AFAIK) and web crawling to get lyric data. I'm not an expert on this, so not sure if that will be a legal problem. FYI, I was inspired by [`youtube-music`](https://github.com/th-ch/youtube-music/blob/master/plugins/lyrics-genius/back.js). Maybe we can get some information from there.
Author
Owner

@0323pin commented on GitHub (Jun 6, 2022):

Thanks! Closing this now.

<!-- gh-comment-id:1147537535 --> @0323pin commented on GitHub (Jun 6, 2022): Thanks! Closing this now.
Author
Owner

@0323pin commented on GitHub (Jun 6, 2022):

@aome510 lyric_finder feature off by default 😞

Concerns with the following paragraph,
"Commercial Use: Unless otherwise expressly authorized herein or by Genius' express written consent, you agree not to display, distribute, license, perform, publish, reproduce, duplicate, copy, create derivative works from, modify, sell, resell, exploit, transfer or transmit for any commercial purposes, any portion of the Service, use of the Service, or access to the Service. The Service is for your personal use and may not be used for direct commercial endeavors without the express written consent of Genius."

<!-- gh-comment-id:1147849364 --> @0323pin commented on GitHub (Jun 6, 2022): @aome510 `lyric_finder` feature off by default 😞 Concerns with the following paragraph, _"Commercial Use: Unless otherwise expressly authorized herein or by Genius' express written consent, you agree not to display, distribute, license, perform, publish, reproduce, duplicate, copy, create derivative works from, modify, sell, resell, exploit, transfer or transmit for any commercial purposes, any portion of the Service, use of the Service, or access to the Service. The Service is for your personal use and may not be used for direct commercial endeavors without the express written consent of Genius."_
Author
Owner

@0323pin commented on GitHub (Jun 7, 2022):

@aome510 I've finally fixed it. lyric_finder is off by default but, it's possible to enable it at compile time. As for media-control, I've submited a PR to souvlaki after test building it stand alone. Let's see what happens 😄
Hopefully, they don't switch to zbus from dbus + dbus-crossroads, zbus doesn't build on NetBSD 😨

<!-- gh-comment-id:1149140903 --> @0323pin commented on GitHub (Jun 7, 2022): @aome510 I've finally fixed it. `lyric_finder` is off by default but, it's possible to enable it at compile time. As for `media-control`, I've submited a PR to `souvlaki` after test building it stand alone. Let's see what happens 😄 Hopefully, they don't switch to `zbus` from `dbus` + `dbus-crossroads`, `zbus` doesn't build on NetBSD 😨
Author
Owner

@aome510 commented on GitHub (Jun 7, 2022):

Wow, great to hear that. Thanks @0323pin 💪

<!-- gh-comment-id:1149202257 --> @aome510 commented on GitHub (Jun 7, 2022): Wow, great to hear that. Thanks @0323pin 💪
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/spotify-player#951
No description provided.