public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Panu Matilainen <pmatilai@fedoraproject.org>
To: git-commits@fedoraproject.org
Subject: [rpms/rpm] pmatilai-v6: - load macros before creating directories on src.rpm install (#489104)
Date: Mon, 23 Nov 2026 09:25:42 GMT [thread overview]
Message-ID: <179542594282.1.8879838135736487088.rpms-rpm-fc85648d1ed1@fedoraproject.org> (raw)
A new commit has been pushed.
Repo : rpms/rpm
Branch : pmatilai-v6
Commit : fc85648d1ed1b589d7345eaa5eb5f9feea5965f7
Author : Panu Matilainen <pmatilai@fedoraproject.org>
Date : 2009-03-08T09:52:55+00:00
Stats : +39/-1 in 2 file(s)
URL : https://src.fedoraproject.org/rpms/rpm/c/fc85648d1ed1b589d7345eaa5eb5f9feea5965f7?branch=pmatilai-v6
Log:
- load macros before creating directories on src.rpm install (#489104)
---
diff --git a/rpm-4.7.0-beta1-srcrpm-macros.patch b/rpm-4.7.0-beta1-srcrpm-macros.patch
new file mode 100644
index 0000000..9b66e5e
--- /dev/null
+++ b/rpm-4.7.0-beta1-srcrpm-macros.patch
@@ -0,0 +1,32 @@
+commit 7a813e149fe40bbb9beee7dbf9898ab0c1906da2
+Author: Panu Matilainen <pmatilai@redhat.com>
+Date: Sun Mar 8 11:33:22 2009 +0200
+
+ Load macros before creating directories (rhbz#489104)
+ - %_sourcedir and friends can have things like %{name}, load macros
+ before trying to create any directories when installing src.rpms
+ (cherry picked from commit ac7c3412278a03da6633758bca999827d4b59038)
+
+diff --git a/lib/psm.c b/lib/psm.c
+index 3b2fd7c..112d344 100644
+--- a/lib/psm.c
++++ b/lib/psm.c
+@@ -275,6 +275,9 @@ rpmRC rpmInstallSourcePackage(rpmts ts, FD_t fd,
+ if (rootdir && strcmp(rootdir, "/") == 0)
+ rootdir = NULL;
+
++ /* Macros need to be added before trying to create directories */
++ rpmInstallLoadMacros(h);
++
+ if (specix >= 0) {
+ const char *bn;
+
+@@ -301,8 +304,6 @@ rpmRC rpmInstallSourcePackage(rpmts ts, FD_t fd,
+ goto exit;
+ }
+
+- rpmInstallLoadMacros(h);
+-
+ te = rpmtsElement(ts, 0);
+ if (te == NULL) { /* XXX can't happen */
+ goto exit;
diff --git a/rpm.spec b/rpm.spec
index dd2df48..ad3074e 100644
--- a/rpm.spec
+++ b/rpm.spec
@@ -25,7 +25,7 @@
Summary: The RPM package management system
Name: rpm
Version: %{rpmver}
-Release: 0.%{snapver}.1%{?dist}
+Release: 0.%{snapver}.2%{?dist}
Group: System Environment/Base
Url: http://www.rpm.org/
Source0: http://rpm.org/releases/testing/%{name}-%{srcver}.tar.bz2
@@ -43,6 +43,7 @@ Patch2: rpm-4.5.90-gstreamer-provides.patch
Patch3: rpm-4.6.0-fedora-specspo.patch
# Patches already in upstream
+Patch200: rpm-4.7.0-beta1-srcrpm-macros.patch
# These are not yet upstream
Patch300: rpm-4.7.0-extra-provides.patch
@@ -183,6 +184,8 @@ that will manipulate RPM packages and databases.
%patch2 -p1 -b .gstreamer-prov
%patch3 -p1 -b .fedora-specspo
+%patch200 -p1 -b .srcrpm-macros
+
%patch300 -p1 -b .extra-prov
%if %{with int_bdb}
@@ -388,6 +391,9 @@ exit 0
%doc doc/librpm/html/*
%changelog
+* Sun Mar 08 2009 Panu Matilainen <pmatilai@redhat.com> - 4.7.0-0.beta1.2
+- load macros before creating directories on src.rpm install (#489104)
+
* Fri Mar 06 2009 Panu Matilainen <pmatilai@redhat.com> - 4.7.0-0.beta1.1
- update to 4.7.0-beta1 (http://rpm.org/wiki/Releases/4.7.0)
reply other threads:[~2026-11-23 9:25 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=179542594282.1.8879838135736487088.rpms-rpm-fc85648d1ed1@fedoraproject.org \
--to=pmatilai@fedoraproject.org \
--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