1App::cpanminus(3)     User Contributed Perl Documentation    App::cpanminus(3)
2
3
4

NAME

6       App::cpanminus - get, unpack, build and install modules from CPAN
7

SYNOPSIS

9           cpanm Module
10
11       Run "cpanm -h" or "perldoc cpanm" for more options.
12

DESCRIPTION

14       cpanminus is a script to get, unpack, build and install modules from
15       CPAN and does nothing else.
16
17       It's dependency free (can bootstrap itself), requires zero
18       configuration, and stands alone. When running, it requires only 10MB of
19       RAM.
20

INSTALLATION

22       There are several ways to install cpanminus to your system.
23
24   Package management system
25       There are Debian packages, RPMs, FreeBSD ports, and packages for other
26       operation systems available. If you want to use the package management
27       system, search for cpanminus and use the appropriate command to
28       install. This makes it easy to install "cpanm" to your system without
29       thinking about where to install, and later upgrade.
30
31   Installing to system perl
32       You can also use the latest cpanminus to install cpanminus itself:
33
34           curl -L https://cpanmin.us | perl - --sudo App::cpanminus
35
36       This will install "cpanm" to your bin directory like "/usr/local/bin"
37       and you'll need the "--sudo" option to write to the directory, unless
38       you configured "INSTALL_BASE" with local::lib.
39
40   Installing to local perl (perlbrew, plenv etc.)
41       If you have perl in your home directory, which is the case if you use
42       tools like perlbrew or plenv, you don't need the "--sudo" option, since
43       you're most likely to have a write permission to the perl's library
44       path. You can just do:
45
46           curl -L https://cpanmin.us | perl - App::cpanminus
47
48       to install the "cpanm" executable to the perl's bin path, like
49       "~/perl5/perlbrew/bin/cpanm".
50
51   Downloading the standalone executable
52       You can also copy the standalone executable to whatever location you'd
53       like.
54
55           cd ~/bin
56           curl -L https://cpanmin.us/ -o cpanm
57           chmod +x cpanm
58
59       This just works, but be sure to grab the new version manually when you
60       upgrade because "--self-upgrade" might not work with this installation
61       setup.
62
63   Troubleshoot: HTTPS warnings
64       When you run "curl" commands above, you may encounter SSL handshake
65       errors or certification warnings. This is due to your HTTP client
66       (curl) being old, or SSL certificates installed on your system needs to
67       be updated.
68
69       You're recommended to update the software or system if you can. If that
70       is impossible or difficult, use the "-k" option with curl.
71

DEPENDENCIES

73       perl 5.8.1 or later.
74
75       •   'tar' executable (bsdtar or GNU tar version 1.22 are recommended)
76           or Archive::Tar to unpack files.
77
78       •   C compiler, if you want to build XS modules.
79
80       •   make
81
82       •   Module::Build (core in 5.10)
83

QUESTIONS

