TS_LIBVERSION(3)
π TS_LIBVERSION(3) β the tslib girlies' guide to peeping your version π
okay bestie, so this is a page from the tslib manual, section 3 (that's the library-functions section, iykyk). it's short, it's sweet, it's literally just "how do i find out what version of tslib i'm running" and honestly? iconic behaviour.
β¨ NAME β¨
ts_libversion β get version information on the currently running tslib π«Ά
πΈ SYNOPSIS πΈ
#include <tslib.h>
struct ts_lib_version_data *ts_libversion();
like, that's it. no arguments. she takes nothing and gives you everything π
π¦ DESCRIPTION π¦
ts_libversion() β okay so what this does is it returns a pointer to a static copy of the version info struct. static. as in, don't you dare try to free it, she lives there rent-free forever.
and the struct? the struct is giving:
struct ts_lib_version_data {
const char *package_version;
int version_num;
unsigned int features;
};
let's break her down, one field at a time, no cap:
package_versionβ just a string with the tarball release number in it. like, for example"1.10". that's the whole vibe. a string. a little release-number string. πversion_numβ this one's the math girlie. it's a 24 bit number built like this:<8 bits major number> | <8 bits minor number> | <8 bits patch number>β and all of that is of the librarylibts. so version0.7.1? that gets returned as0x000701. cute right? bit-shifted into one single int. she's efficient. she's compact. she's slaying. βfeaturesβ this is the bitmask, bestie, and it can have one or more bits set. the bits that are currently defined are:TSLIB_VERSION_MTβ tslib filters support multitouchts_read_mt()and there is at least one raw access module supporting it (currentlyevdevinput). multitouch era fr fr π₯TSLIB_VERSION_OPEN_RESTRICTEDβts_open_restrictedandts_close_restrictedfunction pointers are available to implementTSLIB_VERSION_EVENTPATHβts_get_eventpath()is available since tslib can auto-detect a device πTSLIB_VERSION_VERSIONβ simpletslib_version()andts_print_ascii_logo()are available π
not me noticing the descriptions in the original just kind of... run into each other π that's the source material though, so we're keeping every word of it, exactly as it is. no editing, no guessing, no adding.
π RETURN VALUE π
she returns a pointer to a static copy of the version info struct. that's the answer. that's the whole answer. pointer. static. version info struct. periodt. π
π SEE ALSO π
go read those next, bestie, they're part of the same little family π«Ά
and that's the page!! brought to you by the tslib manual, section 3, TS_LIBVERSION(3) β mwah, go check your version numbers, you're doing amazing, ily, bye πβ¨
π¦ where this page comes from
- alpine 3.24: tslib-doc 1.24-r0 Β· LGPL-2.0-or-later
- arch rolling: tslib 1.24-1 Β· LGPL-2.1-only
- debian bookworm: libts0 1.22-1+b1 Β· LGPL-2.0-or-later
- debian trixie: libts0t64 1.22-1.1+b1 Β· LGPL-2.0-or-later
- epel 10: tslib 1.23-2.el10_2 Β· LGPL-2.1-only
- epel 9: tslib 1.22-5.el9 Β· LGPLv2
- fedora 43: tslib 1.23-2.fc43 Β· LGPL-2.1-only
- fedora 43: tslib 1.23-2.fc43 Β· LGPL-2.1-only
- fedora 44: tslib 1.24-2.fc44 Β· LGPL-2.1-only
- fedora 44: tslib 1.24-2.fc44 Β· LGPL-2.1-only
- nixos 26.05: tslib 1.24
- nixpkgs unstable: tslib 1.24
- opensuse-leap 16.0: tslib 1.22-160000.2.2 Β· LGPL-2.1-or-later AND GPL-2.0-only
- opensuse-leap 16.0: tslib 1.22-160000.2.2 Β· LGPL-2.1-or-later AND GPL-2.0-only
- opensuse-leap 16.0: tslib 1.22-160000.2.2 Β· LGPL-2.1-or-later AND GPL-2.0-only
- opensuse-leap 16.0: tslib 1.22-160000.2.2 Β· LGPL-2.1-or-later AND GPL-2.0-only
- ubuntu jammy: libts0 1.22-1 Β· LGPL-2.0-or-later
- ubuntu noble: libts0t64 1.22-1.1build1 Β· LGPL-2.0-or-later
- ubuntu questing: libts0t64 1.22-1.1build1
- ubuntu resolute: libts0t64 1.22-1.1build2 Β· LGPL-2.0-or-later
- ubuntu stonking: libts0t64 1.22-1.1build2 Β· LGPL-2.0-or-later
- Copyright (c) 2017, Martin Kepplinger <martink@posteo.de>
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms