[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Ltib] (more) LTIB on Gentoo
From: |
Stuart Hughes |
Subject: |
Re: [Ltib] (more) LTIB on Gentoo |
Date: |
Wed, 29 Aug 2007 10:30:15 +0100 |
Hi Frank,
Thanks for your patches. Looking at your version number this would seem
to be from a Freescale ISO, is this correct?
Looking at your first patch bin/Ltibutils.pm, I still think that there
needs to be a check for libstdc++, even for gcc4. However if you look
at the latest savannah CVS, you'll see there was a change made to the
criteria from more than one file to just one (or more). I think this is
correct.
As far as libstdc++-devel goes, there was a hack that just ignored the
test if it detected "/usr/portage".
While I think your checks are technically more correct, I think it's
better to leave as-is for simplicity. The diffs for that section that
went into ltib at Savannah are attached.
As far as the ltib patch goes:
pkg_iterate();
- $cf->{sn} = "";
+ #$cf->{sn} = "";
The idea was that having set $cf->{sn} a few lines up to force a single
package build in short-circuit mode, it then clears it. Probably this
should be a restore to whatever it already was before being force set.
I'm thinking of something like:
@@ -624,6 +624,7 @@
TXT
if($cf->{mode} eq 'buildrpms') {
warn "scbuild/scdeploy already unpacked package\n";
+ my $osn = $cf->{sn};
$cf->{sn} = $sn;
pkg_iterate($cf->{sn});
$cf->{nounpack} = 1;
@@ -631,7 +632,7 @@
$cf->{leavesrc} = 0;
$cf->{nounpack} = 0;
pkg_iterate();
- $cf->{sn} = "";
+ $cf->{sn} = $osn;
The pfx change is rejected because rpm-fs.spec and any others that don't
define %pfx are special cases whereby the rpm is not relocatable (it has
no 'Prefix : ...' tag. In the scdeploy you should not change a
non-relocatable rpm to be relocatable.
I agree there is a bug here, but what I should change is to make rpm-fs
(and any other non-relocatable rpm) refuse to resume an aborted build.
I have this down in by TODO list.
Thanks very much for your efforts and comments as they really help.
Regards, Stuart
On Tue, 2007-08-28 at 15:28 -0400, Frank Szczerba wrote:
> I know this has been visited before, but ran into a few issues using
> ltib on Gentoo that I didn't see mentioned in the archives, or in some
> cases arrived at some slightly different conclusions about the fix for
> these issues. My ltib is:
>
> ------------------------------------------------------------------------
> ----
> $ ./ltib --version
> ltib 6.4.1 ($Revision: 1.228.2.8 $)
> Copyright (C) 2004-2006 Freescale Semiconductor, Inc.
> This is free software; it is licensed under the terms of the
> GNU General Public License, see 'COPYING' for the license. There is NO
> warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR
> PURPOSE.
> ------------------------------------------------------------------------
> ----
>
> My first issue was the "libstdc++/libstdc++-devel" issue. According to
> the package description in Gentoo, this library only applies to gcc 3.
> If gcc 4 is being used there should be no need for it, so I did
>
> 'libstdc++' => sub {
> my $gver = get_ver('gcc-c++');
> if (cmp_ver($gver, '4.0') < 0) {
> my @f = glob('/usr/lib/libstdc++*');
> return @f > 1 ? 1 : 0 ;
> } else {
> return $gver;
> }
> },
>
> with a similar change for libstdc++-devel (see libutils.patch,
> attached).
>
> I then fixed the rpm magic error discussed earlier (I see now that this
> is actually fixed in the new ebuild, but it's not marked stable so I
> didn't have it installed).
>
> I then ran into another error in rpm-fs, this one due to the lack of a
> "pfx" token in the spec file. I changed the regeneration of the spec
> file in f_scdeploy() to not skip the %define and Prefix : lines if this
> was not defined (see ltib.patch, attached).
>
> The last issue I ran into, which was probably due to repeatedly running
> ltib without cleaning out /tmp/rpm*, was due to f_buildrpms() clearing
> $cf->{sn} if the package was already unpacked. I just commented out this
> line and everything seemed to be ok (though I wonder if the $cf->{sn} =
> $sn line is right as well).
>
> Everything seems to build nicely now (well, at least the stuff I've
> tried so far).
>
> Hope this helps someone!
>
> Frank
>
> _______________________________________________
> LTIB home page: http://bitshrine.org
>
> Ltib mailing list
> address@hidden
> http://lists.nongnu.org/mailman/listinfo/ltib
ltib_utils-gentoo.patch
Description: Text Data