From 0ceee5ec652ce4e45d74281b1a869687e6c088b9 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Tue, 19 Aug 2014 10:31:12 +1000 Subject: [PATCH] Add some minimal documentation about static linking I can't recommend it, but I can't stop people from doing it, so at least document the ground rules. Signed-off-by: Peter Hutterer --- libevdev/libevdev.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/libevdev/libevdev.h b/libevdev/libevdev.h index 321f980..afc1d13 100644 --- a/libevdev/libevdev.h +++ b/libevdev/libevdev.h @@ -540,6 +540,20 @@ extern "C" { * @include linux/input.h */ +/** + * @page static_linking Statically linking libevdev + * + * Statically linking libevdev.a is not recommended. Symbol visibility is + * difficult to control in a static library, so extra care must be taken to + * only use symbols that are explicitly exported. libevdev's API stability + * guarantee only applies to those symbols. + * + * If you do link libevdev statically, note that in addition to the exported + * symbols, libevdev reserves the _libevdev_* namespace. Do not use + * or create symbols with that prefix, they are subject to change at any + * time. + */ + /** * @page testing libevdev-internal test suite * -- 2.34.1