IBM Support

TNPMW Gateways - Perl 5.6.1 Build Instruction for RHEL

Education


Abstract

The IBM Tivoli Netcool Performance Manager for Wireless Gateways - Perl requires Perl 5.6.1. This provides the instruction on how to build Perl 5.6.1.

Content

System Requirements
The documents attached provides the instructions to build Perl 5.6.1 for the following machine platform:
Vendor O/S version(s) Architecture
Red Hat Enterprise Linux 4 & 5 x86-32, and x86-64
Note: x86-64 includes EM64T (Xeon) and AMD64 (Opteron); x86-32 is Intel 32-bit and AMD Athlon

Software Requirements
The RPM packages required for RHEL 4 is listed in the table below:
Software RPM Packages Name Version
GCC gcc 3.4.6
GCC libraries libgcc 3.4.6
GNU Make make 3.80
GNU binary utilities binutils 2.15.92.0.2
GNU C development headers and libraries glibc-devel 2.3.4
GNU C-compatible Compiler Processor cpp 3.4.6
Berkeley Yacc byacc 1.9
Note: The development library to compile perl for this instruction must be in 32 bit binary.
This requirement applies for both x86-32 and x86-64 architectures.

The RPM packages required for RHEL 5 is listed in the table below:

Software RPM Packages Name Version
GCC gcc 4.1.2
GCC libraries libgcc 4.1.2
GNU Make make 3.81
GNU binary utilities binutils 2.17.50.0.6
GNU C development headers and libraries glibc-devel 2.5
GNU C-compatible Compiler Processor cpp 4.1.2
Berkeley Yacc byacc 1.9
Note: The development library to compile perl for this instruction must be in 32 bit binary.
This requirement applies for both x86-32 and x86-64 architectures.

Preparation


Download Perl 5.6.1 source code from http://www.perl.com/CPAN/src
Extract the content of the source package using the following command:
$ gunzip -dc perl-5.6.1.tar.gz | tar xvf -
The directory perl-5.6.1 will be created with its contents.

Ensure that make and cc is in the $PATH environment.

Remove the config.sh and Policy.sh from within the perl-5.6.1 directory if available:
$ cd perl-5.6.1
$ rm -f config.sh Policy.sh

Create the installation directories at a desired location, e.g.:
$ mkdir -p /usr/local/gways/perl5/5.6.1/bin

Build Instruction
Run Configure within the Perl source directory with the following parameters:
  1. set the prefix to use the installation directory created earlier,
  2. do not install perl as /usr/bin/perl, and
  3. accept all other default parameters.
$ sh Configure -Dprefix=/usr/local/gways/perl5/5.6.1 \
  • -Uinstallusrbinperl -Ui_db -des -Dcc='cc -m32' \
    -Darchname='i686-linux'

After Configure is completed, edit the following makefiles:
    1. makefile
    2. x2p/makefile

Remove the lines containing the following from the makefiles:
    1. <build-in>
    2. <command line>

The following command can be used to remove the lines:
$ mv makefile makefile.1
$ cat makefile.1 | sed '/: </d' > makefile
Repeat the above commands for x2p/makefile
$ cd x2p
$ mv makefile makefile.1
$ cat makefile.1 | sed '/: </d' > makefile
$ cd ..
For RHEL 5, please run the following command to ensure the correctness of the SIG_NAME defines in config.h file:
$ perl -pi -e 's/^#define SIG_NAME [ ]*"ZERO", 0/#define SIG_NAME "ZERO", "HUP", "INT", "QUIT", "ILL", "TRAP", "ABRT", "BUS", "FPE", "KILL", "USR1", "SEGV", "USR2", "PIPE", "ALRM", "TERM", "STKFLT", "CHLD", "CONT", "STOP", "TSTP", "TTIN", "TTOU", "URG", "XCPU", "XFSZ", "VTALRM", "PROF", "WINCH", "IO", "PWR", "SYS", "NUM32", "NUM33", "RTMIN", "NUM35", "NUM36", "NUM37", "NUM38", "NUM39", "NUM40", "NUM41", "NUM42", "NUM43", "NUM44", "NUM45", "NUM46", "NUM47", "NUM48", "NUM49", "NUM50", "NUM51", "NUM52", "NUM53", "NUM54", "NUM55", "NUM56", "NUM57", "NUM58", "NUM59", "NUM60", "NUM61", "NUM62", "NUM63", "RTMAX", "IOT", "CLD", "POLL", "UNUSED", 0/g' config.h
For RHEL 5, please run the following command to ensure the correctness of the SIG_NUM defines in config.h file:
$ perl -pi -e 's/^#define SIG_NUM [ ]*0, 0/#define SIG_NUM 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 6, 17, 29, 31, 0/g' config.h
After the the steps completed, run make:
$ make

The binaries are verified using the following command:
$ make test

The last two lines of the output should show something similar to the following:
All tests successful.
u=0.17 s=0.37 cu=17.74 cs=9.53 scripts=251 tests=12634

Finally, install perl into the target installation directory:
$ make install

Check the perl configuration summary by running the following command:
$ <perl_installation_directory>/bin/perl -V

Check the perl build architecture by running the following the command:
$ file <perl_installation_directory>/bin/perl
The sample output of the command is as below:
/usr/local/gways/perl5/5.6.1/bin/perl: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), for GNU/Linux 2.2.5, dynamically linked (uses shared libs), not stripped

Original Publication Date

08 March 2010

Perl_Build_Instruction_RHELx86.pdf

[{"Product":{"code":"SSKGHX","label":"Tivoli Netcool Performance Manager for Wireless"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"Gateways","Platform":[{"code":"PF016","label":"Linux"}],"Version":"9.2;1.2.1;1.3","Edition":"","Line of Business":{"code":"LOB45","label":"Automation"}}]

Document Information

Modified date:
06 April 2020

UID

swg27015399