|
From: Matthias G. <m_g...@wi...> - 2025-10-09 07:25:53
|
Hi all, I am glad to announce the userspace parts of linux-gpib are now available in Debian unstable [0]. It provides the C library, the python bindings, the userspace tools and the documentation. Once those migrated to testing (in three days) I will backport the package to trixie (current Debian stable). I won't be packaging the kernel parts as those are in staging anyway; am hoping to enable those once they are in mainline. Currently, the user tools mention in the README.Debian that the DKMS module is still needed. To comply with Debian policy (no prebuilt/pregenerated files) I had to jump through some hoops. The whole process is documented in README.source [1] It would be great if future release tarballs would match the pristine git tree for the corresponding tag; this would really ease future package updates. Another thing I ran into when building the manpages is Debian shipping the xml stylesheet under a different directory, and providing osg2xml as /usr/bin/osx. This resulted in the following patch [2] For the python bindings I opted to version them separately form the GPIB version [3]. I did this since setuptools.py also mentions 1.0 as version; furthermore this allows for an easier split should the bindings be maintained separately at some point. Regarding this, I commited a version using pyproject.toml, and cleaned up the code to the best of my abilities. The last four commits might be of interest here; they fix the indentation for all python files and take care of some other minor warnings [4] IMO the python binding should be split from the source tree to allow building with pyproject.toml; should you choose to switch to that, my fork has all the bits ready. If a standalone setuptools build gets deprecated in Debian I will use my fork and provide the bindings from there (from a separate package). Additionally, for some reason the Changelog is not present in git from 4.3.7; this causes a build failure when trying to build from git since the makefile expects the Changelog to be present. To mitigate this, I touched an empty one; however this should be fixed properly [5]. The last issue I ran into is hardening. Debian recommends that we set the following hardening flags [6]: CFLAGS=-g -O2 -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -flto=auto -ffat-lto-objects -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -fcf-protection hardening features: bindnow=no branch=yes format=yes fortify=yes pie=yes relro=yes stackclash=yes stackprotector=yes stackprotectorstrong=yes Exported for make: export LDFLAGS += -pie -Wl,-z,relro export CFLAGS := -g -O2 -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -flto=auto -ffat-lto-objects -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -fcf-protection CFLAGS += -fPIE -fstack-clash-protection -D_FORTIFY_SOURCE=2 Since configure.ac overrides the exports I have set those aren't included in the build. It would be great if those could be included. [0] https://tracker.debian.org/pkg/linux-gpib-user [1] https://sources.debian.org/src/linux-gpib-user/4.3.7-2/debian/README.source [2] https://sources.debian.org/src/linux-gpib-user/4.3.7-2/debian/patches/fix-docbook-path.diff [3] https://sources.debian.org/src/linux-gpib-user/4.3.7-2/debian/rules#L7 [4] https://codeberg.org/werdahias/python-gpib [5] https://sources.debian.org/src/linux-gpib-user/4.3.7-2/debian/rules#L26 [6] https://wiki.debian.org/Hardening -- Freundliche Grüsse / Best regards Matthias Geiger __________________________________________________________________ Matthias Geiger Werkstudent Forschung & Entwicklung/Research & Development Phone : +49-6441-609-3004 Email : m_g...@wi... URL : www.wiwa.de WIWA Wilhelm Wagner GmbH & Co. KG Gewerbestrasse 1-3, 35633 Lahnau, Germany Besucheranschrift/visitor address: Georg-Ohm-Strasse 12, 35633 Lahnau, Germany AG WETZLAR HRA 3223, Komplementär : Wagner GmbH (AG Wetzlar HRB 363) UST-ID Nr: / VAT-No: DE113745802 Geschäftsführer: Dipl.-Ing. (FH) Peter Turczak, Dipl.-Wirt.-Ing. Malte Weber |