1XSBuilder::ParseSource(U3s)er Contributed Perl DocumentatXiSoBnuilder::ParseSource(3)
2
3
4
6 ExtUtils::XSBuilder::ParseSource - parse C source files
7
8 DESCRIPTION
9
10 For more information, see ExtUtils::XSBuilder
11
12 extent_parser (o)
13
14 Allows the user to call the Extent or Replace method of the parser to
15 add new syntax rules. This is mainly useful to include expansions for
16 preprocessor macros.
17
18 preprocess (o)
19
20 Allows the user to preprocess the source before it is given to the
21 parser. You may modify the source, which is given as first argument in
22 place.
23
24 include_dirs (o)
25
26 Returns a reference to the list of directories that should be searched
27 for include files which contain the functions, structures, etc. to be
28 extracted.
29
30 Default: '.'
31
32 include_paths (o)
33
34 Returns a reference to a list of directories that are given as include
35 directories to the C compiler. This is mainly used to strip these
36 directories from filenames to convert absolute paths to relative paths.
37
38 Default: empty list ("[]")
39
40 unwanted_includes (o)
41
42 Returns a reference to a list of include files that should not be pro‐
43 cessed.
44
45 Default: empty list ("[]")
46
47 sort_includes (o, include_list)
48
49 Passed an array ref of include files, it allows the user to define the
50 sort order, so includes are processed correctly.
51
52 Default: return the passed array reference.
53
54 find_includes (o)
55
56 Returns a list of include files to be processed.
57
58 Default: search directories given by "include_dirs" for all files and
59 build a list of include files. All files starting with a word matched
60 by "unwanted_includes" are not included in the list.
61
62 handle_define (o)
63
64 Passed a hash ref with the definition of a define, may modify it.
65 Return false to discard it, return true to keep it.
66
67 Default: 1
68
69 handle_enum (o)
70
71 Passed a hash ref with the definition of a enum value, may modify it.
72 Return false to discard it, return true to keep it.
73
74 Default: 1
75
76 handle_struct (o)
77
78 Passed a hash ref with the definition of a struct, may modify it.
79 Return false to discard it, return true to keep it.
80
81 Default: 1
82
83 handle_function (o)
84
85 Passed a hash ref with the definition of a function, may modify it.
86 Return false to discard it, return true to keep it.
87
88 Default: 1
89
90 handle_callback (o)
91
92 Passed a hash ref with the definition of a callback, may modify it.
93 Return false to discard it, return true to keep it.
94
95 Default: 1
96
97 package (o)
98
99 Return package name for tables
100
101 Default: 'MY'
102
103 targetdir (o)
104
105 Return name of target directory where to write tables
106
107 Default: './xsbuilder/tables'
108
109 run
110
111 Call this class method to parse your source. Before you can do so you
112 must provide a class that overrides the defaults in ExtU‐
113 tils::XSBuilder::ParseSource. After that you scan the source files with
114
115 MyClass -> run ;
116
117
118
119perl v5.8.8 2005-08-31 XSBuilder::ParseSource(3)