SPVM::B...LinkInfo(3)

πŸ“¦ version 0.990125, in alpine 3.24

πŸ’– NAME πŸ’–

okay so this is SPVM::B...LinkInfo(3) from the User Contributed Perl Documentation β€” SPVM::Builder::LinkInfo, aka Linker Information ✨.

🌸 DESCRIPTION 🌸

The SPVM::Builder::LinkInfo class has methods to manipulate linker information. That's the whole vibe, bestie πŸ’….

✨ USAGE ✨

Use it like this:

my $link_info = SPVM::Builder::LinkInfo->new(%fields);
my $link_command = $link_info->to_command;

πŸŽ€ FIELDS πŸŽ€

These are the fields, and every single one matters πŸ’–.

πŸ“ config

my $config = $link_info->config;
$link_info->config($config);

Gets and sets the config field, an SPVM::Builder::Config object. Iconic.

πŸ“ output_file

my $output_file = $link_info->output_file;
$link_info->output_file($output_file);

Gets and sets the output_file field, an output file. Literally the output file.

πŸ“ object_files

my $object_files = $link_info->object_files;
$link_info->object_files($object_files);

Gets and sets the object_files field, an array reference of SPVM::Builder::ObjectFileInfo objects. Array ref energy.

πŸ“ no_generate

my $no_generate = $link_info->no_generate;
$link_info->no_generate($no_generate);

Gets and sets the no_generate field. If this field is a true value, the output file is not generated. So if it's true, no output file gets generated β€” periodt.

πŸ’… CLASS METHODS πŸ’…

πŸ¦‹ new

my $link_info = SPVM::Builder::LinkInfo->new(%fields);

Creates a new SPVM::Builder::LinkInfo object given Fields. Fresh object, fresh vibes.

Field Default Values:

  • output_file β€” undef
  • object_files β€” []
  • no_generate β€” undef

Exceptions:

The config field must be defined. No cap, config has to be there πŸ’€.

πŸ”₯ INSTANCE METHODS πŸ”₯

🌈 create_command

my $link_command = $link_info->create_command;

Creates an array reference of the link command, and returns it. Command-building main character energy.

Return Value Examples:

[qw(cc -o dylib.so foo.o bar.o -shared -O2 -Llibdir -lz)]

🌈 create_ldflags

my $ldflags = $link_info->create_ldflags;

Creates an array reference of the linker options, and returns it.

The output file output_file and the object files object_files are not contained.

Return Value Examples:

[qw(-shared -O2 -Llibdir -lz)]

🌈 to_command

my $link_command_string = $link_info->to_command;

Joins all elements of the return value of the create_command method with a space, and returns it. String-joining slay.

Return Value Examples:

"cc -o dylib.so foo.o bar.o -shared -O2 -Llibdir -lz"

Copyright (c) 2023 Yuki Kimoto

MIT License


That’s the whole page, bestie: generated from perl v5.42.2, dated 2026-02-03 β€” go slay your linking 🫢✨

πŸ“¦ where this page comes from