summaryrefslogtreecommitdiff
path: root/build
diff options
context:
space:
mode:
Diffstat (limited to 'build')
-rw-r--r--build/build.c2
-rw-r--r--build/files.c3
2 files changed, 3 insertions, 2 deletions
diff --git a/build/build.c b/build/build.c
index 61fe6094e..a60233c2b 100644
--- a/build/build.c
+++ b/build/build.c
@@ -68,7 +68,7 @@ struct Script *openScript(Spec spec, int builddir, char *name)
fprintf(script->file, "RPM_SOURCE_DIR=\"%s\"\n", getVar(RPMVAR_SOURCEDIR));
fprintf(script->file, "RPM_BUILD_DIR=\"%s\"\n", getVar(RPMVAR_BUILDDIR));
- fprintf(script->file, "RPM_DOC_DIR=\"/usr/doc\"\n");
+ fprintf(script->file, "RPM_DOC_DIR=\"%s\"\n", getVar(RPMVAR_DEFAULTDOCDIR));
fprintf(script->file, "RPM_OPT_FLAGS=\"%s\"\n", getVar(RPMVAR_OPTFLAGS));
fprintf(script->file, "RPM_ARCH=\"%s\"\n", getArchName());
fprintf(script->file, "RPM_OS=\"%s\"\n", getOsName());
diff --git a/build/files.c b/build/files.c
index 9258a7201..3c8d9f0ca 100644
--- a/build/files.c
+++ b/build/files.c
@@ -176,7 +176,8 @@ int process_filelist(Header header, struct PackageRec *pr,
"Can't mix special %%doc with other forms: %s", fp);
return(RPMERR_BADSPEC);
}
- sprintf(buf, "/usr/doc/%s-%s-%s", name, version, release);
+ sprintf(buf, "%s/%s-%s-%s", getVar(RPMVAR_DEFAULTDOCDIR),
+ name, version, release);
filename = buf;
passed_special_doc = 1;
}