skip arch checks if only packaging source rpm.
CVS patchset: 2352 CVS date: 1998/09/24 20:36:54
This commit is contained in:
parent
d6a3e244e0
commit
54b2849f61
1
CHANGES
1
CHANGES
|
@ -14,6 +14,7 @@
|
|||
- add new fully recursive macro.c
|
||||
|
||||
2.5.3 -> 2.5.4:
|
||||
- skip arch checks if only packaging source rpm.
|
||||
- add license field to rpmpopt -qi alias.
|
||||
- provides/obsoletes requires tokens that begin with alnum or _.
|
||||
- non-zero exit status for verify failures.
|
||||
|
|
8
build.c
8
build.c
|
@ -129,9 +129,13 @@ int buildplatform(char *arg, int buildAmount, char *passPhrase,
|
|||
s++;
|
||||
}
|
||||
|
||||
if (parseSpec(&spec, specfile, buildRoot, 0, passPhrase, cookie)) {
|
||||
return 1;
|
||||
#define _anyarch(_f) \
|
||||
(((_f)&(RPMBUILD_PACKAGESOURCE|RPMBUILD_PACKAGEBINARY)) == RPMBUILD_PACKAGESOURCE)
|
||||
if (parseSpec(&spec, specfile, buildRoot, 0, passPhrase, cookie,
|
||||
_anyarch(buildAmount))) {
|
||||
return 1;
|
||||
}
|
||||
#undef _anyarch
|
||||
|
||||
if (buildSpec(spec, buildAmount, test)) {
|
||||
freeSpec(spec);
|
||||
|
|
|
@ -626,7 +626,7 @@ static int findPreambleTag(Spec spec, int *tag, char **macro, char *lang)
|
|||
return 0;
|
||||
}
|
||||
|
||||
int parsePreamble(Spec spec, int initialPackage)
|
||||
int parsePreamble(Spec spec, int initialPackage, int anyarch)
|
||||
{
|
||||
int nextPart;
|
||||
int tag, rc;
|
||||
|
@ -705,8 +705,9 @@ int parsePreamble(Spec spec, int initialPackage)
|
|||
return RPMERR_BADSPEC;
|
||||
}
|
||||
|
||||
if (checkForValidArchitectures(spec)) {
|
||||
return RPMERR_BADSPEC;
|
||||
/* XXX Skip valid arch check if only doing -bs processing */
|
||||
if (!anyarch && checkForValidArchitectures(spec)) {
|
||||
return RPMERR_BADSPEC;
|
||||
}
|
||||
|
||||
if (pkg == spec->packages) {
|
||||
|
|
|
@ -214,7 +214,8 @@ void closeSpec(Spec spec)
|
|||
int noLang = 0; /* XXX FIXME: pass as arg */
|
||||
|
||||
int parseSpec(Spec *specp, char *specFile, char *buildRoot,
|
||||
int inBuildArch, char *passPhrase, char *cookie)
|
||||
int inBuildArch, char *passPhrase, char *cookie,
|
||||
int anyarch)
|
||||
{
|
||||
int parsePart = PART_PREAMBLE;
|
||||
int initialPackage = 1;
|
||||
|
@ -266,7 +267,7 @@ int parseSpec(Spec *specp, char *specFile, char *buildRoot,
|
|||
while (parsePart != PART_NONE) {
|
||||
switch (parsePart) {
|
||||
case PART_PREAMBLE:
|
||||
parsePart = parsePreamble(spec, initialPackage);
|
||||
parsePart = parsePreamble(spec, initialPackage, anyarch);
|
||||
initialPackage = 0;
|
||||
break;
|
||||
case PART_PREP:
|
||||
|
@ -319,7 +320,7 @@ int parseSpec(Spec *specp, char *specFile, char *buildRoot,
|
|||
rpmSetMachine(spec->buildArchitectures[x], NULL);
|
||||
if (parseSpec(&(spec->buildArchitectureSpecs[index]),
|
||||
specFile, buildRoot, 1,
|
||||
passPhrase, cookie)) {
|
||||
passPhrase, cookie, anyarch)) {
|
||||
spec->buildArchitectureCount = index;
|
||||
freeSpec(spec);
|
||||
return RPMERR_BADSPEC;
|
||||
|
|
|
@ -104,7 +104,7 @@ char *cleanFileName(char *name);
|
|||
int parseChangelog(Spec spec);
|
||||
int parseDescription(Spec spec);
|
||||
int parseFiles(Spec spec);
|
||||
int parsePreamble(Spec spec, int initialPackage);
|
||||
int parsePreamble(Spec spec, int initialPackage, int anyarch);
|
||||
int parsePrep(Spec spec);
|
||||
int parseRequiresConflicts(Spec spec, Package pkg, char *field,
|
||||
int tag, int index);
|
||||
|
@ -137,7 +137,7 @@ int processSourceFiles(Spec spec);
|
|||
/* global entry points */
|
||||
|
||||
int parseSpec(Spec *specp, char *specFile, char *buildRoot,
|
||||
int inBuildArch, char *passPhrase, char *cookie);
|
||||
int inBuildArch, char *passPhrase, char *cookie, int anyarch);
|
||||
int buildSpec(Spec spec, int what, int test);
|
||||
|
||||
int packageBinaries(Spec spec);
|
||||
|
|
Loading…
Reference in New Issue