Github messages for voidlinux
 help / color / mirror / Atom feed
From: classabbyamp <classabbyamp@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: Re: hackrf: fix udev rules directory
Date: Tue, 04 Oct 2022 19:33:16 +0200	[thread overview]
Message-ID: <20221004173316.iCsOq9ulKrUZy9NnTlA6Sn0YZG1XO3ha_jPC9aNPzyM@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-39633@inbox.vuxu.org>

[-- Attachment #1: Type: text/plain, Size: 3253 bytes --]

New comment by classabbyamp on void-packages repository

https://github.com/void-linux/void-packages/pull/39633#issuecomment-1267333294

Comment:
the previously-installed rules with the `vsed` made it so only elogind users could use the udev rules. The now-installed rules only work with the `plugdev` group (and the `vsed` did nothing useful), this patch fixes that.

This should also be upstreamed, I think.

Also, upstream repo changed namespaces.

template change:
```diff
diff --git a/srcpkgs/hackrf/template b/srcpkgs/hackrf/template
index 397efa95a0..f47857bada 100644
--- a/srcpkgs/hackrf/template
+++ b/srcpkgs/hackrf/template
@@ -12,13 +12,9 @@ short_desc="${_desc} - tools"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://greatscottgadgets.com/hackrf/"
-distfiles="https://github.com/mossmann/hackrf/releases/download/v${version}/${pkgname}-${version}.tar.xz"
+distfiles="https://github.com/greatscottgadgets/hackrf/releases/download/v${version}/${pkgname}-${version}.tar.xz"
 checksum=a43e5080c11efdfe69ddebcc35a02b018e30e820de0e0ebdc7948cf7b0cd93a3
 
-pre_configure() {
-	vsed -i 's|MODE="660", GROUP="plugdev"|TAG+="uaccess"|g' libhackrf/53-hackrf.rules
-}
-
 post_install() {
 	for f in ../firmware-bin/*.{bin,dfu}; do
 		vinstall "$f" 644 usr/share/hackrf/
```
patch:
```diff
enable device access via elogind

--- a/host/libhackrf/53-hackrf.rules.in
+++ b/host/libhackrf/53-hackrf.rules.in
@@ -1,13 +1,13 @@
 # HackRF Jawbreaker
-ATTR{idVendor}=="1d50", ATTR{idProduct}=="604b", SYMLINK+="hackrf-jawbreaker-%k", MODE="660", GROUP="@HACKRF_GROUP@"
+ATTR{idVendor}=="1d50", ATTR{idProduct}=="604b", SYMLINK+="hackrf-jawbreaker-%k", MODE="660", GROUP="@HACKRF_GROUP@", TAG+="uaccess"
 # HackRF One
-ATTR{idVendor}=="1d50", ATTR{idProduct}=="6089", SYMLINK+="hackrf-one-%k", MODE="660", GROUP="@HACKRF_GROUP@"
+ATTR{idVendor}=="1d50", ATTR{idProduct}=="6089", SYMLINK+="hackrf-one-%k", MODE="660", GROUP="@HACKRF_GROUP@", TAG+="uaccess"
 # rad1o
-ATTR{idVendor}=="1d50", ATTR{idProduct}=="cc15", SYMLINK+="rad1o-%k", MODE="660", GROUP="@HACKRF_GROUP@"
+ATTR{idVendor}=="1d50", ATTR{idProduct}=="cc15", SYMLINK+="rad1o-%k", MODE="660", GROUP="@HACKRF_GROUP@", TAG+="uaccess"
 # NXP Semiconductors DFU mode (HackRF and rad1o)
-ATTR{idVendor}=="1fc9", ATTR{idProduct}=="000c", SYMLINK+="nxp-dfu-%k", MODE="660", GROUP="@HACKRF_GROUP@"
+ATTR{idVendor}=="1fc9", ATTR{idProduct}=="000c", SYMLINK+="nxp-dfu-%k", MODE="660", GROUP="@HACKRF_GROUP@", TAG+="uaccess"
 # rad1o "full flash" mode
-KERNEL=="sd?", SUBSYSTEM=="block", ENV{ID_VENDOR_ID}=="1fc9", ENV{ID_MODEL_ID}=="0042", SYMLINK+="rad1o-flash-%k", MODE="660", GROUP="@HACKRF_GROUP@"
+KERNEL=="sd?", SUBSYSTEM=="block", ENV{ID_VENDOR_ID}=="1fc9", ENV{ID_MODEL_ID}=="0042", SYMLINK+="rad1o-flash-%k", MODE="660", GROUP="@HACKRF_GROUP@", TAG+="uaccess"
 # rad1o flash disk
-KERNEL=="sd?", SUBSYSTEM=="block", ENV{ID_VENDOR_ID}=="1fc9", ENV{ID_MODEL_ID}=="0082", SYMLINK+="rad1o-msc-%k", MODE="660", GROUP="@HACKRF_GROUP@"
+KERNEL=="sd?", SUBSYSTEM=="block", ENV{ID_VENDOR_ID}=="1fc9", ENV{ID_MODEL_ID}=="0082", SYMLINK+="rad1o-msc-%k", MODE="660", GROUP="@HACKRF_GROUP@", TAG+="uaccess"
 #
```

  parent reply	other threads:[~2022-10-04 17:33 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-02 20:21 [PR PATCH] " motorto
2022-10-02 20:25 ` [PR PATCH] [Updated] " motorto
2022-10-02 20:36 ` motorto
2022-10-02 21:32 ` Piraty
2022-10-02 21:34 ` Piraty
2022-10-02 21:56 ` paper42
2022-10-03  5:57 ` motorto
2022-10-03  6:00 ` [PR PATCH] [Updated] " motorto
2022-10-03 12:33 ` classabbyamp
2022-10-03 15:40 ` Piraty
2022-10-04  9:40 ` motorto
2022-10-04  9:40 ` [PR PATCH] [Updated] " motorto
2022-10-04  9:42 ` motorto
2022-10-04 11:02 ` motorto
2022-10-04 11:08 ` Piraty
2022-10-04 11:14 ` [PR PATCH] [Updated] " motorto
2022-10-04 17:32 ` classabbyamp
2022-10-04 17:33 ` classabbyamp [this message]
2022-10-04 19:37 ` [PR PATCH] [Updated] " motorto
2022-10-04 19:41 ` motorto
2022-10-04 19:46 ` motorto
2022-10-04 19:50 ` [PR PATCH] [Updated] " motorto
2022-10-04 20:46 ` classabbyamp
2022-10-04 20:49 ` [PR PATCH] [Updated] " motorto
2022-10-04 20:56 ` motorto
2022-10-04 21:01 ` [PR PATCH] [Merged]: " classabbyamp

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20221004173316.iCsOq9ulKrUZy9NnTlA6Sn0YZG1XO3ha_jPC9aNPzyM@z \
    --to=classabbyamp@users.noreply.github.com \
    --cc=ml@inbox.vuxu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).