--- App-Staticperl/staticperl.pod 2011/03/18 19:49:04 1.38 +++ App-Staticperl/staticperl.pod 2011/05/19 18:58:19 1.41 @@ -11,6 +11,7 @@ staticperl install # build and then install perl staticperl clean # clean most intermediate files (restart at configure) staticperl distclean # delete everything installed by this script + staticperl perl ... # invoke the perlinterpreter staticperl cpan # invoke CPAN shell staticperl instmod path... # install unpacked modules staticperl instcpan modulename... # install modules from CPAN @@ -40,7 +41,7 @@ With F and F on x86, you can create a single 500kb binary that contains perl and 100 modules such as POSIX, AnyEvent, EV, IO::AIO, -Coro and so on. Or any other choice of modules. +Coro and so on. Or any other choice of modules (and some other size :). To see how this turns out, you can try out smallperl and bigperl, two pre-built static and compressed perl binaries with many and even more @@ -188,6 +189,16 @@ Wipes the perl installation directory (usually F<~/.staticperl/perl>) and installs the perl distribution, potentially after building it first. +=item F [args...] + +Invokes the compiled perl interpreter with the given args. Basically the +same as starting perl directly (usually via F<~/.staticperl/bin/perl>), +but beats typing the path sometimes. + +Example: check that the Gtk2 module is installed and loadable. + + staticperl perl -MGtk2 -e0 + =item F [args...] Starts an interactive CPAN shell that you can use to install further @@ -914,6 +925,11 @@ Most of the variables override (or modify) the corresponding F variable, except C, which gets appended. +You should have a look near the beginning of the F script - +staticperl tries to default C to some psace-saving options +suitable for newer gcc versions. For other compilers or older versions you +need to adjust these, for example, in your F<~/.staticperlrc>. + =back =head4 Variables you probably I to override @@ -1141,7 +1157,7 @@ To minimise code size, I used C<-pipe -ffunction-sections -fdata-sections -finline-limit=8 -fno-builtin-strlen -mtune=i386>. The C<-mtune=i386> doesn't decrease codesize much, but it makes the file much more -compressible. +compressible (and the execution a lot slower...). If you don't need Coro or threads, you can go with "linuxthreads.old" (or no thread support). For Coro, it is highly recommended to switch to a @@ -1224,6 +1240,10 @@ Or you can use C<--usepacklists> and specify C<-MAnyEvent> to include everything. +=item Cairo + +See Glib, same problem, same solution. + =item Carp Carp had (in older versions of perl) a dependency on L. As of @@ -1235,6 +1255,23 @@ turn might need L<"Config_heavy.pl">. Including the latter gives you both. +=item Glib + +Glib literally requires Glib to be installed already to build - it tries +to fake this by running Glib out of the build directory before being +built. F tries to work around this by forcing C and +C to be empty via the C environment variable. + +=item Gtk2 + +See Pango, same problems, same solution. + +=item Pango + +In addition to the C problem in Glib, Pango also routes around +L by compiling its files on its own. F +tries to patch L to route around Pango. + =item Term::ReadLine::Perl Also needs L, or C<--usepacklists>.