Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add android udev rules package #23284

Merged
merged 2 commits into from Jun 28, 2020
Merged

Add android udev rules package #23284

merged 2 commits into from Jun 28, 2020

Conversation

rien
Copy link
Contributor

@rien rien commented Jun 28, 2020

This pr adds the android-udev-rules package, an udev rules list for android devices.

If one installs the android-tools (the adb command), they will almost always want this installed too. So I've added this package as a dependency.

srcpkgs/android-udev-rules/template Outdated Show resolved Hide resolved
srcpkgs/android-udev-rules/template Outdated Show resolved Hide resolved
srcpkgs/android-tools/template Show resolved Hide resolved
@rien rien requested a review from sgn June 28, 2020 13:09
@sgn sgn merged commit 06db3d8 into void-linux:master Jun 28, 2020
@Duncaen
Copy link
Member

Duncaen commented Jun 29, 2020

This adds a group to the devices that doesn't exist.

@Duncaen
Copy link
Member

Duncaen commented Jun 29, 2020

Also not a fan of depending on this by default if android-tools is installed.

@sgn
Copy link
Member

sgn commented Jun 29, 2020

Sorry, I have adbusers group in my setup.

diff --git a/srcpkgs/android-udev-rules/template b/srcpkgs/android-udev-rules/template
index 83d9636a6f..9fc589f713 100644
--- a/srcpkgs/android-udev-rules/template
+++ b/srcpkgs/android-udev-rules/template
@@ -1,7 +1,7 @@
 # Template file for 'android-udev-rules'
 pkgname=android-udev-rules
 version=20200613
-revision=1
+revision=2
 short_desc="Android udev rules list aimed to be the most comprehensive on the net"
 maintainer="Rien Maertens <rien.maertens@posteo.be>"
 license="GPL-3.0-or-later"
@@ -9,6 +9,10 @@ homepage="https://github.com/M0Rf30/android-udev-rules"
 distfiles="https://github.com/M0Rf30/android-udev-rules/archive/${version}.tar.gz"
 checksum=8c7fad8cf97fe106f826f07aa9f033e9aa9ee69422b35dada6d9d2df878b5473
 
+do_patch() {
+	vsed -i -e 's/GROUP="adbusers"/GROUP="users"/' 51-android.rules
+}
+
 do_install() {
 	vinstall 51-android.rules 644 usr/lib/udev/rules.d 51-android.rules
 }

Is this good enough? I'll push it out.
I understand your position on not depending on udev rules.

@Duncaen
Copy link
Member

Duncaen commented Jun 29, 2020

I think keeping the "adbusers" group is better, but creating it as part of the android-udev-rules package.

@rien
Copy link
Contributor Author

rien commented Jun 29, 2020

@Duncaen when would you not want this package if you install android-tools?

@Duncaen
Copy link
Member

Duncaen commented Jun 29, 2020

When using the image tools and for me personally I've been using adb with my own rule for my specific device and after rebooting today I noticed error logs from eudev because of it, I'm probably a bit biased against it because it just doesn't work at the moment.

@rien
Copy link
Contributor Author

rien commented Jun 29, 2020

It was working fine here, but I also had the adbusers group already present. I'll create a fix.

@rien
Copy link
Contributor Author

rien commented Jun 29, 2020

See #23307

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 31, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants