Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 693 lines (450 sloc) 16.269 kb
3ace369 @particle #39826: [CAGE] convert C<perl -w> to C<use warnings;>
particle authored
1 #! perl
29b08db @bschmalhofer Require Perl 5.6.0, not 5.8.0, in Configure.pl.
bschmalhofer authored
2
110c52f @allisonrandal [build] Add a --disable-rpath option to allow Linux packagers to build
allisonrandal authored
3 # Copyright (C) 2001-2009, Parrot Foundation.
11b744f @simoncozens Configure system from Brent Dax <brentdax@cpan.org>
simoncozens authored
4
dc40427 @coke [codingstd] require version in a way that avoids a complaint from per…
coke authored
5 use 5.008;
3477cc0 @jkeenan Applying patch submitted in
jkeenan authored
6 use strict;
7 use warnings;
8 use lib 'lib';
9
10 use Parrot::Configure;
11 use Parrot::Configure::Options qw( process_options );
12 use Parrot::Configure::Options::Test;
a725b2f @jkeenan Refactor preparatory code found in lib/Parrot/Configure/Options/Test.…
jkeenan authored
13 use Parrot::Configure::Options::Test::Prepare qw(
14 get_preconfiguration_tests
15 get_postconfiguration_tests
16 );
3477cc0 @jkeenan Applying patch submitted in
jkeenan authored
17 use Parrot::Configure::Messages qw(
18 print_introduction
19 print_conclusion
20 );
b65b944 @NotFound Update .parrot_current_rev in Configure if possible
NotFound authored
21 use Parrot::Revision;
3477cc0 @jkeenan Applying patch submitted in
jkeenan authored
22
23 $| = 1; # $OUTPUT_AUTOFLUSH = 1;
24
25 # Install Option text was taken from:
26 #
27 # autoconf (GNU Autoconf) 2.59
28 # Written by David J. MacKenzie and Akim Demaille.
29 #
30 # Copyright (C) 2003 Free Software Foundation, Inc.
31 # This is free software; see the source for copying conditions. There is NO
32 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
33
34 # from Parrot::Configure::Options
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
35 my ($args, $steps_list_ref) = process_options(
3477cc0 @jkeenan Applying patch submitted in
jkeenan authored
36 {
468e958 @jkeenan Check for whether $ARGV[0] to avoid uninitialized value warning when …
jkeenan authored
37 mode => (defined $ARGV[0] and $ARGV[0] =~ /^--file=/)
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
38 ? 'file'
39 : 'configure',
3477cc0 @jkeenan Applying patch submitted in
jkeenan authored
40 argv => [@ARGV],
41 }
42 );
43 exit(1) unless defined $args;
44
be71d13 @rurban [GH #833] preload configure steps
rurban authored
45 # preload all steps for debugging because some Windows systems cannot
46 # do "b postpone stepname"
c4de4b4 @rurban [GH #833] preload only when debugging perl via -d
rurban authored
47 if (defined &DB::DB) {
48 for my $step_name (@{ $steps_list_ref } ) {
9f58d2f @rurban [codingstd] tabs in Configure.PL
rurban authored
49 eval "use $step_name;"; ## no critic (BuiltinFunctions::ProhibitStringyEval)
50 die $@ if $@;
c4de4b4 @rurban [GH #833] preload only when debugging perl via -d
rurban authored
51 }
be71d13 @rurban [GH #833] preload configure steps
rurban authored
52 }
53
3477cc0 @jkeenan Applying patch submitted in
jkeenan authored
54 my $opttest = Parrot::Configure::Options::Test->new($args);
55
56 # configuration tests will only be run if you requested them
57 # as command-line option
a725b2f @jkeenan Refactor preparatory code found in lib/Parrot/Configure/Options/Test.…
jkeenan authored
58 $opttest->run_configure_tests( get_preconfiguration_tests() );
3477cc0 @jkeenan Applying patch submitted in
jkeenan authored
59
60 my $parrot_version = $Parrot::Configure::Options::Conf::parrot_version;
61
62 # from Parrot::Configure::Messages
46c8406 @jkeenan Implement option of fully silent configuration.
jkeenan authored
63 print_introduction($parrot_version)
64 unless $args->{silent};
3477cc0 @jkeenan Applying patch submitted in
jkeenan authored
65
b65b944 @NotFound Update .parrot_current_rev in Configure if possible
NotFound authored
66 # Update revision number if needed
67 Parrot::Revision::update();
68
a5b614c @bschmalhofer [config]
bschmalhofer authored
69 my $conf = Parrot::Configure->new();
3477cc0 @jkeenan Applying patch submitted in
jkeenan authored
70
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
71 $conf->add_steps( @{ $steps_list_ref } );
3477cc0 @jkeenan Applying patch submitted in
jkeenan authored
72
73 # from Parrot::Configure::Data
74 $conf->options->set( %{$args} );
8963c6e @rurban [config] Enable make reconfig. RT #58034
rurban authored
75 # save the command-line for make reconfig
766efa7 @jkeenan Minor code reformatting.
jkeenan authored
76 $conf->data->set(configure_args => @ARGV
77 ? '"'.join("\" \"", map {qq($_)} @ARGV).'"'
78 : '');
3477cc0 @jkeenan Applying patch submitted in
jkeenan authored
79
47714ec @rurban vms: fix and test multi-dot filenames
rurban authored
80 # Log files created by Configure.pl in MANIFEST_configure.generated
7bb2d0e @jkeenan Applying patch submitted in
jkeenan authored
81 $conf->{active_configuration} = 1;
47714ec @rurban vms: fix and test multi-dot filenames
rurban authored
82 unlink 'MANIFEST_configure.generated';
d154d3a @jkeenan Reposition one inline comment; add another.
jkeenan authored
83
84 # Run the actual steps from Parrot::Configure
3477cc0 @jkeenan Applying patch submitted in
jkeenan authored
85 $conf->runsteps or exit(1);
86
87 # build tests will only be run if you requested them
88 # as command-line option
a725b2f @jkeenan Refactor preparatory code found in lib/Parrot/Configure/Options/Test.…
jkeenan authored
89 $opttest->run_build_tests( get_postconfiguration_tests() );
3477cc0 @jkeenan Applying patch submitted in
jkeenan authored
90
91 my $make = $conf->data->get('make');
92 # from Parrot::Configure::Messages
46c8406 @jkeenan Implement option of fully silent configuration.
jkeenan authored
93 ( print_conclusion( $conf, $make, $args ) ) ? exit 0 : exit 1;
3477cc0 @jkeenan Applying patch submitted in
jkeenan authored
94
95 ################### DOCUMENTATION ###################
96
756762f *** empty log message ***
Michael Scott authored
97 =head1 NAME
54d55b6 Patch from Nicholas Clark <nick@unfortu.net>: stops silly people
Josh Wilmes authored
98
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
99 Configure.pl - Parrot's configuration script
a3cd162 Build enhancements. Originally to support building shared libraries, …
Gregor N. Purdy authored
100
756762f *** empty log message ***
Michael Scott authored
101 =head1 SYNOPSIS
a3cd162 Build enhancements. Originally to support building shared libraries, …
Gregor N. Purdy authored
102
756762f *** empty log message ***
Michael Scott authored
103 % perl Configure.pl [options]
6d36c2d bunch of patches:
Leopold Toetsch authored
104
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
105 or:
106
107 % perl Configure.pl --file=/path/to/configuration/directives
108
756762f *** empty log message ***
Michael Scott authored
109 =head1 DESCRIPTION
a3cd162 Build enhancements. Originally to support building shared libraries, …
Gregor N. Purdy authored
110
d10b19e @petdance Perl programs are programs, not scripts
petdance authored
111 This is Parrot's configuration program. It should be run to create
112 the necessary system-specific files before building Parrot.
b4b718e Update configuration system documentation (based on patches provided …
Michael Scott authored
113
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
114 We now offer two interfaces to configuration:
115
116 =over 4
117
118 =item * Command-Line Interface
c15d8e5 Added 'reconfig' make target and corresponding --reconfig option to
Gregor N. Purdy authored
119
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
120 All configuration options are placed on the command-line. You may request
121 interactive configuration with the C<--ask> option. You may not use the
122 C<--file> option, as that is reserved for the Configuration-File interface.
c15d8e5 Added 'reconfig' make target and corresponding --reconfig option to
Gregor N. Purdy authored
123
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
124 =item * Configuration-File Interface
125
126 All configuration options are placed in a special configuration file whose
127 full path is invoked on the command-line as
128 C<--file=/path/to/configuration/directives> as the sole command-line option.
129 You may not request interactive configuration. For specific instructions, see
130 L</"CONFIGURATION-FILE INTERFACE"> below.
131
132 =back
133
134 =head2 General Options
135
136 =over 4
ad4983c add --optimize Configure option
Leopold Toetsch authored
137
756762f *** empty log message ***
Michael Scott authored
138 =item C<--help>
205f653 @brentdax Win32 compatibility, Configure hints, 5.005 compatibility, MANIFEST c…
brentdax authored
139
756762f *** empty log message ***
Michael Scott authored
140 Prints out a description of the options and exits.
ad4983c add --optimize Configure option
Leopold Toetsch authored
141
756762f *** empty log message ***
Michael Scott authored
142 =item C<--version>
0fc6ac6 @brentdax Configure.pl 2.0.
brentdax authored
143
756762f *** empty log message ***
Michael Scott authored
144 Prints out the version number of Configure.pl and exits.
c0142c7 memory allocation rework
Dan Sugalski authored
145
756762f *** empty log message ***
Michael Scott authored
146 =item C<--verbose>
c0142c7 memory allocation rework
Dan Sugalski authored
147
6f5b538 @jhoblitt podtidy configure files
jhoblitt authored
148 Tells Configure.pl to output extra information about the configuration data it
149 is setting.
c15d8e5 Added 'reconfig' make target and corresponding --reconfig option to
Gregor N. Purdy authored
150
ab81b8c @brentdax Configure output cleanup. Retasks --verbose to include the old outpu…
brentdax authored
151 =item C<--verbose=2>
152
dacbc40 ICU config patch - use systems ICU
Leopold Toetsch authored
153 Tells Configure.pl to output information about i<every> setting added or
ab81b8c @brentdax Configure output cleanup. Retasks --verbose to include the old outpu…
brentdax authored
154 changed.
155
d79c782 @jkeenan Applying patch submitted in
jkeenan authored
156 =item C<--verbose-step={N|regex}>
567c2b1 new Configure options: verbose-step
Leopold Toetsch authored
157
d79c782 @jkeenan Applying patch submitted in
jkeenan authored
158 Run C<--verbose=2> for step number C<N> or matching description.
567c2b1 new Configure options: verbose-step
Leopold Toetsch authored
159
a5e7643 @jkeenan Committing patch submitted for RT 45523 and 45525. Add --fatal and
jkeenan authored
160 =item C<--fatal>
161
162 Tells Configure.pl to halt completely if any configuration step fails.
163
164 =item C<--fatal-step={init::alpha,inter::beta,auto::gamma}>
165
166 Tells Configure.pl to halt completely if any configuration step in
167 comma-delimited string individually fails.
168
756762f *** empty log message ***
Michael Scott authored
169 =item C<--nomanicheck>
85a1fcc reenable debugging=1 default
Leopold Toetsch authored
170
756762f *** empty log message ***
Michael Scott authored
171 Tells Configure.pl not to run the MANIFEST check.
11b744f @simoncozens Configure system from Brent Dax <brentdax@cpan.org>
simoncozens authored
172
20fed4c Add a --prefix argument to Configure.pl to set the installation prefix
Nicholas Clark authored
173 =item C<--prefix>
174
175 Sets the location where parrot will be installed.
176
b4b718e Update configuration system documentation (based on patches provided …
Michael Scott authored
177 =item C<--ask>
de4d079 Add conditional configurations for testy code.
Melvin Smith authored
178
570f6d4 @jkeenan Remove configuration probe for asynchronous input/output per architec…
jkeenan authored
179 This turns on the user prompts during configuration. Available only in
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
180 Command-Line interface. Not available in Configuration-File interface.
6fba438 @simoncozens Abstract the argument and opcode packing types and functions out into
simoncozens authored
181
84c64a2 @jkeenan Applying to trunk patch submitted in RT 42690. particle requested a …
jkeenan authored
182 =item C<--test>
183
184 Run certain tests along with F<Configure.pl>:
185
186 =over 4
187
188 =item C<--test=configure>
189
190 Run tests found in F<t/configure/> I<before> beginning configuration. These
191 tests demonstrate that Parrot's configuration tools will work properly once
192 configuration has begun.
193
194 =item C<--test=build>
195
272ac52 @jkeenan Some prerequisites for successful operation of buildtools_tests are n…
jkeenan authored
196 Run tests found in F<t/steps/>, F<t/postconfigure/> and F<t/pharness>.
84c64a2 @jkeenan Applying to trunk patch submitted in RT 42690. particle requested a …
jkeenan authored
197
198 =item C<--test>
199
200 Run the tests described in C<--test=configure>, conduct configuration, then
201 run the tests described in C<--test=build>.
202
203 =back
204
52494c2 @jkeenan Merge darwin2hints branch into trunk. Functionality for detecting Fi…
jkeenan authored
205 =item C<--configure_trace>
206
207 Store the results of each configuration step in a Storable F<.sto> file on
208 disk, for later analysis by F<Parrot::Configure::Trace> methods.
209
d3bdc79 @jkeenan Add documentation for quickcover; link to Devel-Cover.
jkeenan authored
210 =item C<--coveragedir>
211
1bb6425 @pjcj Changed cover to fullcover and quickcover to cover
pjcj authored
212 In preparation for calling C<make cover> to perform coverage analysis,
d3bdc79 @jkeenan Add documentation for quickcover; link to Devel-Cover.
jkeenan authored
213 provide a user-specified directory for top level of HTML output.
214
52494c2 @jkeenan Merge darwin2hints branch into trunk. Functionality for detecting Fi…
jkeenan authored
215 =item Operating system-specific configuration options
216
217 =over 4
218
bc26b63 @darbelo Make the used hints file overridable on the Configure.pl command line.
darbelo authored
219 =item C<--hintsfile=filename>
220
221 Use filename as the hints file.
222
52494c2 @jkeenan Merge darwin2hints branch into trunk. Functionality for detecting Fi…
jkeenan authored
223 =item C<--darwin_no_fink>
224
225 On Darwin, do not probe for Fink libraries.
226
227 =item C<--darwin_no_macports>
228
229 On Darwin, do not probe for Macports libraries.
230
231 =back
232
756762f *** empty log message ***
Michael Scott authored
233 =back
a3cd162 Build enhancements. Originally to support building shared libraries, …
Gregor N. Purdy authored
234
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
235 =head2 Compile Options
9d000b4 Made the changes to figure out mask bits for various register and stack
Dan Sugalski authored
236
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
237 =over 4
19fa0d4 @tomhughes Stop Configure trying to make op_info.c and op.h as op_info.c no longer
tomhughes authored
238
756762f *** empty log message ***
Michael Scott authored
239 =item C<--debugging=0>
bc2ee1d @brentdax Minor cleanup and enhancements.
brentdax authored
240
756762f *** empty log message ***
Michael Scott authored
241 Debugging is turned on by default. Use this to disable it.
9d000b4 Made the changes to figure out mask bits for various register and stack
Dan Sugalski authored
242
82a8718 @particle config: add --parrot_is_shared option to docs
particle authored
243 =item C<--parrot_is_shared>
244
245 Link parrot dynamically.
246
2ddc05f [config] New Configure.pl option --m=32
Leopold Toetsch authored
247 =item C<--m=32>
248
fe05e8a @ambs Some enhancements on linelength.t
ambs authored
249 Create a 32-bit executable on 64-architectures like x86_64. This
fb5eae8 @jkeenan POD formatting corrections only.
jkeenan authored
250 option appends C<-m32> to compiler and linker programs and does
251 C<s/lib64/lib/g> on link flags.
2ddc05f [config] New Configure.pl option --m=32
Leopold Toetsch authored
252
253 This option is experimental. See F<config/init/defaults.pm> for more.
254
62c60b6 really speed up oo1.pasm by 2
Leopold Toetsch authored
255 =item C<--profile>
256
257 Turn on profiled compile (gcc only for now)
258
efd9dcb @paultcochrane Added --cage option. Part of patch (#39802) courtesy of Kevin Tew
paultcochrane authored
259 =item C<--cage>
260
261 [CAGE] compile includes many additional warnings
262
756762f *** empty log message ***
Michael Scott authored
263 =item C<--optimize>
9d000b4 Made the changes to figure out mask bits for various register and stack
Dan Sugalski authored
264
fb5eae8 @jkeenan POD formatting corrections only.
jkeenan authored
265 Add Perl 5's C<$Config{optimize}> to the compiler flags.
2fc8aec @bschmalhofer This patch makes it easier to compile parrot with a compiler other than
bschmalhofer authored
266
267 =item C<--optimize=flags>
268
269 Add C<flags> to the compiler flags.
756762f *** empty log message ***
Michael Scott authored
270
271 =item C<--inline>
272
273 Tell Configure that the compiler supports C<inline>.
274
275 =item C<--cc=(compiler)>
276
5792dce @jkeenan Add entry for '--cxx' to help.
jkeenan authored
277 Specify which C compiler to use.
278
279 =item C<--cxx=(compiler)>
280
281 Specify which C++ compiler to use.
756762f *** empty log message ***
Michael Scott authored
282
283 =item C<--ccflags=(flags)>
284
285 Use the given compiler flags.
286
287 =item C<--ccwarn=(flags)>
288
289 Use the given compiler warning flags.
290
291 =item C<--libs=(libs)>
292
293 Use the given libraries.
294
295 =item C<--link=(linker)>
296
297 Specify which linker to use.
298
299 =item C<--linkflags=(flags)>
300
301 Use the given linker flags
302
d716b34 @plobsing add --ar and --arflags options to Configure.pl
plobsing authored
303 =item C<--ar=(archiver)>
304
305 Specify which librarian to use for static libraries
306
307 =item C<--arflags=(flags)>
308
309 Use the given librarian flags for static libraris
310
756762f *** empty log message ***
Michael Scott authored
311 =item C<--ld=(linker)>
312
313 Specify which loader to use for shared libraries.
314
315 =item C<--ldflags=(flags)>
316
317 Use the given loader flags for shared libraries
318
110c52f @allisonrandal [build] Add a --disable-rpath option to allow Linux packagers to build
allisonrandal authored
319 =item C<--disable-rpath>
320
321 Specify that rpath should not be included in linking flags. With this
322 configuration option, you must append the library build directory
323 (usually blib/lib) to the LD_LIBRARY_PATH environment variable (or your
324 platform equivalent). This option is primarily used for building Linux
325 packages.
326
756762f *** empty log message ***
Michael Scott authored
327 =item C<--lex=(lexer)>
328
329 Specify which lexer to use.
330
331 =item C<--yacc=(parser)>
332
333 Specify which parser to use.
0846288 various patches 2
Leopold Toetsch authored
334
b4b718e Update configuration system documentation (based on patches provided …
Michael Scott authored
335 =item C<--define=val1[,val2]>
336
6f5b538 @jhoblitt podtidy configure files
jhoblitt authored
337 Generate "#define PARROT_DEF_VAL1 1" ... entries in has_header.h. Currently
338 needed to use inet_aton for systems that lack inet_pton:
b4b718e Update configuration system documentation (based on patches provided …
Michael Scott authored
339
340 --define=inet_aton
341
a4c21ab @jkeenan Applying patch supplied by bsdz in https://trac.parrot.org/parrot/tic…
jkeenan authored
342 =item C<--no-line-directives>
343
344 Disables the creation of C #line directives when generating C from PMCs and
345 ops. Useful when debugging internals.
3b2baf4 @coke Remove trailing whitespace
coke authored
346
b4b718e Update configuration system documentation (based on patches provided …
Michael Scott authored
347 =back
348
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
349 =head2 Parrot Options
b4b718e Update configuration system documentation (based on patches provided …
Michael Scott authored
350
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
351 =over 4
b4b718e Update configuration system documentation (based on patches provided …
Michael Scott authored
352
756762f *** empty log message ***
Michael Scott authored
353 =item C<--intval=(type)>
354
355 Use the given type for C<INTVAL>.
356
357 =item C<--floatval=(type)>
358
359 Use the given type for C<FLOATVAL>.
360
361 =item C<--opcode=(type)>
362
363 Use the given type for opcodes.
364
365 =item C<--ops=(files)>
366
367 Use the given ops files.
368
5a9e89c [PATCH] runConfigureICU usage
Leopold Toetsch authored
369 =back
370
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
371 =head2 International Components For Unicode (ICU) Options
5a9e89c [PATCH] runConfigureICU usage
Leopold Toetsch authored
372
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
373 =over 4
5a9e89c [PATCH] runConfigureICU usage
Leopold Toetsch authored
374
acf4fa4 autodetect and use system icu installations
Jens Rieks authored
375 =item C<--icu-config=/path/to/icu-config>
376
73ba72d [perl #36057] [PATCH] Fix some typos - 5
Leopold Toetsch authored
377 Use the specified icu-config script to determine the necessary ICU options.
acf4fa4 autodetect and use system icu installations
Jens Rieks authored
378
6f5b538 @jhoblitt podtidy configure files
jhoblitt authored
379 Use --icu-config=none to disable the autodetect feature. Parrot will then be
380 build without ICU.
acf4fa4 autodetect and use system icu installations
Jens Rieks authored
381
6f5b538 @jhoblitt podtidy configure files
jhoblitt authored
382 B<Note:> If you specify another ICU option than --icu-config, the autodetection
383 functionality will be disabled.
a194975 - removed error message if icu-config does not exists
Jens Rieks authored
384
dacbc40 ICU config patch - use systems ICU
Leopold Toetsch authored
385 =item C<--icushared=(linkeroption)>
386
5ec035c Config cleanup - icu
Leopold Toetsch authored
387 Linker command to link against ICU library.
dacbc40 ICU config patch - use systems ICU
Leopold Toetsch authored
388
389 E.g.
390
391 --icushared='-L /opt/openoffice/program -licudata -licuuc'
392
393 (The libs in openoffice are actually version 2.2 and do not work)
394
395 =item C<--icuheaders=(header_dir)>
396
6f5b538 @jhoblitt podtidy configure files
jhoblitt authored
397 Location of ICU header files without the /unicode suffix.
dacbc40 ICU config patch - use systems ICU
Leopold Toetsch authored
398
399 E.g.
400
401 --icuheaders='/home/lt/icu/'
402
756762f *** empty log message ***
Michael Scott authored
403 =back
404
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
405 =head2 Other Options
205f653 @brentdax Win32 compatibility, Configure hints, 5.005 compatibility, MANIFEST c…
brentdax authored
406
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
407 =over 4
a3cd162 Build enhancements. Originally to support building shared libraries, …
Gregor N. Purdy authored
408
b4b718e Update configuration system documentation (based on patches provided …
Michael Scott authored
409 =item C<--maintainer>
43a606a This patch allows parrot to mostly-build with tcc. It allows one to …
Dan Sugalski authored
410
6f5b538 @jhoblitt podtidy configure files
jhoblitt authored
411 Use this option if you want imcc's parser and lexer files to be generated.
412 Needs a working parser and lexer.
9d000b4 Made the changes to figure out mask bits for various register and stack
Dan Sugalski authored
413
370a418 @cotto Introduce --with-llvm option to explicitly link to LLVM
cotto authored
414 =item C<--with-llvm>
415
416 Use this option if you have a recent version of LLVM installed and wish Parrot
417 to link to it.
418
0fc6ac6 @brentdax Configure.pl 2.0.
brentdax authored
419 =back
a3cd162 Build enhancements. Originally to support building shared libraries, …
Gregor N. Purdy authored
420
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
421 =head1 CONFIGURATION-FILE INTERFACE
422
423 In the Configuration-File interface, unlike the Command-Line interface, you
424 may delete configuration steps or run them in an order different from that
425 listed in Parrot::Configure::Step::List.
426
427 A configuration file is a plain-text file located somewhere in or under your
428 top-level Parrot directory. Unless indicated otherwise, all lines in this
429 file must have no leading whitespace. As in Perl 5, lines beginning with C<#>
430 marks are comments and are ignored during parsing of the file. Unlike Perl 5,
431 you may not begin comments in the middle of a line.
432
433 The configuration file must contain these three sections:
434
435 =over 4
436
437 =item * variables
438
439 =over 4
440
441 =item *
442
443 Section begins with line C<=variables> and must be followed by at least one
444 blank line. All other content in this section is optional.
445
446 =item *
447
448 Section may contain one or more I<key=value> pairs which assign strings to
449 variables much in the way that you would do in a shell script wrapping around
450 F<Configure.pl>.
451
452 =variables
453
454 CC=/usr/bin/gcc
455 CX=/usr/bin/g++
456
457 So if you typically invoked F<Configure.pl> by wrapping it in a shell script
458 for the purpose of setting environmental variables used in options, like this:
459
460 CC="/usr/bin/gcc"
461 CX="/usr/bin/g++"
462 /usr/local/bin/perl Configure.pl \
463 --cc="$CC" \
464 --link="$CX" \
465 --ld="$CX"
466
467 ... you would now place the assignments to C<CC> and C<CX> in the
468 I<=variables> section of the configuration file (as above).
469
9691780 @jkeenan Modify documentation re file-based configuration to respond to proble…
jkeenan authored
470 In addition, should you wish to use an option whose value contains whitespace
f7cc9f9 @jkeenan [configure] Provide an additional pattern by which an entry in the 'g…
jkeenan authored
471 and would, if presented on the command-line, require quoting, you may
9691780 @jkeenan Modify documentation re file-based configuration to respond to proble…
jkeenan authored
472 assign that string to a variable and then use the variable in the C<general>
473 section below.
474
475 LONGLONG=long long
476
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
477 =back
478
479 =item * general
480
481 =over 4
482
483 =item *
484
485 Section begins with line C<=general> and must be followed by at least one
486 blank line. All other content in this section is optional.
487
488 =item *
489
490 This section is the location recommended for listing options whose impact is
491 not conceptually limited to a single step. It is also the location where the
492 variables defined in the I<=variables> section are assigned to particular
493 Parrot configuration options. Entries in this section must be either
494 I<option=value> pairs or be options which will be assigned a true value.
495
496 cc=$CC
497 link=$CX
498 ld=/usr/bin/g++
499 verbose
500
501 Note that when the value is a variable defined in the I<=variables> section,
502 it must be preceded by a C<$> sign.
503
9691780 @jkeenan Modify documentation re file-based configuration to respond to proble…
jkeenan authored
504 intval=$LONGLONG
505
f7cc9f9 @jkeenan [configure] Provide an additional pattern by which an entry in the 'g…
jkeenan authored
506 Alternatively, if assignment of a value to an option on the command-line would
507 require quoting due to the presence of whitespace in the value, you may assign
508 it to a value in the I<=general> section by double-quoting the value.
509
510 intval="long long"
511
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
512 =item *
513
514 You I<may> list options here which are I<conceptually> limited to a single
515 configuration step. For example, if you wished to skip validation of the
516 F<MANIFEST> during configuration and to configure without ICU, you I<could>,
517 in this section, say:
518
519 nomanicheck
520 without-icu
521
522 However, as we shall quickly see, it's conceptually clearer to place these
523 values next to those configuration steps that actually use them.
524
525 =back
526
527 =item * steps
528
529 =over 4
530
531 =item *
532
533 Section begins with line C<=steps> and must be followed by at least one
534 blank line, in turn followed by the list of configuration steps, followed by
535 another blank line followed by a line C<=cut> (just like POD).
536
537 =item *
538
539 The order in which you list the steps is the order in which they will be
540 executed. If you delete a step from the canonical list or comment a step out,
541 it will not be executed.
542
543 ...
544 auto::snprintf
545 # auto::perldoc
546 auto::ctags
547 ...
548
549 In the above example, step C<auto::perldoc> will be completely skipped. You
550 will not see it listed as C<....skipped> in F<Configure.pl>'s output; it will
551 simply not be there at all.
552
553 =item *
554
555 This is the recommended location to call options whose impact is
556 I<conceptually> limited to a single configuration step. Type the
557 configuration step's name, type a whitespace, type the option (with no leading
558 C<-->) and repeat as needed for additional step-specific options.
559
560 init::manifest nomanicheck
561 ...
562
563 =item *
564
565 This is also the location to call options whose impact is limited to one step
566 at a time but which may be applied to more than one configuration step. The
567 C<fatal-step> and C<verbose-step> options are the best examples of this case.
568 Rather than requesting verbose output from all configuration steps, you may,
569 for example, wish to designate only a few steps for verbose output:
570
571 ...
572 init::hints verbose-step
067bf3a @coke remove init::headers config step
coke authored
573 ...
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
574 inter::progs fatal-step
575 ...
576 auto::gcc verbose-step
577 ...
578
579 In the above example, F<Configure.pl> will grind to a halt if C<inter::progs>
580 does not complete successfully. You will get verbose output only from
581 C<init::hints> and C<auto::gcc>; the other 60+ steps will be terse.
582
583 =item *
584
585 Nothing prevents you from listing general options anywhere in this section.
586
587 init::manifest nomanicheck cc=$CC ld=/usr/bin/g++ verbose
588 init::defaults
589 ...
590
591 That will work -- but why would you want to do something that messy?
592
593 =back
594
595 =back
596
597 =head2 Example
598
599 Ignoring leading whitespace, this is an example of a correctly formed
600 configuration file.
601
602 =variables
603
604 CC=/usr/bin/gcc
605 CX=/usr/bin/g++
606
607 =general
608
609 cc=$CC
610 link=$CX
611 ld=/usr/bin/g++
612
613 =steps
614
615 init::manifest nomanicheck
616 init::defaults
617 init::install
618 init::hints verbose-step
619 inter::progs
620 inter::make
621 inter::lex
622 inter::yacc
623 auto::gcc
624 auto::glibc
625 auto::backtrace
626 auto::fink
627 auto::macports
628 auto::msvc
629 auto::attributes
630 auto::warnings
631 init::optimize
632 inter::shlibs
633 inter::libparrot
634 inter::types
635 auto::ops
636 auto::alignptrs
637 auto::headers
638 auto::sizes
639 auto::byteorder
640 auto::va_ptr
641 auto::format
642 auto::isreg
643 auto::arch
644 auto::jit
645 auto::cpu
646 auto::inline
647 auto::gc
648 auto::memalign
649 auto::signal
650 auto::socklen_t
651 auto::env
652 auto::gmp
653 auto::readline
654 auto::pcre
655 auto::opengl
656 auto::gettext
657 auto::snprintf
658 # auto::perldoc
659 auto::ctags
660 auto::revision
661 auto::icu
59fec7a @nwellnhof Move platform code from config to src
nwellnhof authored
662 auto::platform
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
663 gen::config_h
664 gen::core_pmcs
665 gen::opengl
666 gen::makefiles
667 gen::config_pm
668
669 =cut
670
671 You may see how this works in practice by calling:
672
c2f7ada @jkeenan Revise Configure.pl POD and other docs to reflect file movement.
jkeenan authored
673 perl Configure.pl --file=examples/config/file/configcompiler
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
674
675 or
676
c2f7ada @jkeenan Revise Configure.pl POD and other docs to reflect file movement.
jkeenan authored
677 perl Configure.pl --file=examples/config/file/configwithfatalstep
780cbd7 @jkeenan Merge newsc branch into trunk, implementing Configuration-File interf…
jkeenan authored
678
c9264be more config system add ons and docs
Leopold Toetsch authored
679 =head1 SEE ALSO
680
e478ac7 @jkeenan Merge fileconf branch into trunk per
jkeenan authored
681 F<lib/Parrot/Configure.pm>,
c9264be more config system add ons and docs
Leopold Toetsch authored
682 F<lib/Parrot/Configure/Step.pm>, F<docs/configuration.pod>
683
756762f *** empty log message ***
Michael Scott authored
684 =cut
aeeafc5 @brentdax Mention where all the files went.
brentdax authored
685
b91d268 @bschmalhofer #40278: [CAGE] perl coding standards coda.
bschmalhofer authored
686 # Local Variables:
687 # mode: cperl
688 # cperl-indent-level: 4
689 # fill-column: 100
690 # End:
691 # vim: expandtab shiftwidth=4:
25830bb @jkeenan Applying patch submitted in
jkeenan authored
692
Something went wrong with that request. Please try again.