1ExtUtils::Install(3pm) Perl Programmers Reference Guide ExtUtils::Install(3pm)
2
3
4
6 ExtUtils::Install - install files from here to there
7
9 use ExtUtils::Install;
10
11 install({ 'blib/lib' => 'some/install/dir' } );
12
13 uninstall($packlist);
14
15 pm_to_blib({ 'lib/Foo/Bar.pm' => 'blib/lib/Foo/Bar.pm' });
16
18 Handles the installing and uninstalling of perl modules, scripts, man
19 pages, etc...
20
21 Both install() and uninstall() are specific to the way ExtUtils::Make‐
22 Maker handles the installation and deinstallation of perl modules. They
23 are not designed as general purpose tools.
24
25 Functions
26
27 install
28 install(\%from_to);
29 install(\%from_to, $verbose, $dont_execute, $uninstall_shadows);
30
31 Copies each directory tree of %from_to to its corresponding value
32 preserving timestamps and permissions.
33
34 There are two keys with a special meaning in the hash: "read" and
35 "write". These contain packlist files. After the copying is done,
36 install() will write the list of target files to $from_to{write}.
37 If $from_to{read} is given the contents of this file will be merged
38 into the written file. The read and the written file may be identi‐
39 cal, but on AFS it is quite likely that people are installing to a
40 different directory than the one where the files later appear.
41
42 If $verbose is true, will print out each file removed. Default is
43 false. This is "make install VERBINST=1"
44
45 If $dont_execute is true it will only print what it was going to do
46 without actually doing it. Default is false.
47
48 If $uninstall_shadows is true any differing versions throughout
49 @INC will be uninstalled. This is "make install UNINST=1"
50
51 install_default DISCOURAGED
52 install_default();
53 install_default($fullext);
54
55 Calls install() with arguments to copy a module from blib/ to the
56 default site installation location.
57
58 $fullext is the name of the module converted to a directory (ie.
59 Foo::Bar would be Foo/Bar). If $fullext is not specified, it will
60 attempt to read it from @ARGV.
61
62 This is primarily useful for install scripts.
63
64 NOTE This function is not really useful because of the hard-coded
65 install location with no way to control site vs core vs vendor
66 directories and the strange way in which the module name is given.
67 Consider its use discouraged.
68
69 uninstall
70 uninstall($packlist_file);
71 uninstall($packlist_file, $verbose, $dont_execute);
72
73 Removes the files listed in a $packlist_file.
74
75 If $verbose is true, will print out each file removed. Default is
76 false.
77
78 If $dont_execute is true it will only print what it was going to do
79 without actually doing it. Default is false.
80
81 pm_to_blib
82 pm_to_blib(\%from_to, $autosplit_dir);
83 pm_to_blib(\%from_to, $autosplit_dir, $filter_cmd);
84
85 Copies each key of %from_to to its corresponding value efficiently.
86 Filenames with the extension .pm are autosplit into the
87 $autosplit_dir. Any destination directories are created.
88
89 $filter_cmd is an optional shell command to run each .pm file
90 through prior to splitting and copying. Input is the contents of
91 the module, output the new module contents.
92
93 You can have an environment variable PERL_INSTALL_ROOT set which
94 will be prepended as a directory to each installed file (and direc‐
95 tory).
96
98 PERL_INSTALL_ROOT
99 Will be prepended to each install path.
100
102 Original author lost in the mists of time. Probably the same as Make‐
103 maker.
104
105 Currently maintained by Michael G Schwern "schwern@pobox.com"
106
107 Send patches and ideas to "makemaker@perl.org".
108
109 Send bug reports via http://rt.cpan.org/. Please send your generated
110 Makefile along with your report.
111
112 For more up-to-date information, see <http://www.makemaker.org>.
113
115 This program is free software; you can redistribute it and/or modify it
116 under the same terms as Perl itself.
117
118 See <http://www.perl.com/perl/misc/Artistic.html>
119
120
121
122perl v5.8.8 2001-09-21 ExtUtils::Install(3pm)