Skip to content

New package: rivalcfg-4.17.0#60987

Open
uggwar wants to merge 1 commit into
void-linux:masterfrom
uggwar:rivalcfg
Open

New package: rivalcfg-4.17.0#60987
uggwar wants to merge 1 commit into
void-linux:masterfrom
uggwar:rivalcfg

Conversation

@uggwar

@uggwar uggwar commented Jun 10, 2026

Copy link
Copy Markdown
  • I tested the changes in this PR: YES
  • This new package conforms to the package requirements: YES
  • I built this PR locally for my native architecture, (x86_64-glibc)

@tranzystorekk tranzystorekk added the new-package This PR adds a new package label Jun 10, 2026
@slymattz

Copy link
Copy Markdown
Contributor

Are you sure it's licensed under Apache-2.0 and not WTFPL? Their github page says it's the latter, in which case, you should probably write WTFPL and do vlicense LICENSE in post_install()

grep -R WTFPL srcpkgs 
srcpkgs/tree-sitter-gitcommit/template:license="WTFPL"
srcpkgs/LGOGDownloader/template:license="WTFPL"
srcpkgs/WindowMaker-devel/template:license="GPL-2.0-or-later, WTFPL"
srcpkgs/WindowMaker-devel/template:     vlicense COPYING.WTFPL
srcpkgs/WindowMaker/template:license="GPL-2.0-or-later, WTFPL"
srcpkgs/WindowMaker/template:   vlicense COPYING.WTFPL
srcpkgs/fcount/template:license="WTFPL"
srcpkgs/gettext-stub-devel/template:license="WTFPL"
srcpkgs/gettext-stub/template:license="WTFPL"
srcpkgs/gohufont/template:license="WTFPL"
srcpkgs/hxtools/template:license="WTFPL AND LGPL-2.0-or-later AND GPL-2.0-or-later"
srcpkgs/hydrus/template:license="WTFPL"
srcpkgs/libcaca-devel/template:license="WTFPL"
srcpkgs/libcaca/template:license="WTFPL"
srcpkgs/lolcat-c/template:license="WTFPL"
srcpkgs/orjail/template:license="WTFPL"
srcpkgs/skroll/template:license="WTFPL"
srcpkgs/toilet/template:license="WTFPL"
srcpkgs/wifish/template:license="WTFPL"
srcpkgs/xcmenu/template:license="WTFPL"
srcpkgs/zimg-devel/template:license="WTFPL"
srcpkgs/zimg/template:license="WTFPL"
srcpkgs/zzuf/template:license="WTFPL"

@uggwar

uggwar commented Jun 10, 2026

Copy link
Copy Markdown
Author

Auch, you are correct. Missed that one! Thanks, will fix tonight!

@ahesford ahesford left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't vendor content like those udev rules, especially when they can be automatically generated by the program.

Comment thread srcpkgs/rivalcfg/template Outdated
homepage="https://github.com/flozz/rivalcfg"
distfiles="https://github.com/flozz/rivalcfg/archive/v${version}.tar.gz"
checksum=9ef0512b097ce46b77d0c74eb9c84411250c91a4dea1c77469a41bfacbe8705d
make_check=no # no tests available

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I used another project as a template and this slipped through. Will remove and test!

Comment thread srcpkgs/rivalcfg/template Outdated
maintainer="Christer Stenbrenden <christer@uggwar.net>"
license="WTFPL"
homepage="https://github.com/flozz/rivalcfg"
distfiles="https://github.com/flozz/rivalcfg/archive/v${version}.tar.gz"

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fetching from $PYPI_SITE should be preferred, unless the GitHub tarball offers content (like tests) that are not shipped in the PyPI distribution.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, didn't know. Will change this and see how it goes.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I really hate that hard coded path for the udev rules that it checks every time it runs. I removed the patch that changes this path, since it probably is better to just go with the application defaults. What do you think?

@uggwar

