Files
g15stats/debian

g15stats for Debian 13 (local fork package)
=========================================

This packaging targets Linux and debhelper compatibility 13. See PROVENANCE
for the complete Debian 1.9.2-2 import, licensing and snapshot version choice.
All upstream modifications are in debian/patches; do not build in the checkout
when you want it to remain pristine.

Clean source preparation (outside the checkout)
----------------------------------------------
Export ONLY tracked upstream files at commit
95de11a526346b3d9fd33df051b330c36b1c8a16 using git archive, with directory
prefix g15stats-3.0.3+git20240609.95de11a/. Compress with xz to produce
g15stats_3.0.3+git20240609.95de11a.orig.tar.xz. Extract in a temporary build
directory, then copy this debian/ directory into it. Never tar the working
checkout: .git, quilt state and untracked build outputs must not be included.

In a disposable Debian 13 container, install build-essential, debhelper,
autoconf, automake, libtool, pkgconf, libgtop2-dev, libg15-dev,
libg15render-dev and libg15daemon-client-dev (apt-get build-dep on the staged
source directory also resolves Build-Depends). Install lintian for QA.
If the already-built local G15 libraries are available, install their runtime
and development .deb files instead of the distro G15 libraries. Keep libgtop
and other dependencies from Debian 13. Do not install packages on the host.

Run dpkg-buildpackage -S -us -uc in the staged source directory. In another
empty directory/container, extract the resulting .dsc with dpkg-source -x,
then run dpkg-buildpackage -b -us -uc. Source packages here are unsigned;
dpkg-source --no-check is appropriate only after independently checking the
locally produced source artifact checksums. Lint both source and binary
.changes with lintian --fail-on error. Keep logs and all artifacts outside
the checkout. A second independent extraction/build checks rebuildability;
bit-for-bit reproducibility is a separate claim requiring comparison.

Safe smoke test
---------------
Install the resulting binary in a disposable container with no USB mappings,
no host networking and no privileged mode. Suppress service startup using
policy-rc.d before installing g15daemon. Run debian/tests/help, which compares
timeout-bounded --help and -h output. These exit before any daemon connection,
sensor access or keyboard thread. Do not invoke the normal client or -d.
The same test is declared as a superficial autopkgtest.

Scope and limitations
---------------------
No service/init, udev rule, keyboard macro or automatic startup is shipped.
The existing runtime code has not been safety-certified or rewritten: legacy
sensor paths, argument parsing, array bounds, string handling and threading
need separate runtime review. Build/CLI tests do not validate hardware, LCD
rendering, live daemon interaction, battery support or other architectures.
Use --info-rotate, not the incorrectly documented short form -ir; see the
manual for the existing parser discrepancy.