----- Original Message -----
From: "Andrew Ford" <A.Ford(a)ford-mason.co.uk>
To: softwarecollections(a)lists.fedorahosted.org
Sent: Thursday, December 6, 2012 3:29:00 PM
Subject: Building perl-5.16.1 collection on CentOS 5.8
I am trying to build Marcela Mašláňov's perl516 and perl-5.16.1
packages
on CentOS 5.8.
I had a couple of problems getting perl516 to build: firstly rpmbuild
requires a Group directive - I specified application/development, and
secondly rpm 4.4.2.3 seems to require BuildRoot. I was wondering
whether
it would be possible to detect the RPM version and add those
directives
conditionally.
That should be easy by adding condition if rpm < 4.8 or what is in EL-6.
Next I tried to build perl-5.16.1, initially without scl. That
failed
immediately as the line
BuildRequires: perl516-build
should be wrapped in a conditional scl macro, i.e.:
%{?scl:BuildRequires: %{scl}-build}
Yes.
With that in place the build succeeds but rpmbuild finds a shedload
of
unpackaged debug files under /usr/lib/debug. For a quick and dirty
solution, I defined debug_package as %{nil} and the package built OK,
except that all the RPMs were built as noarch. I'll investigate the
debug and arch issues later.
When I installed the perl516 package and tried to rebuild perl-5.16.1
as
a non-scl package it now tries to build the scl package. This seems
to
be due to the line
%scl perl516
in /etc/rpm/macros.perl516-macros. This also makes it impossible to
build perl514 while perl516-build is installed. In fact I would think
it
would make it impossible to build other base SCL packages unless one
specified the "--define 'scl <pkgname>'" on the command line. Is
it
necessary to have %scl defined in the macros.perl516-macros file? I
thought that scl was supposed to be defined with --define on the
invocation of rpmbuild - and I presume that all files in /etc/rpm are
loaded by rpmbuild at startup (I need to look through the rpmbuild
sources and possibly run it in the debugger).
We were doing builds in our instance of koji or mock. You can use mockbuild
on your computer. That should be the easiest way. Not sure, which version
of mock is on RHEL-5. I'm aware that old version weren't very useful.
With the perl516-build package installed the build trips over on
check-rpaths:
ERROR: 0002: file '/opt/rh/perl516/root/usr/bin/perl5.16.1' contains
an
invalid rpath '/opt/rh/perl516/root/usr/lib64/perl/CORE' in
[/opt/rh/perl516/root/usr/lib64/perl5/CORE]
Um, I thought we got rid off rpaths, I need to look at this one.
I'll do a bit of digging into these issues, learn up on
rpm-building,
and hopefully get the perl-5.16.1 SCL package built on CentOS/RHEL 5.
Then I'll start on SCL-izing 5.8.8 on CentOS 5.8.
Andrew
_______________________________________________
softwarecollections mailing list
softwarecollections(a)lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/softwarecollections
Thanks for suggestions, I'll add it into my packages.
--
Marcela