Package Details: headsetcontrol-git 3.1.0.r55.g6611933-2

Git Clone URL: https://aur.archlinux.org/headsetcontrol-git.git (read-only, click to copy)
Package Base: headsetcontrol-git
Description: Sidetone and Battery status for Logitech G930, G533, G633, G933 SteelSeries Arctis 7/PRO 2019 and Corsair VOID (Pro) in Linux and MacOSX
Upstream URL: https://github.com/Sapd/HeadsetControl
Keywords: arctis battery corsair g533 g633 g930 g933 headphones headset logitech sidetone steelseries
Licenses: GPL-3.0-only
Conflicts: headsetcontrol
Provides: headsetcontrol, libheadsetcontrol.a, libheadsetcontrol.so
Submitter: sistematico
Maintainer: TheBill2001
Last Packager: TheBill2001
Votes: 6
Popularity: 0.000000
First Submitted: 2020-11-10 15:53 (UTC)
Last Updated: 2026-01-26 06:41 (UTC)

Dependencies (3)

Required by (7)

Sources (1)

Latest Comments

TheBill2001 commented on 2026-01-10 00:19 (UTC) (edited on 2026-01-10 00:36 (UTC) by TheBill2001)

Updated PKGBUILD to build headsetcontrol with both shared and static library. What changed:

  • Add staticlibs to options to keep both static and shared library.
  • Switch to use annotated tag instead. Otherwise, the continuous tag is used.
  • Add -ffat-lto-objects to CXXFLAGS. Otherwise, the static library is unusable.
  • No need to manually generate udev rules anymore.
diff --git a/.SRCINFO b/.SRCINFO
index 081f0a5..28a5871 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,15 +1,16 @@
 pkgbase = headsetcontrol-git
    pkgdesc = Sidetone and Battery status for Logitech G930, G533, G633, G933 SteelSeries Arctis 7/PRO 2019 and Corsair VOID (Pro)
-   pkgver = 2.7.0.r1.gbd8aed3
-   pkgrel = 2
+   pkgver = 3.1.0.r45.g689115a
+   pkgrel = 1
    url = https://github.com/Sapd/HeadsetControl
    arch = x86_64
-   license = GPL3
+   license = GPL-3.0-only
    makedepends = cmake
    makedepends = git
    depends = hidapi
-   provides = headsetcontrol=2.7.0.r1.gbd8aed3
+   provides = headsetcontrol=3.1.0.r45.g689115a
    conflicts = headsetcontrol
+   options = staticlibs
    source = headsetcontrol::git+https://github.com/Sapd/HeadsetControl.git
    sha256sums = SKIP

diff --git a/PKGBUILD b/PKGBUILD
index b84cf09..8f3e4d2 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,42 +1,42 @@
 # Maintainer: Caltlgin Stsodaat <contact@fossdaily.xyz>
 # Contributor: Lucas Saliés Brum <lucas@archlinux.com.br>
 # Contributor: s3lph <aur-hsdquy@s3lph.me>
+# Contributor: Trần Nam Tuấn <tuantran1632001@gmail.com>

 _pkgname='headsetcontrol'
 pkgname="${_pkgname}-git"
-pkgver=2.7.0.r1.gbd8aed3
-pkgrel=2
+pkgver=3.1.0.r45.g689115a
+pkgrel=1
 pkgdesc='Sidetone and Battery status for Logitech G930, G533, G633, G933 SteelSeries Arctis 7/PRO 2019 and Corsair VOID (Pro)'
 arch=('x86_64')
 url='https://github.com/Sapd/HeadsetControl'
-license=('GPL3')
+license=('GPL-3.0-only')
 depends=('hidapi')
 makedepends=('cmake' 'git')
 provides=("${_pkgname}=${pkgver}")
 conflicts=("${_pkgname}")
 source=("${_pkgname}::git+${url}.git")
 sha256sums=('SKIP')
+options=(staticlibs)

 pkgver() {
   cd "${_pkgname}"
-  git describe --long --tags --abbrev=7 | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
+  git describe --long --abbrev=7 | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
 }

 build() {
-  export CFLAGS+=" ${CPPFLAGS}"
-  export CXXFLAGS+=" ${CPPFLAGS}"
+  export CXXFLAGS+=" ${CPPFLAGS} -ffat-lto-objects"
   cmake -B 'build' -S "${_pkgname}" \
     -DCMAKE_BUILD_TYPE='None' \
     -DCMAKE_INSTALL_PREFIX='/usr' \
-    -Wno-dev
-  make -C 'build'
+    -Wno-dev \
+    -DBUILD_SHARED_LIBRARY=ON
+  cmake --build build
 }

 package() {
-  make DESTDIR="${pkgdir}" PREFIX='/usr' -C 'build' install
+  DESTDIR="$pkgdir" cmake --install build
   install -Dvm644 "${_pkgname}/README.md" -t "${pkgdir}/usr/share/doc/${_pkgname}"
-  install -dvm755 "${pkgdir}/usr/lib/udev/rules.d/"
-  "${pkgdir}/usr/bin/headsetcontrol" -u > "${pkgdir}/usr/lib/udev/rules.d/70-headsets.rules"
 }

 # vim: ts=2 sw=2 et:

TheBill2001 commented on 2026-01-07 19:33 (UTC)

Might want to update the package to enable building the shared library along with the static one.

https://github.com/Sapd/HeadsetControl/blob/master/docs/LIBRARY_USAGE.md#building-the-library

TwistedXenos commented on 2025-05-15 23:02 (UTC)

🛠️ After running paru -Syu --devel, the update to headsetcontrol-git (2.7.0.r1.gbd8aed3-2) appears in the AUR helper GUI, but when building, the version reverts to continuous.r0.g12d8483-1.

This seems to happen because the Git repository hasn't actually advanced — pkgver() resolves to the same commit as before (g12d8483), so the installed version doesn’t change.

s3lph commented on 2023-07-03 20:24 (UTC)

@MarsSeed I've updated the package to include your proposed changes.

(I have to say, I was quite surprised to be notified here and and just found out I'm now listed as maintainer of this package for some reason.)

MarsSeed commented on 2023-07-02 02:00 (UTC)

Please implement a pkgver() based on Git tags.

Then please change provides to have version:

provides=("${_pkgname}=${pkgver}")

jomority commented on 2021-05-20 18:09 (UTC)

Thanks to @s3lph for the solution. It works!

However, I would suggest using /usr/lib/udev/rules.d/ instead of /etc/udev/rules.d/ since packages should place their rules there.

s3lph commented on 2021-05-18 20:17 (UTC)

The upstream recently changed their approach to udev rules: Previously they shipped a precomiled list of rules, now they are generated dynamically. Please update the PKGBUILD accordingly. E.g. something like this:

--- a/PKGBUILD  2021-05-18 21:54:34.588270559 +0200
+++ b/PKGBUILD  2021-05-18 22:04:48.154982524 +0200
@@ -33,6 +33,8 @@
 package() {
   make DESTDIR="${pkgdir}" PREFIX='/usr' -C 'build' install
   install -Dvm644 "${_pkgname}/README.md" -t "${pkgdir}/usr/share/doc/${_pkgname}"
+  install -dvm755 "${pkgdir}/etc/udev/rules.d/"
+  "${pkgdir}/usr/bin/headsetcontrol" -u > "${pkgdir}/etc/udev/rules.d/70-headsets.rules"
 }

 # vim: ts=2 sw=2 et: