[v3,1/6] doc: update guide on versioning macros

Message ID 1740083508-6703-2-git-send-email-andremue@linux.microsoft.com (mailing list archive)
State Changes Requested
Delegated to: David Marchand
Headers
Series mbuf: enable to be compiled with MSVC |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Andre Muezerie Feb. 20, 2025, 8:31 p.m. UTC
Added explanation about new macro MAP_STATIC_BASE_SYMBOL.

Signed-off-by: Andre Muezerie <andremue@linux.microsoft.com>
---
 doc/guides/contributing/abi_versioning.rst | 6 ++++++
 1 file changed, 6 insertions(+)
  

Patch

diff --git a/doc/guides/contributing/abi_versioning.rst b/doc/guides/contributing/abi_versioning.rst
index 7afd1c1886..1179445da3 100644
--- a/doc/guides/contributing/abi_versioning.rst
+++ b/doc/guides/contributing/abi_versioning.rst
@@ -151,6 +151,11 @@  The macros exported are:
   fully qualified function ``p``, so that if a symbol becomes versioned, it
   can still be mapped back to the public symbol name.
 
+* ``MAP_STATIC_BASE_SYMBOL(b, p)``: Declare the base symbol ``b``, and map it
+  to the fully qualified function ``p``, so that if a symbol becomes versioned,
+  it can still be mapped back to the public symbol name. Used for compatibility
+  with MSVC.
+
 * ``__vsym``:  Annotation to be used in a declaration of the internal symbol
   ``be`` to signal that it is being used as an implementation of a particular
   version of symbol ``b``.
@@ -397,6 +402,7 @@  defined, we add this
         ...
    }
    MAP_STATIC_SYMBOL(struct rte_acl_ctx *rte_acl_create(const struct rte_acl_param *param, int debug), rte_acl_create_v22);
+   MAP_STATIC_BASE_SYMBOL(rte_acl_create, rte_acl_create_v22);
 
 That tells the compiler that, when building a static library, any calls to the
 symbol ``rte_acl_create`` should be linked to ``rte_acl_create_v22``