public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Lubos Kardos <lkardos@redhat.com>
To: git-commits@fedoraproject.org
Subject: [rpms/rpm] pmatilai-v6: - Fix %autosetup not to cause errors during run of rpmspec tool
Date: Mon, 23 Nov 2026 09:29:48 GMT [thread overview]
Message-ID: <179542618802.1.1139567723967912986.rpms-rpm-a0329136e36d@fedoraproject.org> (raw)
A new commit has been pushed.
Repo : rpms/rpm
Branch : pmatilai-v6
Commit : a0329136e36d22e3668da59a1f5e38dd5dc63910
Author : Lubos Kardos <lkardos@redhat.com>
Date : 2016-01-19T16:20:24+01:00
Stats : +47/-1 in 2 file(s)
URL : https://src.fedoraproject.org/rpms/rpm/c/a0329136e36d22e3668da59a1f5e38dd5dc63910?branch=pmatilai-v6
Log:
- Fix %autosetup not to cause errors during run of rpmspec tool
- Resolves: #1293687
---
diff --git a/rpm-4.13.0-autosetup-errors.patch b/rpm-4.13.0-autosetup-errors.patch
new file mode 100644
index 0000000..dacde03
--- /dev/null
+++ b/rpm-4.13.0-autosetup-errors.patch
@@ -0,0 +1,42 @@
+From 231a7213b90a8dfba426737732e2dc6e62acfbad Mon Sep 17 00:00:00 2001
+From: Lubos Kardos <lkardos@redhat.com>
+Date: Tue, 19 Jan 2016 14:37:07 +0100
+Subject: [PATCH] Fix %autosetup to not cause errors during run of rpmspec tool
+
+Firstly %autosetup showed an error during its expansion if some patch
+wasn't available, that is an error was showed during parsing of a spec
+file. This caused showing an error during execution of rpmspec
+tool (rhbz:1293687).
+
+Now %autosetup doesn't cause an error during parsing of a spec file but
+it causes an error during building of specfile if some patch is not
+available. Also old macro %patch behaves similarly.
+---
+ macros.in | 11 +++++++++--
+ 1 file changed, 9 insertions(+), 2 deletions(-)
+
+diff --git a/macros.in b/macros.in
+index 319a1a3..f11affe 100644
+--- a/macros.in
++++ b/macros.in
+@@ -1122,8 +1122,15 @@ done \
+
+ # Single patch application
+ %apply_patch(qp:m:)\
+-test -f %{1} || exit 1 ; \
+-%{uncompress:%{1}} | %{expand:%__scm_apply_%{__scm} %{-q} %{-p:-p%{-p*}} %{-m:-m%{-m*}}}
++%{lua:\
++local file = rpm.expand("%{1}")\
++if posix.access(file, "r") then\
++ local options = rpm.expand("%{-q} %{-p:-p%{-p*}} %{-m:-m%{-m*}}")\
++ local scm_apply = rpm.expand("%__scm_apply_%{__scm}")\
++ print(rpm.expand("%{uncompress:"..file.."} | "..scm_apply.." "..options.."\\n"))\
++else\
++ print("echo 'Cannot read "..file.."'; exit 1;".."\\n")\
++end}
+
+ # Automatically apply all patches
+ %autopatch(vp:)\
+--
+1.9.3
+
diff --git a/rpm.spec b/rpm.spec
index 996452e..8f05815 100644
--- a/rpm.spec
+++ b/rpm.spec
@@ -29,7 +29,7 @@
Summary: The RPM package management system
Name: rpm
Version: %{rpmver}
-Release: %{?snapver:0.%{snapver}.}16%{?dist}
+Release: %{?snapver:0.%{snapver}.}17%{?dist}
Group: System Environment/Base
Url: http://www.rpm.org/
Source0: http://rpm.org/releases/rpm-4.12.x/%{name}-%{srcver}.tar.bz2
@@ -66,6 +66,7 @@ Patch110: rpm-4.13.0-disabling-filetriggers.patch
Patch111: rpm-4.13.0-chroot-file-triggers.patch
Patch112: rpm-4.13.0-missingok.patch
Patch113: rpm-4.13.0-recursing-rpmdeps.patch
+Patch114: rpm-4.13.0-autosetup-errors.patch
# These are not yet upstream
Patch302: rpm-4.7.1-geode-i686.patch
@@ -570,6 +571,9 @@ exit 0
%doc doc/librpm/html/*
%changelog
+* Tue Jan 19 2016 Lubos Kardos <lkardos@redhat.com> - 4.13.0-0.rc1.17
+- Fix %autosetup not to cause errors during run of rpmspec tool (#1293687)
+
* Fri Jan 15 2016 Lubos Kardos <lkardos@redhat.com> - 4.13.0-0.rc1.16
- Fix recursive calling of rpmdeps tool (#1297557)
reply other threads:[~2026-11-23 9:29 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=179542618802.1.1139567723967912986.rpms-rpm-a0329136e36d@fedoraproject.org \
--to=lkardos@redhat.com \
--cc=git-commits@fedoraproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox