RPM Community Forums

Mailing List Message of <rpm-devel>

Re: upgrading from RPM 4 to RPM 5

From: Jeff Johnson <n3npq@mac.com>
Date: Mon 31 Dec 2007 - 15:03:26 CET
Message-Id: <8B617233-E50E-4891-ADB9-F5503E4D2364@mac.com>

On Dec 31, 2007, at 8:52 AM, Ralf S. Engelschall wrote:

>
> Perhaps a difference between RPM 4.2 (me) and 4.5 (you)?
>

Here's the current rpm-5.0 logic in lib/psm.c:

     isSource =
         (headerIsEntry(h, RPMTAG_SOURCERPM) == 0 &&
          headerIsEntry(h, RPMTAG_ARCH) != 0);

     if (!isSource) {
         rpmlog(RPMLOG_ERR, _("source package expected, binary found 
\n"));
         rpmrc = RPMRC_FAIL;
         goto exit;
     }

There have been several changes since rpm-4.2 detecting srpms,
all to get uncoupled from the vestigial lead structure (which was the
original test for a src rpm), and to stop adding an additional tag  
explicitly
(testing on non-existence of RPMTAG_SOURCERPM is sufficient to
detect a srpm).

Likeliest failure I can think of is that the lead value is no longer  
set.
I can/will send you a patch, but the lead is/was "an abandoned data  
structure"
(quoting from "Maximum RPM" published in 1997) and its way way past
time to nuke the sucker.

73 de Jeff
Received on Mon Dec 31 15:03:52 2007
Driven by Jeff Johnson and the RPM project team.
Hosted by OpenPKG and Ralf S. Engelschall.
Powered by FreeBSD and OpenPKG.