代码拉取完成,页面将自动刷新
From af9a2347cd725a8dbb6045d7d3e9661d524af110 Mon Sep 17 00:00:00 2001
From: openEuler Buildteam <buildteam@openeuler.org>
Date: Wed, 4 Mar 2020 16:12:58 +0800
Subject: [PATCH] add dist to release by default
---
build/parsePreamble.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/build/parsePreamble.c b/build/parsePreamble.c
index b0a17c8..cac899a 100644
--- a/build/parsePreamble.c
+++ b/build/parsePreamble.c
@@ -808,6 +808,11 @@ static rpmRC handlePreambleTag(rpmSpec spec, Package pkg, rpmTagVal tag,
case RPMTAG_VERSION:
case RPMTAG_RELEASE:
SINGLE_TOKEN_ONLY;
+ if (tag == RPMTAG_RELEASE) {
+ char *dist = rpmExpand("%{?dist}",NULL);
+ rasprintf(&field,"%s%s",field,dist);
+ free(dist);
+ }
if (rpmCharCheck(spec, field, ALLOWED_CHARS_VERREL, NULL))
goto exit;
headerPutString(pkg->header, tag, field);
@@ -987,6 +992,8 @@ static rpmRC handlePreambleTag(rpmSpec spec, Package pkg, rpmTagVal tag,
}
rc = RPMRC_OK;
exit:
+ if (tag == RPMTAG_RELEASE)
+ free(field);
return rc;
}
--
1.8.3.1
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。