5.1 Where enforcement does exist

When you compile a library into a module with the Separate Namespace option — an AutoCAD ‘.vlx’ built by the Make Application wizard (Expert mode; the settings live in the ‘.prv’ file), or a BricsCAD DES-encrypted file with the VLX-NameSpace feature (DEScoder v2.7+ / BricsCAD V18.2 and later) — the module’s functions are hidden from the loading document, except those published at load time by top-level ‘(vl-doc-export 'name)’ calls inside the module.

ALPM generates those calls from your declaration. Declare where the generated file lives by listing it as a file of the system with ‘generated-exports T’:

files ("points"
       (file "lines" depends-on ("points"))
       (file "geometry-exports" generated-exports T
             depends-on ("points" "lines")))

then

(alpm-generate-exports-file "geometry" nil)

(re)writes that file with one guarded ‘(if vl-doc-export (vl-doc-export 'geo-make-point))’ per exported name, and it is loaded at its declared position like any other file — and listed like any other file when the sources are compiled into a module (‘.prj’ / DEScoder project), which is what makes the exports take effect there. Loaded as plain source, the file is harmless on every engine. Without a ‘generated-exports’ file spec, the file is written as ‘geometry-exports.lsp’ next to the sources but never added to a plan behind your back.

If your existing sources already contain inline ‘vl-doc-export’ calls, keep them: declare the same names in ‘exports’ and ‘alpm-check-exports’ will keep declaration and code in sync.