85   How does cpanm get/parse/update the CPAN index?
86       It queries the CPAN Meta DB site at <http://cpanmetadb.plackperl.org/>.
87       The site is updated at least every hour to reflect the latest changes
88       from fast syncing mirrors. The script then also falls back to query the
89       module at <http://metacpan.org/> using its search API.
90
91       Upon calling these API hosts, cpanm (1.6004 or later) will send the
92       local perl versions to the server in User-Agent string by default. You
93       can turn it off with "--no-report-perl-version" option. Read more about
94       the option with cpanm, and read more about the privacy policy about
95       this data collection at <http://cpanmetadb.plackperl.org/#privacy>
96
97       Fetched files are unpacked in "~/.cpanm" and automatically cleaned up
98       periodically.  You can configure the location of this with the
99       "PERL_CPANM_HOME" environment variable.
100
101   Where does this install modules to? Do I need root access?
102       It installs to wherever ExtUtils::MakeMaker and Module::Build are
103       configured to (via "PERL_MM_OPT" and "PERL_MB_OPT").
104
105       By default, it installs to the site_perl directory that belongs to your
106       perl. You can see the locations for that by running "perl -V" and it
107       will be likely something under "/opt/local/perl/..." if you're using
108       system perl, or under your home directory if you have built perl
109       yourself using perlbrew or plenv.
110
111       If you've already configured local::lib on your shell, cpanm respects
112       that settings and modules will be installed to your local perl5
113       directory.
114
115       At a boot time, cpanminus checks whether you have already configured
116       local::lib, or have a permission to install modules to the site_perl
117       directory.  If neither, i.e. you're using system perl and do not run
118       cpanm as a root, it automatically sets up local::lib compatible
119       installation path in a "perl5" directory under your home directory.
120
121       To avoid this, run "cpanm" either as a root user, with "--sudo" option,
122       or with "--local-lib" option.
123
124   cpanminus can't install the module XYZ. Is it a bug?
125       It is more likely a problem with the distribution itself. cpanminus
126       doesn't support or may have issues with distributions such as follows:
127
128       •   Tests that require input from STDIN.
129
130       •   Build.PL or Makefile.PL that prompts for input even when
131           "PERL_MM_USE_DEFAULT" is enabled.
132
133       •   Modules that have invalid numeric values as VERSION (such as
134           "1.1a")
135
136       These failures can be reported back to the author of the module so that
137       they can fix it accordingly, rather than to cpanminus.
138
139   Does cpanm support the feature XYZ of CPAN and CPANPLUS?
140       Most likely not. Here are the things that cpanm doesn't do by itself.
141
142       If you need these features, use CPAN, CPANPLUS or the standalone tools
143       that are mentioned.
144
145       •   CPAN testers reporting. See App::cpanminus::reporter
146
147       •   Building RPM packages from CPAN modules
148
149       •   Listing the outdated modules that needs upgrading. See
150           App::cpanoutdated
151
152       •   Showing the changes of the modules you're about to upgrade. See
153           cpan-listchanges
154
155       •   Patching CPAN modules with distroprefs.
156
157       See cpanm or "cpanm -h" to see what cpanminus can do :)
158
160       Copyright 2010- Tatsuhiko Miyagawa
161
162       The standalone executable contains the following modules embedded.
163
164       CPAN::DistnameInfo Copyright 2003 Graham Barr
165       local::lib Copyright 2007-2009 Matt S Trout
166       HTTP::Tiny Copyright 2011 Christian Hansen
167       Module::Metadata Copyright 2001-2006 Ken Williams. 2010 Matt S Trout
168       version Copyright 2004-2010 John Peacock
169       JSON::PP Copyright 2007-2011 by Makamaka Hannyaharamitu
170       CPAN::Meta, CPAN::Meta::Requirements Copyright (c) 2010 by David Golden
171       and Ricardo Signes
172       CPAN::Meta::YAML Copyright 2010 Adam Kennedy
173       CPAN::Meta::Check Copyright (c) 2012 by Leon Timmermans
174       File::pushd Copyright 2012 David Golden
175       parent Copyright (c) 2007-10 Max Maischein
176       Parse::PMFile Copyright 1995 - 2013 by Andreas Koenig, Copyright 2013
177       by Kenichi Ishigaki
178       String::ShellQuote by Roderick Schertler
179

LICENSE

181       This software is licensed under the same terms as Perl.
182

CREDITS

184   CONTRIBUTORS
185       Patches and code improvements were contributed by:
186
187       Goro Fuji, Kazuhiro Osawa, Tokuhiro Matsuno, Kenichi Ishigaki, Ian
188       Wells, Pedro Melo, Masayoshi Sekimura, Matt S Trout (mst), squeeky,
189       horus and Ingy dot Net.
190
191   ACKNOWLEDGEMENTS
192       Bug reports, suggestions and feedbacks were sent by, or general
193       acknowledgement goes to:
194
195       Jesse Vincent, David Golden, Andreas Koenig, Jos Boumans, Chris
196       Williams, Adam Kennedy, Audrey Tang, J. Shirley, Chris Prather, Jesse
197       Luehrs, Marcus Ramberg, Shawn M Moore, chocolateboy, Chirs Nehren,
198       Jonathan Rockway, Leon Brocard, Simon Elliott, Ricardo Signes, AEvar
199       Arnfjord Bjarmason, Eric Wilhelm, Florian Ragwitz and xaicron.
200

COMMUNITY

202       <http://github.com/miyagawa/cpanminus> - source code repository, issue
203       tracker
204       <irc://irc.perl.org/#cpanm> - discussions about cpanm and its related
205       tools
206

NO WARRANTY

208       This software is provided "as-is," without any express or implied
209       warranty. In no event shall the author be held liable for any damages
210       arising from the use of the software.
211

SEE ALSO

213       CPAN CPANPLUS pip
214
215
216
217perl v5.36.0                      2022-07-22                 App::cpanminus(3)
Impressum