Debian Codegraph @

upstream/mageia-cauldron/man3pm/ExtUtils::Mksymlists.3pm

raw
1 .\" -*- mode: troff; coding: utf-8 -*-
2 .\" Automatically generated by Pod::Man v6.0.2 (Pod::Simple 3.45)
3 .\"
4 .\" Standard preamble:
5 .\" ========================================================================
6 .de Sp \" Vertical space (when we can't use .PP)
7 .if t .sp .5v
8 .if n .sp
9 ..
10 .de Vb \" Begin verbatim text
11 .ft CW
12 .nf
13 .ne \\$1
14 ..
15 .de Ve \" End verbatim text
16 .ft R
17 .fi
18 ..
19 .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>.
20 .ie n \{\
21 . ds C` ""
22 . ds C' ""
23 'br\}
24 .el\{\
25 . ds C`
26 . ds C'
27 'br\}
28 .\"
29 .\" Escape single quotes in literal strings from groff's Unicode transform.
30 .ie \n(.g .ds Aq \(aq
31 .el .ds Aq '
32 .\"
33 .\" If the F register is >0, we'll generate index entries on stderr for
34 .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
35 .\" entries marked with X<> in POD. Of course, you'll have to process the
36 .\" output yourself in some meaningful fashion.
37 .\"
38 .\" Avoid warning from groff about undefined register 'F'.
39 .de IX
40 ..
41 .nr rF 0
42 .if \n(.g .if rF .nr rF 1
43 .if (\n(rF:(\n(.g==0)) \{\
44 . if \nF \{\
45 . de IX
46 . tm Index:\\$1\t\\n%\t"\\$2"
47 ..
48 . if !\nF==2 \{\
49 . nr % 0
50 . nr F 2
51 . \}
52 . \}
53 .\}
54 .rr rF
55 .\"
56 .\" Required to disable full justification in groff 1.23.0.
57 .if n .ds AD l
58 .\" ========================================================================
59 .\"
60 .IX Title "ExtUtils::Mksymlists 3pm"
61 .TH ExtUtils::Mksymlists 3pm 2025-06-24 "perl v5.42.0" "Perl Programmers Reference Guide"
62 .\" For nroff, turn off justification. Always turn off hyphenation; it makes
63 .\" way too many mistakes in technical documents.
64 .if n .ad l
65 .nh
66 .SH NAME
67 ExtUtils::Mksymlists \- write linker options files for dynamic extension
68 .SH SYNOPSIS
69 .IX Header "SYNOPSIS"
70 .Vb 5
71 \& use ExtUtils::Mksymlists;
72 \& Mksymlists( NAME => $name ,
73 \& DL_VARS => [ $var1, $var2, $var3 ],
74 \& DL_FUNCS => { $pkg1 => [ $func1, $func2 ],
75 \& $pkg2 => [ $func3 ] );
76 .Ve
77 .SH DESCRIPTION
78 .IX Header "DESCRIPTION"
79 \&\f(CW\*(C`ExtUtils::Mksymlists\*(C'\fR produces files used by the linker under some OSs
80 during the creation of shared libraries for dynamic extensions. It is
81 normally called from a MakeMaker\-generated Makefile when the extension
82 is built. The linker option file is generated by calling the function
83 \&\f(CW\*(C`Mksymlists\*(C'\fR, which is exported by default from \f(CW\*(C`ExtUtils::Mksymlists\*(C'\fR.
84 It takes one argument, a list of key\-value pairs, in which the following
85 keys are recognized:
86 .IP DLBASE 4
87 .IX Item "DLBASE"
88 This item specifies the name by which the linker knows the
89 extension, which may be different from the name of the
90 extension itself (for instance, some linkers add an \*(Aq_\*(Aq to the
91 name of the extension). If it is not specified, it is derived
92 from the NAME attribute. It is presently used only by OS2 and Win32.
93 .IP DL_FUNCS 4
94 .IX Item "DL_FUNCS"
95 This is identical to the DL_FUNCS attribute available via MakeMaker,
96 from which it is usually taken. Its value is a reference to an
97 associative array, in which each key is the name of a package, and
98 each value is an a reference to an array of function names which
99 should be exported by the extension. For instance, one might say
100 \&\f(CW\*(C`DL_FUNCS => { Homer::Iliad => [ qw(trojans greeks) ],
101 Homer::Odyssey => [ qw(travellers family suitors) ] }\*(C'\fR. The
102 function names should be identical to those in the XSUB code;
103 \&\f(CW\*(C`Mksymlists\*(C'\fR will alter the names written to the linker option
104 file to match the changes made by \fIxsubpp\fR. In addition, if
105 none of the functions in a list begin with the string \fBboot_\fR,
106 \&\f(CW\*(C`Mksymlists\*(C'\fR will add a bootstrap function for that package,
107 just as xsubpp does. (If a \fBboot_<pkg>\fR function is
108 present in the list, it is passed through unchanged.) If
109 DL_FUNCS is not specified, it defaults to the bootstrap
110 function for the extension specified in NAME.
111 .IP DL_VARS 4
112 .IX Item "DL_VARS"
113 This is identical to the DL_VARS attribute available via MakeMaker,
114 and, like DL_FUNCS, it is usually specified via MakeMaker. Its
115 value is a reference to an array of variable names which should
116 be exported by the extension.
117 .IP FILE 4
118 .IX Item "FILE"
119 This key can be used to specify the name of the linker option file
120 (minus the OS\-specific extension), if for some reason you do not
121 want to use the default value, which is the last word of the NAME
122 attribute (\fIe.g.\fR for \f(CW\*(C`Tk::Canvas\*(C'\fR, FILE defaults to \f(CW\*(C`Canvas\*(C'\fR).
123 .IP FUNCLIST 4
124 .IX Item "FUNCLIST"
125 This provides an alternate means to specify function names to be
126 exported from the extension. Its value is a reference to an
127 array of function names to be exported by the extension. These
128 names are passed through unaltered to the linker options file.
129 Specifying a value for the FUNCLIST attribute suppresses automatic
130 generation of the bootstrap function for the package. To still create
131 the bootstrap name you have to specify the package name in the
132 DL_FUNCS hash:
133 .Sp
134 .Vb 3
135 \& Mksymlists( NAME => $name ,
136 \& FUNCLIST => [ $func1, $func2 ],
137 \& DL_FUNCS => { $pkg => [] } );
138 .Ve
139 .IP IMPORTS 4
140 .IX Item "IMPORTS"
141 This attribute is used to specify names to be imported into the
142 extension. It is currently only used by OS/2 and Win32.
143 .IP NAME 4
144 .IX Item "NAME"
145 This gives the name of the extension (\fIe.g.\fR \f(CW\*(C`Tk::Canvas\*(C'\fR) for which
146 the linker option file will be produced.
147 .PP
148 When calling \f(CW\*(C`Mksymlists\*(C'\fR, one should always specify the NAME
149 attribute. In most cases, this is all that\*(Aqs necessary. In
150 the case of unusual extensions, however, the other attributes
151 can be used to provide additional information to the linker.
152 .SH AUTHOR
153 .IX Header "AUTHOR"
154 Charles Bailey \fI<[email protected]>\fR
155 .SH REVISION
156 .IX Header "REVISION"
157 Last revised 14\-Feb\-1996, for Perl 5.002.