From ded3a0f8442be3b97eae95d23da77f6aaa96b6d9 Mon Sep 17 00:00:00 2001 From: root Date: Thu, 22 Aug 1996 21:04:33 +0000 Subject: [PATCH] only rm -rf docdir if we've got a %doc CVS patchset: 983 CVS date: 1996/08/22 21:04:33 --- build/spec.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/build/spec.c b/build/spec.c index 80158fe..b1c119a 100644 --- a/build/spec.c +++ b/build/spec.c @@ -497,9 +497,11 @@ static void generateNamesAndDocScript(Spec s) appendStringBuf(s->doc, "DOCDIR=$RPM_ROOT_DIR/$RPM_DOC_DIR/"); sprintf(fullname, "%s-%s-%s", name, packageVersion, packageRelease); appendLineStringBuf(s->doc, fullname); - appendLineStringBuf(s->doc, "rm -rf $DOCDIR"); docs = getStringBuf(package->doc); - appendLineStringBuf(s->doc, docs); + if (*docs) { + appendLineStringBuf(s->doc, "rm -rf $DOCDIR"); + appendLineStringBuf(s->doc, docs); + } package = package->next; } -- 2.7.4