RPM Community Forums

Mailing List Message of <rpm-cvs>

[CVS] RPM: rpm/ CHANGES TODO rpm/build/ parseSpec.c rpmbuild.h

From: Jeff Johnson <jbj@rpm5.org>
Date: Wed 21 Nov 2007 - 00:50:56 CET
Message-Id: <20071120235056.8912834845C@rpm5.org>
  RPM Package Manager, CVS Repository
  http://rpm5.org/cvs/
  ____________________________________________________________________________

  Server: rpm5.org                         Name:   Jeff Johnson
  Root:   /v/rpm/cvs                       Email:  jbj@rpm5.org
  Module: rpm                              Date:   21-Nov-2007 00:50:56
  Branch: HEAD                             Handle: 2007112023505501

  Modified files:
    rpm                     CHANGES TODO
    rpm/build               parseSpec.c rpmbuild.h

  Log:
    - jbj: rebase rpmParseState_e +256 to permit rpmRC to be returned too.

  Summary:
    Revision    Changes     Path
    1.1859      +1  -0      rpm/CHANGES
    1.21        +0  -4      rpm/TODO
    2.114       +2  -2      rpm/build/parseSpec.c
    2.77        +24 -23     rpm/build/rpmbuild.h
  ____________________________________________________________________________

  patch -p0 <<'@@ .'
  Index: rpm/CHANGES
  ============================================================================
  $ cvs diff -u -r1.1858 -r1.1859 CHANGES
  --- rpm/CHANGES	20 Nov 2007 23:02:50 -0000	1.1858
  +++ rpm/CHANGES	20 Nov 2007 23:50:55 -0000	1.1859
  @@ -1,4 +1,5 @@
   5.0a2 -> 5.0a3:
  +    - jbj: rebase rpmParseState_e +256 to permit rpmRC to be returned too.
       - jbj: remove headerWrite() from the public API, use rpmpkgWrite instead.
       - jbj: convert last headerWrite to use rpmpkgWrite instead.
       - jbj: conver 2 (of 9 remaining) headerRead's to use rpmpkgRead instead.
  @@ .
  patch -p0 <<'@@ .'
  Index: rpm/TODO
  ============================================================================
  $ cvs diff -u -r1.20 -r1.21 TODO
  --- rpm/TODO	19 Nov 2007 20:02:37 -0000	1.20
  +++ rpm/TODO	20 Nov 2007 23:50:55 -0000	1.21
  @@ -63,10 +63,6 @@
   	"works", but not same FC8 package converted using txar and FC8 pubkey
   	verify.
       - jbj: check that rpmbuild --sign is functional, or eliminate the option.
  -    - jbj: parsing error paths (like missing source or patch file) are
  -	returning rpmRC in some cases now, with accidental collision with
  -	PART_FOO values that drive the spec file parser. Renumbering enum
  -	rpmParseState to avoid the collisions should fix most of the problem.
       - jbj: choose between db-4.5.20 and db-4.6.18. db-4.5.20 may have fewer
   	upgrade/downgrade issues because of the db-4.6.18 DB_HASH change,
   	but rpm-5.0 already uses DB_BTREE for Packages.
  @@ .
  patch -p0 <<'@@ .'
  Index: rpm/build/parseSpec.c
  ============================================================================
  $ cvs diff -u -r2.113 -r2.114 parseSpec.c
  --- rpm/build/parseSpec.c	10 Nov 2007 18:06:41 -0000	2.113
  +++ rpm/build/parseSpec.c	20 Nov 2007 23:50:56 -0000	2.114
  @@ -478,7 +478,7 @@
       /* which handles the initial entry into a spec file.         */
       
       /*@-infloops@*/	/* LCL: parsePart is modified @*/
  -    while (parsePart < PART_LAST && parsePart != PART_NONE) {
  +    while (parsePart < PART_LAST && parsePart > PART_NONE) {
   	switch (parsePart) {
   	case PART_PREAMBLE:
   	    parsePart = parsePreamble(spec, initialPackage);
  @@ -524,7 +524,7 @@
   	    /*@switchbreak@*/ break;
   	}
   
  -	if (parsePart >= PART_LAST) {
  +	if (parsePart < PART_NONE || parsePart >= PART_LAST) {
   	    spec = freeSpec(spec);
   	    return parsePart;
   	}
  @@ .
  patch -p0 <<'@@ .'
  Index: rpm/build/rpmbuild.h
  ============================================================================
  $ cvs diff -u -r2.76 -r2.77 rpmbuild.h
  --- rpm/build/rpmbuild.h	19 Nov 2007 17:07:46 -0000	2.76
  +++ rpm/build/rpmbuild.h	20 Nov 2007 23:50:56 -0000	2.77
  @@ -47,30 +47,31 @@
   /** \ingroup rpmbuild
    * Spec file parser states.
    */
  +#define	PART_BASE	256
   typedef enum rpmParseState_e {
  -    PART_NONE		=  0,	/*!< */
  -    PART_PREAMBLE	=  1,	/*!< */
  -    PART_PREP		=  2,	/*!< */
  -    PART_BUILD		=  3,	/*!< */
  -    PART_INSTALL	=  4,	/*!< */
  -    PART_CHECK		=  5,	/*!< */
  -    PART_CLEAN		=  6,	/*!< */
  -    PART_FILES		=  7,	/*!< */
  -    PART_PRE		=  8,	/*!< */
  -    PART_POST		=  9,	/*!< */
  -    PART_PREUN		= 10,	/*!< */
  -    PART_POSTUN		= 11,	/*!< */
  -    PART_PRETRANS	= 12,	/*!< */
  -    PART_POSTTRANS	= 13,	/*!< */
  -    PART_DESCRIPTION	= 14,	/*!< */
  -    PART_CHANGELOG	= 15,	/*!< */
  -    PART_TRIGGERIN	= 16,	/*!< */
  -    PART_TRIGGERUN	= 17,	/*!< */
  -    PART_VERIFYSCRIPT	= 18,	/*!< */
  -    PART_BUILDARCHITECTURES= 19,/*!< */
  -    PART_TRIGGERPOSTUN	= 20,	/*!< */
  -    PART_TRIGGERPREIN	= 21,	/*!< */
  -    PART_LAST		= 22	/*!< */
  +    PART_NONE		=  0+PART_BASE,	/*!< */
  +    PART_PREAMBLE	=  1+PART_BASE,	/*!< */
  +    PART_PREP		=  2+PART_BASE,	/*!< */
  +    PART_BUILD		=  3+PART_BASE,	/*!< */
  +    PART_INSTALL	=  4+PART_BASE,	/*!< */
  +    PART_CHECK		=  5+PART_BASE,	/*!< */
  +    PART_CLEAN		=  6+PART_BASE,	/*!< */
  +    PART_FILES		=  7+PART_BASE,	/*!< */
  +    PART_PRE		=  8+PART_BASE,	/*!< */
  +    PART_POST		=  9+PART_BASE,	/*!< */
  +    PART_PREUN		= 10+PART_BASE,	/*!< */
  +    PART_POSTUN		= 11+PART_BASE,	/*!< */
  +    PART_PRETRANS	= 12+PART_BASE,	/*!< */
  +    PART_POSTTRANS	= 13+PART_BASE,	/*!< */
  +    PART_DESCRIPTION	= 14+PART_BASE,	/*!< */
  +    PART_CHANGELOG	= 15+PART_BASE,	/*!< */
  +    PART_TRIGGERIN	= 16+PART_BASE,	/*!< */
  +    PART_TRIGGERUN	= 17+PART_BASE,	/*!< */
  +    PART_VERIFYSCRIPT	= 18+PART_BASE,	/*!< */
  +    PART_BUILDARCHITECTURES= 19+PART_BASE,/*!< */
  +    PART_TRIGGERPOSTUN	= 20+PART_BASE,	/*!< */
  +    PART_TRIGGERPREIN	= 21+PART_BASE,	/*!< */
  +    PART_LAST		= 22+PART_BASE	/*!< */
   } rpmParseState;
   
   #define STRIP_NOTHING             0
  @@ .
Received on Wed Nov 21 00:50:56 2007
Driven by Jeff Johnson and the RPM project team.
Hosted by OpenPKG and Ralf S. Engelschall.
Powered by FreeBSD and OpenPKG.