SPVM::Builder::API(3)
π NAME π
okay so this page is for SPVM::Builder::API β literally Builder APIs, bestie β and it lives in the User Contributed Perl Documentation manual, section 3. π
πΈ DESCRIPTION πΈ
The SPVM::Builder::API class has the public methods to build SPVM native classes and SPVM precompilation classes. That's the whole flex. β¨
π§ USAGE π§
Here's the vibe check β this is how you use it:
my $builder = SPVM::Builder::API->new(
build_dir => '.spvm_build',
);
$builder->build_dynamic_lib_dist_precompile('MyClass');
$builder->build_dynamic_lib_dist_native('MyClass');
π CLASS METHODS π
π¦ new π¦
my $builder = SPVM::Builder::API->new(%options);
Creates a new SPVM::Builder::API object, and returns it. Slay. π
Options:
"build_dir"β a build directory."optimize"β the optimization level for the compiler.
π INSTANCE METHODS π
π build_dynamic_lib_dist_precompile π
$builder->build_dynamic_lib_dist_precompile($class_name)
$builder->build_dynamic_lib_dist_precompile($class_name, $options)
Generates a dynamic library for a native class given by the class name $class_name, and copies it into the "blib/lib" directory. A native class must have at least one method with the native attribute. π«Ά
Options: $options is a hash reference. This is optional.
"force"β if this option is a true value, the compilation and link are forced. π₯
π¦ build_dynamic_lib_dist_native π¦
$builder->build_dynamic_lib_dist_native($class_name)
$builder->build_dynamic_lib_dist_native($class_name, $options)
Generates a dynamic library for a precompilation class $class_name that has "native" methods, and copies it into the "blib/lib" directory. A precompilation class must have at least one method with the precompile attribute. π
Options: $options is a hash reference. This is optional.
"force"β if this option is a true value, the compilation and link are forced. π₯
later, bestie π β this page is from perl v5.42.2, dated 2026-02-03, and its label is SPVM::Builder::API(3). mwah π
π¦ where this page comes from
- alpine 3.24: spvm-doc 0.990125-r0 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms