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

lsusb.py: add usb.ids path for Debian #207

Merged
merged 1 commit into from
Nov 10, 2024
Merged

Conversation

aurel32
Copy link
Contributor

@aurel32 aurel32 commented Oct 25, 2024

Commit 008e330 ("lsusb.py: remove @datadir@ instance") removed the possibility to define the location of the usb.ids file through @datadir@ and instead hardcodes the possible paths to the usb.ids file. However the Debian path is missing, fix that.

Fixes: 008e330 ("lsusb.py: remove @datadir@ instance")

Commit 008e330 ("lsusb.py: remove @datadir@ instance") removed the
possibility to define the location of the usb.ids file through @datadir@
and instead hardcodes the possible paths to the usb.ids file. However
the Debian path is missing, fix that.

Fixes: 008e330 ("lsusb.py: remove @datadir@ instance")
Signed-off-by: Aurelien Jarno <[email protected]>
@evelikov
Copy link
Contributor

According to the package listing the upstream path is correct. Which version of Debian are you using?

@evelikov
Copy link
Contributor

The link is to Debian bullseye - looking at the rest (buster, bookworm, trixie and sid) they all use /usr/share/hwdata/usb.ids

@evelikov
Copy link
Contributor

Seems like the Debian packaging is broken - https://packages.debian.org/sid/usbutils-py does not depend on hwdata but on usb.ids. The latter should probably be phased out and removed, especially since it doesn't have a git repo on salsa.

@aurel32
Copy link
Contributor Author

aurel32 commented Oct 29, 2024

No, the hwdata package does not provide /usr/share/hwdata/usb.ids. It:

  • depends on usb.ids
  • provides the /usr/share/hwdata/usb.ids -> /usr/share/misc/usb.ids symlink

@evelikov
Copy link
Contributor

evelikov commented Oct 29, 2024

Change Debian's usbutils-py to depend on hwdata, like all the other distributions do?

Edit: opened a PR against Debian's package to fix this on their end.

@aurel32
Copy link
Contributor Author

aurel32 commented Oct 29, 2024

Change Debian's usbutils-py to depend on hwdata

Depending on hwdata means people will have to install additional data they do not necessary want.

like all the other distributions do?

So why usbutils supports two paths instead of one?

Edit: opened a PR against Debian's package to fix this on their end.

In case you haven't realized, I am the Debian maintainer of this package. Don't explain me how to change things.

@evelikov
Copy link
Contributor

Depending on hwdata means people will have to install additional data they do not necessary want.

See my note in the linked PR, how this can be trivially resolved.

So why usbutils supports two paths instead of one?

Historical reasons.

My suggestion is how to a) make Debian consistent with the rest of the Linux ecosystem, b) carry no patches and c) upstream does not need to carry Debian exclusive workarounds.

If that's too much to ask for, sorry to have bothered you.

@aurel32
Copy link
Contributor Author

aurel32 commented Oct 29, 2024

Depending on hwdata means people will have to install additional data they do not necessary want.

See my note in the linked PR, how this can be trivially resolved.

How opening a PR changes things? It doesn't do more than your suggestion here. At this stage, there is nothing to fix in the package, I haven't uploaded something broken, as you have seen there is a patch to make it fully functional to users.

So why usbutils supports two paths instead of one?

Historical reasons.

Debian has been using that path for 20+ years. Isn't that an historical reason?

My suggestion is how to a) make Debian consistent with the rest of the Linux ecosystem, b) carry no patches and c) upstream does not need to carry Debian exclusive workarounds.

I agree that we should work on getting a common path for all distributions. Now replacing a 20+ year option by a two hardcoded paths for "historical reasons", but not allowing a third one until it is done, is not the right path for that.

@evelikov
Copy link
Contributor

evelikov commented Oct 30, 2024

I agree that we should work on getting a common path for all distributions

All other distributions have taken* the leap. Opened a Debian MR with the initial work - let's keep the discussion in there.

@gregkh
Copy link
Owner

gregkh commented Nov 10, 2024

I'll take this for now, thanks for the fix. But ideally it would be nice if Debian could use the same path as all other distros. If that happens, I'll be glad to take a patch here to revert this change.

@gregkh gregkh merged commit dd312ac into gregkh:master Nov 10, 2024
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants