smi_macro(3)
hey bestie π welcome to smi_macro(3) β manual name: SMI Management Information Library. this page is all about macro/extension info, and itβs lowkey iconic β¨
β¨ NAME β¨
smiGetMacro, smiGetFirstMacro, smiGetNextMacro, smiGetMacroModule β the SMI macro and extension information routines π
πΈ SYNOPSIS πΈ
ok so first you include the header, then the function signatures and the struct show up like:
#include <smi.h>
SmiMacro *smiGetMacro(SmiModule *smiModulePtr, char *macro);
SmiMacro *smiGetFirstMacro(SmiModule *smiModulePtr);
SmiMacro *smiGetNextMacro(SmiMacro *smiMacroPtr);
SmiModule *smiGetMacroModule(SmiMacro *smiMacroPtr);
typedef struct SmiMacro {
SmiIdentifier name;
SmiDecl decl;
SmiStatus status;
char *description;
char *reference;
} SmiMacro;
π DESCRIPTION π
These functions retrieve information on an extension statement definition (SMIng) or a macro (SMIv1/v2) β thatβs the vibe β
smiGetMacro()β retrieves astruct SmiMacrothat represents an extension or macro definition. Themacroargument can be either a fully qualified descriptor or a simple macro or extension name. IfsmiModulePtris notNULL, itβs used to limit the search to the given module. If the macro is not found,smiGetMacro()returnsNULLπsmiGetFirstMacro()andsmiGetNextMacro()β use these to iteratively retrievestruct SmiMacros.smiGetFirstMacro()returns the first one defined in the module specified bysmiModulePtr; subsequent calls tosmiGetNextMacro()return the following ones. If there are no more extension or macro definitions in the module,NULLis returned π«ΆsmiGetMacroModule()β returns the module that defines the macro or extension given bystruct SmiMacroPtrπ
π FILES π
${prefix}/include/smi.hβ SMI library header file. yes bestie, thatβs where the header lives π
π₯ SEE ALSO π₯
libsmi(3)smi_module(3)smi.h
go check these out, iykyk πβ¨
π AUTHOR π
(C) 1999-2001 Frank Strauss, TU Braunschweig, Germany <strauss@ibr.cs.tu-bs.de>β iconic authorship behavior π
xoxo, source/version IBR, date August 16, 2001 β catch u in smi_macro(3) π
π
π¦ where this page comes from
- alpine 3.24: libsmi-doc 0.5.0-r5 Β· BSD-3-Clause AND MIT
- nixos 26.05: libsmi 0.5.0
- nixpkgs unstable: libsmi 0.5.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms