| 1 | If you read this file _as_is_, just ignore the funny characters you
|
|---|
| 2 | see. It is written in the POD format (see pod/perlpod.pod) which is
|
|---|
| 3 | specifically designed to be readable as is.
|
|---|
| 4 |
|
|---|
| 5 | =head1 NAME
|
|---|
| 6 |
|
|---|
| 7 | README.solaris - Perl version 5 on Solaris systems
|
|---|
| 8 |
|
|---|
| 9 | =head1 DESCRIPTION
|
|---|
| 10 |
|
|---|
| 11 | This document describes various features of Sun's Solaris operating system
|
|---|
| 12 | that will affect how Perl version 5 (hereafter just perl) is
|
|---|
| 13 | compiled and/or runs. Some issues relating to the older SunOS 4.x are
|
|---|
| 14 | also discussed, though they may be out of date.
|
|---|
| 15 |
|
|---|
| 16 | For the most part, everything should just work.
|
|---|
| 17 |
|
|---|
| 18 | Starting with Solaris 8, perl5.00503 (or higher) is supplied with the
|
|---|
| 19 | operating system, so you might not even need to build a newer version
|
|---|
| 20 | of perl at all. The Sun-supplied version is installed in /usr/perl5
|
|---|
| 21 | with /usr/bin/perl pointing to /usr/perl5/bin/perl. Do not disturb
|
|---|
| 22 | that installation unless you really know what you are doing. If you
|
|---|
| 23 | remove the perl supplied with the OS, you will render some bits of
|
|---|
| 24 | your system inoperable. If you wish to install a newer version of perl,
|
|---|
| 25 | install it under a different prefix from /usr/perl5. Common prefixes
|
|---|
| 26 | to use are /usr/local and /opt/perl.
|
|---|
| 27 |
|
|---|
| 28 | You may wish to put your version of perl in the PATH of all users by
|
|---|
| 29 | changing the link /usr/bin/perl. This is probably OK, as most perl
|
|---|
| 30 | scripts shipped with Solaris use an explicit path. (There are a few
|
|---|
| 31 | exceptions, such as /usr/bin/rpm2cpio and /etc/rcm/scripts/README, but
|
|---|
| 32 | these are also sufficiently generic that the actual version of perl
|
|---|
| 33 | probably doesn't matter too much.)
|
|---|
| 34 |
|
|---|
| 35 | Solaris ships with a range of Solaris-specific modules. If you choose
|
|---|
| 36 | to install your own version of perl you will find the source of many of
|
|---|
| 37 | these modules is available on CPAN under the Sun::Solaris:: namespace.
|
|---|
| 38 |
|
|---|
| 39 | Solaris may include two versions of perl, e.g. Solaris 9 includes
|
|---|
| 40 | both 5.005_03 and 5.6.1. This is to provide stability across Solaris
|
|---|
| 41 | releases, in cases where a later perl version has incompatibilities
|
|---|
| 42 | with the version included in the preceeding Solaris release. The
|
|---|
| 43 | default perl version will always be the most recent, and in general
|
|---|
| 44 | the old version will only be retained for one Solaris release. Note
|
|---|
| 45 | also that the default perl will NOT be configured to search for modules
|
|---|
| 46 | in the older version, again due to compatibility/stability concerns.
|
|---|
| 47 | As a consequence if you upgrade Solaris, you will have to
|
|---|
| 48 | rebuild/reinstall any additional CPAN modules that you installed for
|
|---|
| 49 | the previous Solaris version. See the CPAN manpage under 'autobundle'
|
|---|
| 50 | for a quick way of doing this.
|
|---|
| 51 |
|
|---|
| 52 | As an interim measure, you may either change the #! line of your
|
|---|
| 53 | scripts to specifically refer to the old perl version, e.g. on
|
|---|
| 54 | Solaris 9 use #!/usr/perl5/5.00503/bin/perl to use the perl version
|
|---|
| 55 | that was the default for Solaris 8, or if you have a large number of
|
|---|
| 56 | scripts it may be more convenient to make the old version of perl the
|
|---|
| 57 | default on your system. You can do this by changing the appropriate
|
|---|
| 58 | symlinks under /usr/perl5 as follows (example for Solaris 9):
|
|---|
| 59 |
|
|---|
| 60 | # cd /usr/perl5
|
|---|
| 61 | # rm bin man pod
|
|---|
| 62 | # ln -s ./5.00503/bin
|
|---|
| 63 | # ln -s ./5.00503/man
|
|---|
| 64 | # ln -s ./5.00503/lib/pod
|
|---|
| 65 | # rm /usr/bin/perl
|
|---|
| 66 | # ln -s ../perl5/5.00503/bin/perl /usr/bin/perl
|
|---|
| 67 |
|
|---|
| 68 | In both cases this should only be considered to be a temporary
|
|---|
| 69 | measure - you should upgrade to the later version of perl as soon as
|
|---|
| 70 | is practicable.
|
|---|
| 71 |
|
|---|
| 72 | Note also that the perl command-line utilities (e.g. perldoc) and any
|
|---|
| 73 | that are added by modules that you install will be under
|
|---|
| 74 | /usr/perl5/bin, so that directory should be added to your PATH.
|
|---|
| 75 |
|
|---|
| 76 | =head2 Solaris Version Numbers.
|
|---|
| 77 |
|
|---|
| 78 | For consistency with common usage, perl's Configure script performs
|
|---|
| 79 | some minor manipulations on the operating system name and version
|
|---|
| 80 | number as reported by uname. Here's a partial translation table:
|
|---|
| 81 |
|
|---|
| 82 | Sun: perl's Configure:
|
|---|
| 83 | uname uname -r Name osname osvers
|
|---|
| 84 | SunOS 4.1.3 Solaris 1.1 sunos 4.1.3
|
|---|
| 85 | SunOS 5.6 Solaris 2.6 solaris 2.6
|
|---|
| 86 | SunOS 5.8 Solaris 8 solaris 2.8
|
|---|
| 87 | SunOS 5.9 Solaris 9 solaris 2.9
|
|---|
| 88 | SunOS 5.10 Solaris 10 solaris 2.10
|
|---|
| 89 |
|
|---|
| 90 | The complete table can be found in the Sun Managers' FAQ
|
|---|
| 91 | L<ftp://ftp.cs.toronto.edu/pub/jdd/sunmanagers/faq> under
|
|---|
| 92 | "9.1) Which Sun models run which versions of SunOS?".
|
|---|
| 93 |
|
|---|
| 94 | =head1 RESOURCES
|
|---|
| 95 |
|
|---|
| 96 | There are many, many sources for Solaris information. A few of the
|
|---|
| 97 | important ones for perl:
|
|---|
| 98 |
|
|---|
| 99 | =over 4
|
|---|
| 100 |
|
|---|
| 101 | =item Solaris FAQ
|
|---|
| 102 |
|
|---|
| 103 | The Solaris FAQ is available at
|
|---|
| 104 | L<http://www.science.uva.nl/pub/solaris/solaris2.html>.
|
|---|
| 105 |
|
|---|
| 106 | The Sun Managers' FAQ is available at
|
|---|
| 107 | L<ftp://ftp.cs.toronto.edu/pub/jdd/sunmanagers/faq>
|
|---|
| 108 |
|
|---|
| 109 | =item Precompiled Binaries
|
|---|
| 110 |
|
|---|
| 111 | Precompiled binaries, links to many sites, and much, much more are
|
|---|
| 112 | available at L<http://www.sunfreeware.com/> and
|
|---|
| 113 | L<http://www.blastwave.org/>.
|
|---|
| 114 |
|
|---|
| 115 | =item Solaris Documentation
|
|---|
| 116 |
|
|---|
| 117 | All Solaris documentation is available on-line at L<http://docs.sun.com/>.
|
|---|
| 118 |
|
|---|
| 119 | =back
|
|---|
| 120 |
|
|---|
| 121 | =head1 SETTING UP
|
|---|
| 122 |
|
|---|
| 123 | =head2 File Extraction Problems on Solaris.
|
|---|
| 124 |
|
|---|
| 125 | Be sure to use a tar program compiled under Solaris (not SunOS 4.x)
|
|---|
| 126 | to extract the perl-5.x.x.tar.gz file. Do not use GNU tar compiled
|
|---|
| 127 | for SunOS4 on Solaris. (GNU tar compiled for Solaris should be fine.)
|
|---|
| 128 | When you run SunOS4 binaries on Solaris, the run-time system magically
|
|---|
| 129 | alters pathnames matching m#lib/locale# so that when tar tries to create
|
|---|
| 130 | lib/locale.pm, a file named lib/oldlocale.pm gets created instead.
|
|---|
| 131 | If you found this advice too late and used a SunOS4-compiled tar
|
|---|
| 132 | anyway, you must find the incorrectly renamed file and move it back
|
|---|
| 133 | to lib/locale.pm.
|
|---|
| 134 |
|
|---|
|
|---|