Skip to content
This repository was archived by the owner on May 1, 2026. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 11 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@ acceleration where the underlying algorithms admit it.

## Status

Early development. The public API and ABI are unstable until 1.0.
**1.0.0** — public API and ABI are stable. SONAME is `libksuid.so.1`;
subsequent 1.x releases stay binary-compatible (semver). A breaking
ABI change would require a 2.0 with a new SONAME.

## Goals

Expand Down Expand Up @@ -68,9 +70,14 @@ A release build on x86_64 produces (post-`strip --strip-unneeded`):

| Artifact | Bytes |
| :------------------ | -----: |
| libksuid.so.0.1.0 | 18 560 |
| libksuid.a | 24 804 |
| ksuid-gen (CLI) | 27 464 |
| libksuid.so.1.0.0 | 26 752 |
| libksuid.a | 35 212 |
| ksuid-gen (CLI) | 22 920 |

The bulk-encode AVX2 kernel from `libksuid/encode_avx2.c` accounts for
roughly 8 KB of the shared-library size; non-AVX2 hosts compile and
link the kernel but never call into it, so the CPUID-gated dispatch
adds no runtime cost to those targets.

The shared library has zero runtime dependencies beyond the C library
and, on Windows, `bcrypt.lib`.
Expand Down
7 changes: 5 additions & 2 deletions meson.build
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
project('libksuid', 'c',
version : '0.1.0',
version : '1.0.0',
license : 'LGPL-3.0-or-later AND MIT',
meson_version : '>=1.1.0',
default_options : [
Expand Down Expand Up @@ -237,7 +237,10 @@ ksuid_lib = both_libraries('ksuid', core_sources,
dependencies : extra_link_deps,
link_whole : avx2_lib_dep,
version : meson.project_version(),
soversion : '0',
# soversion tracks semver major: a major bump means a binary-
# incompatible ABI break and the SONAME flips with it. 1.0 is the
# first stable ABI commitment.
soversion : '1',
install : true,
)

Expand Down
6 changes: 3 additions & 3 deletions tests/test_smoke.c
Original file line number Diff line number Diff line change
Expand Up @@ -88,10 +88,10 @@ test_version_macros_are_consistent (void)
*
* When you bump meson.build's project version you MUST update
* these four asserts in the same commit. */
ASSERT_EQ_INT (KSUID_VERSION_MAJOR, 0);
ASSERT_EQ_INT (KSUID_VERSION_MINOR, 1);
ASSERT_EQ_INT (KSUID_VERSION_MAJOR, 1);
ASSERT_EQ_INT (KSUID_VERSION_MINOR, 0);
ASSERT_EQ_INT (KSUID_VERSION_PATCH, 0);
ASSERT_EQ_STR (KSUID_VERSION_STRING, "0.1.0");
ASSERT_EQ_STR (KSUID_VERSION_STRING, "1.0.0");

/* The composite KSUID_VERSION must equal the documented
* (MAJOR << 16) | (MINOR << 8) | PATCH layout for `#if
Expand Down
Loading