OrclChina / mysql-master-ha

Automatically exported from code.google.com/p/mysql-master-ha
0 stars 0 forks source link

[patch] wrong perl vendor dir for rhel6 #9

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
On the default perl install on RHEL6, the vendor dir is 
/usr/share/perl5/vendor_lib. The spec files hardcode /usr/lib/perl5/vendor_lib 
and make the packages unusable on RHEL6.

Original issue reported on code.google.com by petefbsd on 18 Nov 2011 at 2:01

Attachments:

GoogleCodeExporter commented 8 years ago
I can create a separated rpm package for RHEL6 that installs Perl modules under 
/usr/share/perl5/vendor_perl/ . This is easy, but let me check one thing..

What are outputs of the following?
$ cat /etc/redhat-release
$ perl -e "use a"

My understanding was RHEL6/CentOS6 includes /usr/lib/perl5/vendor_perl in @INC 
like below.
$ perl -e "use a"
Can't locate a.pm in @INC (@INC contains: /usr/local/lib/perl5 
/usr/local/share/perl5 /usr/lib/perl5/vendor_perl /usr/share/perl5/vendor_perl 
/usr/lib/perl5 /usr/share/perl5 .) at -e line 1.

In this case current rpm package works.

Original comment by Yoshinor...@gmail.com on 18 Nov 2011 at 3:07

GoogleCodeExporter commented 8 years ago
I verified that /usr/lib/perl5/vendor_perl was removed from @INC from RHEL6.1. 
I'll create a separated rpm package for RHEL/CentOS6.1 from the next version 
(MHA 5.3).

Original comment by Yoshinor...@gmail.com on 18 Nov 2011 at 3:27

GoogleCodeExporter commented 8 years ago
0 rhel6.build.mtv1(~) % cat /etc/redhat-release 
Red Hat Enterprise Linux Server release 6.0 (Santiago)
0 rhel6.build.mtv1(~) % perl -e "use a"
Can't locate a.pm in @INC (@INC contains: /usr/local/lib64/perl5 
/usr/local/share/perl5 /usr/lib64/perl5/vendor_perl 
/usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .) at -e line 1.
BEGIN failed--compilation aborted at -e line 1.
2 rhel6.build.mtv1(~) % perl -V:installvendorlib
installvendorlib='/usr/share/perl5/vendor_perl';
0 rhel6.build.mtv1(~) % sudo yum info perl
Loaded plugins: rhnplugin, security
Installed Packages
Name       : perl
Arch       : x86_64
Epoch      : 4
Version    : 5.10.1
Release    : 119.el6_1.1
Size       : 34 M
Repo       : installed
From repo  : rhel-x86_64-server-6
Summary    : Practical Extraction and Report Language
URL        : http://www.perl.org/

Looks like it's "/usr/lib64/perl5/vendor_perl" because I'm on the x86_64 
architecture.

Original comment by petefbsd on 18 Nov 2011 at 3:29

GoogleCodeExporter commented 8 years ago
Thanks for the bug report. 
I pushed fixes to github tree. I'll release separated two rpm packages (for 
RHEL4,5 and for RHEL6) from MHA version 5.3.

https://github.com/yoshinorim/mha4mysql-manager
https://github.com/yoshinorim/mha4mysql-node

Original comment by Yoshinor...@gmail.com on 18 Nov 2011 at 3:58