NAME ^

Configure.pl - Parrot's configuration script

SYNOPSIS ^

    % perl Configure.pl [options]

or:

    % perl Configure.pl --file=/path/to/configuration/directives

DESCRIPTION ^

This is Parrot's configuration program. It should be run to create the necessary system-specific files before building Parrot.

We now offer two interfaces to configuration:

General Options ^

--help

Prints out a description of the options and exits.

--version

Prints out the version number of Configure.pl and exits.

--verbose

Tells Configure.pl to output extra information about the configuration data it is setting.

--verbose=2

Tells Configure.pl to output information about i<every> setting added or changed.

--verbose-step={N|regex}

Run --verbose=2 for step number N or matching description.

--fatal

Tells Configure.pl to halt completely if any configuration step fails.

--fatal-step={init::alpha,inter::beta,auto::gamma}

Tells Configure.pl to halt completely if any configuration step in comma-delimited string individually fails.

--nomanicheck

Tells Configure.pl not to run the MANIFEST check.

--prefix

Sets the location where parrot will be installed.

--languages="list of languages"

Specify a list of languages to process (space separated.) Used in combination with --step=gen::languages to regenerate makefiles.

--ask

This turns on the user prompts during configuraion. Available only in Command-Line interface. Not available in Configuration-File interface.

--test

Run certain tests along with Configure.pl:

--test=configure

Run tests found in t/configure/ before beginning configuration. These tests demonstrate that Parrot's configuration tools will work properly once configuration has begun.

--test=build

Run tests found in t/postconfigure/, t/tools/pmc2cutils/, t/tools/ops2cutils/ and t/tools/ops2pmutils/ after configuration has completed. These tests demonstrate (a) that certain of Parrot's configuration tools are working properly post-configuration; and (b) that certain of Parrot's build tools will work properly once you call make.

--test

Run the tests described in --test=configure, conduct configuration, then run the tests described in --test=build.

Compile Options ^

--debugging=0

Debugging is turned on by default. Use this to disable it.

--parrot_is_shared

Link parrot dynamically.

--m=32

Create a 32-bit executable on 64-architectures like x86_64. This option appends -m32 to compiler and linker programs and does s/lib64/lib/g on link flags.

This option is experimental. See config/init/defaults.pm for more.

--profile

Turn on profiled compile (gcc only for now)

--cage

[CAGE] compile includes many additional warnings

--optimize

Add perl5's $Config{optimize} to the compiler flags.

--optimize=flags

Add flags to the compiler flags.

--inline

Tell Configure that the compiler supports inline.

--cc=(compiler)

Specify which compiler to use.

--ccflags=(flags)

Use the given compiler flags.

--ccwarn=(flags)

Use the given compiler warning flags.

--cxx=(compiler)

Specify which C++ compiler to use (for ICU).

--libs=(libs)

Use the given libraries.

--link=(linker)

Specify which linker to use.

--linkflags=(flags)

Use the given linker flags

--ld=(linker)

Specify which loader to use for shared libraries.

--ldflags=(flags)

Use the given loader flags for shared libraries

--lex=(lexer)

Specify which lexer to use.

--yacc=(parser)

Specify which parser to use.

--define=val1[,val2]

Generate "#define PARROT_DEF_VAL1 1" ... entries in has_header.h. Currently needed to use inet_aton for systems that lack inet_pton:

  --define=inet_aton

Parrot Options ^

--intval=(type)

Use the given type for INTVAL.

--floatval=(type)

Use the given type for FLOATVAL.

--opcode=(type)

Use the given type for opcodes.

--ops=(files)

Use the given ops files.

--pmc=(files)

Use the given PMC files.

--cgoto=0

Don't build cgoto core. This is recommended when you are short of memory.

--jitcapable

Use JIT system.

--execcapable

Use JIT to emit a native executable.

--gc=(type)

Determine the type of garbage collection. The value for type should be one of: gc, libc, malloc or malloc-trace. The default is gc.

International Components For Unicode (ICU) Options ^

--icu-config=/path/to/icu-config

Use the specified icu-config script to determine the necessary ICU options.

Use --icu-config=none to disable the autodetect feature. Parrot will then be build without ICU.

Note: If you specify another ICU option than --icu-config, the autodetection functionality will be disabled.

--icushared=(linkeroption)

Linker command to link against ICU library.

E.g.

   --icushared='-L /opt/openoffice/program -licudata -licuuc'
(The libs in openoffice are actually version 2.2 and do not work)

--icuheaders=(header_dir)

Location of ICU header files without the /unicode suffix.

E.g.

--icuheaders='/home/lt/icu/'

Other Options ^

--maintainer

Use this option if you want imcc's parser and lexer files to be generated. Needs a working parser and lexer.

--miniparrot

Build parrot assuming only pure ANSI C is available.

CONFIGURATION-FILE INTERFACE ^

In the Configuration-File interface, unlike the Command-Line interface, you may delete configuration steps or run them in an order different from that listed in Parrot::Configure::Step::List.

A configuration file is a plain-text file located somewhere in or under your top-level Parrot directory. Unless indicated otherwise, all lines in this file must have no leading whitespace. As in Perl 5, lines beginning with # marks are comments and are ignored during parsing of the file. Unlike Perl 5, you may not begin comments in the middle of a line.

The configuration file must contain these three sections:

Example ^

Ignoring leading whitespace, this is an example of a correctly formed configuration file.

    =variables

    CC=/usr/bin/gcc
    CX=/usr/bin/g++

    =general

    cc=$CC
    cxx=$CX
    link=$CX
    ld=/usr/bin/g++

    =steps

    init::manifest nomanicheck
    init::defaults
    init::install
    init::miniparrot
    init::hints verbose-step
    init::headers
    inter::progs
    inter::make
    inter::lex
    inter::yacc
    auto::gcc
    auto::glibc
    auto::backtrace
    auto::fink
    auto::macports
    auto::msvc
    auto::attributes
    auto::warnings
    init::optimize
    inter::shlibs
    inter::libparrot
    inter::charset
    inter::encoding
    inter::types
    auto::ops
    auto::pmc
    auto::alignptrs
    auto::headers
    auto::sizes
    auto::byteorder
    auto::va_ptr
    auto::format
    auto::isreg
    auto::arch
    auto::jit
    auto::cpu
    auto::funcptr
    auto::cgoto
    auto::inline
    auto::gc
    auto::memalign
    auto::signal
    auto::socklen_t
    auto::env
    auto::aio
    auto::gmp
    auto::readline
    auto::gdbm
    auto::pcre
    auto::opengl
    auto::crypto
    auto::gettext
    auto::snprintf
    # auto::perldoc
    auto::ctags
    auto::revision
    auto::icu
    gen::config_h
    gen::core_pmcs
    gen::crypto
    gen::parrot_include
    gen::opengl
    gen::call_list
    gen::languages
    gen::makefiles
    gen::platform
    gen::config_pm

    =cut

You may see how this works in practice by calling:

    perl Configure.pl --file=xconf/samples/yourfoobar

or

    perl Configure.pl --file=xconf/samples/testfoobar

SEE ALSO ^

lib/Parrot/Configure.pm, lib/Parrot/Configure/Step.pm, docs/configuration.pod


parrot