uggwar commented Jul 9, 2026

Copy link
Copy Markdown
Author

Any interest in this or maybe just close it?

@ahesford

Copy link
Copy Markdown
Member

https://github.com/void-linux/void-packages/actions/runs/29483127221/job/87571238105?pr=60987#step:7:41

Tests aren't being run because you haven't provided checkdepends. You need at least pytest, and probably all of the run-time dependencies.

@ahesford
ahesford dismissed their stale review July 16, 2026 11:40

Prior comments addressed

@uggwar

uggwar commented Jul 16, 2026

Copy link
Copy Markdown
Author

Seems like they use nox, of which I have never heard of before, to run their tests. It is also not packaged yet, but something I could add to this branch maybe? https://github.com/wntrblm/nox

@ahesford

Copy link
Copy Markdown
Member

Don't use nox to run their tests. The tests are built around pytest, and we already have machinery to run tests with pytest. Just provide the dependencies and see how things run.

@uggwar
uggwar force-pushed the rivalcfg branch 2 times, most recently from 4d20306 to a5c7c61 Compare July 20, 2026 11:21
@slymattz

slymattz commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

@uggwar try this (GH contains tests in this case while PyPi doesn't).

just pass the -Q flag to run tests locally ./xbps-src -Q pkg rivalcfg

# Template file for 'rivalcfg'
pkgname=rivalcfg
version=4.17.0
revision=1
build_style=python3-pep517
make_check_args="--deselect=test/test_usbhid.py::TestOpenDevice::test_a_not_plugged_device"
hostmakedepends="python3-flit_core"
depends="python3-hidapi"
checkdepends="${depends} python3-pytest python3-pytest-flake8 python3-pytest-black"
short_desc="Steelseries gaming mice configurator"
maintainer="Christer Stenbrenden <christer@uggwar.net>"
license="WTFPL"
homepage="https://rivalcfg.flozz.org/"
distfiles="https://github.com/flozz/rivalcfg/archive/refs/tags/v${version}.tar.gz"
checksum=9ef0512b097ce46b77d0c74eb9c84411250c91a4dea1c77469a41bfacbe8705d

post_install() {
	# otherwise, running rivalcfg --update-udev as root would be necessary
	python3 -m rivalcfg --print-udev > 99-steelseries-rival.rules
	vinstall 99-steelseries-rival.rules 0644 usr/lib/udev/rules.d

	vlicense LICENSE
}

Other changes I made:

  • deselect one test (couldn't get it to pass)
  • runtime depends: I don't think python3-pyudev is needed. If you experienced problems w/out this package, let me know
  • homepage: they do have a legitimate web page :) either way, GH page would be preferred over PyPi "homepage" link

I tested the package on my Rival 3 mouse:

$ rivalcfg -s 800
W: udev rules are not installed. You may not be able to open the device using a regular user.
   Run 'rivalcfg --update-udev' as root to fix.

There is a warning, but udev rules get applied as expected and switching from 400dpi to 800dpi or 1600dpi takes effect. # rivalcfg --update-udev would generate a file under /etc/udev/rules.d/99-steelseries-rival.rules anyway, so there should be no conflict.

@ahesford

Copy link
Copy Markdown
Member

@slymattz please don't post templates in the comments. It makes review and comparison difficult. Instead, use the suggestion mechanism if you want to highlight meaningful changes.

@uggwar

uggwar commented Jul 20, 2026

Copy link
Copy Markdown
Author

Thanks, @slymattz ! @ahesford explained to me that voidlinux doesn't vendor udev rules like that, so I removed them from the package. I will try out the test fixes you suggests.

@slymattz

Copy link
Copy Markdown
Contributor

@uggwar oh yeah, I missed this bit about udev rules and the general policy not to vendor things like this.

@ahesford sure, I'll use the suggestion mechanism from now on. Thanks for your remark.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

new-package This PR adds a new package

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants