Compare commits

...

16 Commits
master ... f25

Author SHA1 Message Date
Panu Matilainen f8de97529b Oops, remove upstreamed patches 2017-11-02 09:33:51 +02:00
Panu Matilainen 99a58c7873 Update to rpm 4.13.02 2017-11-02 08:25:33 +02:00
Panu Matilainen b00ec5cf69 Bunch of fixes from upstream/F26
- Really ignore unknown tags in the signature header (#1480492)
- Fix rpmsign python module import failing (#1462671)
- Fix rpmbuild world writable empty (tmp) dirs in debuginfo (#641022)
- Fix testsuite with recent NSS-versions
2017-08-16 16:14:55 +03:00
Panu Matilainen 074cc434a3 Rebase to rpm 4.13.0.1 (http://rpm.org/wiki/Releases/4.13.0.1)
Fixes #1410907, #1405570, #1399798, #1410907 etc
2017-02-24 14:43:54 +02:00
Tomas Orsava 7a20d1f47a Fix handling of Python wheels by pythondistdeps.py --provides (#1421776) 2017-02-16 14:11:23 +01:00
Igor Gnatenko 46fcd24c85 Merge branch 'master' into f25 2016-12-03 13:24:51 +01:00
Igor Gnatenko 4e36c2ed98 Merge branch 'master' into f25 2016-11-25 13:35:49 +01:00
Panu Matilainen 82cab847ba Merge branch 'master' into f25
* master: (3 commits)
  Expand python subpackage obsoletion range (related: #1394125)
  ...
2016-11-11 11:05:57 +02:00
Panu Matilainen 79ffddb45a Merge branch 'master' into f25
* master: (11 commits)
  Rebase to rpm 4.13.0 final
  ...
2016-11-03 14:09:05 +02:00
Richard W.M. Jones f686f71af8 Add upstream patches for riscv64 architecture support.
These two patches are upstream already.  A third patch is also
upstream, but it is not needed with the older RPM we have, so I didn't
include it.
2016-09-23 15:36:12 +01:00
Igor Gnatenko 82de465ada Backport patch for missing import in Python dependency generator
Signed-off-by: Igor Gnatenko <ignatenko@redhat.com>
2016-08-24 15:49:24 +02:00
Kalev Lember 1149cd0ac5 Fix -python2 and -python3 subpackage obsoleting from .42 2016-08-24 11:38:04 +02:00
Igor Gnatenko 850ff7d23b Use %%python_provide for python3 subpackage
Signed-off-by: Igor Gnatenko <ignatenko@redhat.com>
2016-08-23 12:02:17 +02:00
Igor Gnatenko 5123e762e6 Add %%{?system_python_abi}; Fixes and cleanups
Signed-off-by: Igor Gnatenko <ignatenko@redhat.com>
2016-08-23 12:00:45 +02:00
Igor Gnatenko 74d17c17f7 Backport fixes to ignore .egg-link files in Python dependency generator
Signed-off-by: Igor Gnatenko <ignatenko@redhat.com>
2016-08-22 16:20:28 +02:00
Florian Festi 6536d6c3d4 - Enable --majorver-provides in Python dependency generator 2016-08-12 11:17:28 +02:00
6 changed files with 174 additions and 44 deletions

2
.gitignore vendored
View File

@ -22,3 +22,5 @@
/rpm-4.13.0-rc1.tar.bz2
/rpm-4.13.0-rc2.tar.bz2
/rpm-4.13.0.tar.bz2
/rpm-4.13.0.1.tar.bz2
/rpm-4.13.0.2.tar.bz2

View File

@ -0,0 +1,43 @@
From ff395f4a820497a443baa6cd0198c49b06207c3f Mon Sep 17 00:00:00 2001
From: Tomas Orsava <torsava@redhat.com>
Date: Thu, 16 Feb 2017 11:36:29 +0100
Subject: [PATCH] Fix pythondistdeps.py --provides for Python wheels
As Python wheels do not contain targetted Python version in the directory/file
name of their metadata like Python eggs do, and since the Python version is not
contained in the metadata either, it is necessary to get it from elsewhere.
Here it is parsed from the path the metadata resides at
(e.g. /usr/lib/pythonX.Y/site-packages/...)
---
scripts/pythondistdeps.py | 13 ++++++++++---
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/scripts/pythondistdeps.py b/scripts/pythondistdeps.py
index e4b99e2..d44210c 100644
--- a/scripts/pythondistdeps.py
+++ b/scripts/pythondistdeps.py
@@ -107,10 +107,17 @@ for f in files:
path_item = f
metadata = FileMetadata(f)
dist = Distribution.from_location(path_item, dist_name, metadata)
- # Check if py_version is defined in the file
+ # Check if py_version is defined in the metadata file/directory name
if not dist.py_version:
- warn("Version for {!r} has not been found".format(dist), RuntimeWarning)
- continue
+ # Try to parse the Python version from the path the metadata
+ # resides at (e.g. /usr/lib/pythonX.Y/site-packages/...)
+ import re
+ res = re.search(r"/python(?P<pyver>\d+\.\d)/", path_item)
+ if res:
+ dist.py_version = res.group('pyver')
+ else:
+ warn("Version for {!r} has not been found".format(dist), RuntimeWarning)
+ continue
if (Provides_PyMajorVer_Variant or legacy_Provides or legacy) and Provides:
# Get the Python major version
pyver_major = dist.py_version.split('.')[0]
--
2.11.0

View File

@ -1,40 +0,0 @@
From f6521c50f6836374a0f7995f8f393aaf36e178ea Mon Sep 17 00:00:00 2001
Message-Id: <f6521c50f6836374a0f7995f8f393aaf36e178ea.1478522529.git.pmatilai@redhat.com>
From: Panu Matilainen <pmatilai@redhat.com>
Date: Mon, 7 Nov 2016 13:38:39 +0200
Subject: [PATCH] Fix %transfiletriggerpostun undeterministic behavior
(RhBug:1284645)
Keys from rpmdbIndexIteratorNext() are not necessarily \0-terminated,
buyer beware.
Sometimes you get lucky, but in particular when built as PIE (such as
by default in Fedora) this falls over consistently.
In Fedora this has been hidden by the fact that test suite has been
disabled because its been so broken with fakechroot until recently,
and without PIE the testsuite regularly passes. Valgrind does
complain though.
---
lib/rpmtriggers.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/lib/rpmtriggers.c b/lib/rpmtriggers.c
index a8612c0..ca22a6b 100644
--- a/lib/rpmtriggers.c
+++ b/lib/rpmtriggers.c
@@ -114,8 +114,11 @@ void rpmtriggersPrepPostUnTransFileTrigs(rpmts ts, rpmte te)
/* Iterate over file triggers in rpmdb */
while ((rpmdbIndexIteratorNext(ii, &key, &keylen)) == 0) {
+ char pfx[keylen + 1];
+ memcpy(pfx, key, keylen);
+ pfx[keylen] = '\0';
/* Check if file trigger matches any file in this te */
- rpmfi fi = rpmfilesFindPrefix(files, key);
+ rpmfi fi = rpmfilesFindPrefix(files, pfx);
if (rpmfiFC(fi) > 0) {
/* If yes then store it */
rpmdbAppendIterator(mi, rpmdbIndexIteratorPkgOffsets(ii),
--
2.7.4

View File

@ -0,0 +1,106 @@
commit c707ab26362e795d3f9dba4eb87dc7ed99a28bcb
Author: Robin Lee <cheeselee@fedoraproject.org>
Date: Sat Apr 8 21:21:39 2017 +0800
Fix non-standard inherented modes of directories in debuginfo
In case that binary compiled from source generated in /tmp, a
/usr/src/debug/tmp directory will be created with the same mode as
/tmp, a.k.a 777, which should be avoided.
Fixes: rhbz#641022
diff --git a/scripts/find-debuginfo.sh b/scripts/find-debuginfo.sh
old mode 100644
new mode 100755
index 547dbd9..6f38e19
--- a/scripts/find-debuginfo.sh
+++ b/scripts/find-debuginfo.sh
@@ -396,9 +396,10 @@
mkdir -p "${RPM_BUILD_ROOT}/usr/src/debug"
LC_ALL=C sort -z -u "$SOURCEFILE" | grep -E -v -z '(<internal>|<built-in>)$' |
(cd "$RPM_BUILD_DIR"; cpio -pd0mL "${RPM_BUILD_ROOT}/usr/src/debug")
- # stupid cpio creates new directories in mode 0700, fixup
+ # stupid cpio creates new directories in mode 0700,
+ # and non-standard modes may be inherented from original directories, fixup
find "${RPM_BUILD_ROOT}/usr/src/debug" -type d -print0 |
- xargs --no-run-if-empty -0 chmod a+rx
+ xargs --no-run-if-empty -0 chmod 0755
fi
if [ -d "${RPM_BUILD_ROOT}/usr/lib" -o -d "${RPM_BUILD_ROOT}/usr/src" ]; then
commit e795899780337dea751d85db8f381eff3fe75275
Author: Mark Wielaard <mark@klomp.org>
Date: Fri Apr 21 17:33:26 2017 +0200
debugedit: Only output comp_dir under build dir (once).
The fix for rhbz#444310 (commit c1a5eb - Include empty CU current dirs)
was a little greedy. It would also include comp_dirs outside the build
root. Those are unnecessary and we don't have a good way to store them.
Such dirs (e.g. /tmp) would then show up at the root of /usr/src/debug.
Fix this by including only comp_dirs under base_dir. Also only output
all dirs once (during phase zero) and don't output empty dirs (which
was harmless but would produce a warning from cpio).
This still includes all empty dirs from the original rhbz#444310
nodir testcase and it is an alternative fix for rhbz#641022
(commit c707ab).
Both fixes are necessary in case of an unexpected mode for a directory
actually in the build root that we want to include in the source list.
Signed-off-by: Mark Wielaard <mark@klomp.org>
diff --git a/tools/debugedit.c b/tools/debugedit.c
index 8444e03..bf11513 100644
--- a/tools/debugedit.c
+++ b/tools/debugedit.c
@@ -926,27 +926,29 @@
/* Ensure the CU current directory will exist even if only empty. Source
filenames possibly located in its parent directories refer relatively to
it and the debugger (GDB) cannot safely optimize out the missing
- CU current dir subdirectories. */
- if (comp_dir && list_file_fd != -1)
+ CU current dir subdirectories. Only do this once in phase one. And
+ only do this for dirs under our build/base_dir. Don't output the
+ empty string (in case the comp_dir == base_dir). */
+ if (phase == 0 && base_dir && comp_dir && list_file_fd != -1)
{
char *p;
size_t size;
- if (base_dir && has_prefix (comp_dir, base_dir))
- p = comp_dir + strlen (base_dir);
- else if (dest_dir && has_prefix (comp_dir, dest_dir))
- p = comp_dir + strlen (dest_dir);
- else
- p = comp_dir;
-
- size = strlen (p) + 1;
- while (size > 0)
+ if (has_prefix (comp_dir, base_dir))
{
- ssize_t ret = write (list_file_fd, p, size);
- if (ret == -1)
- break;
- size -= ret;
- p += ret;
+ char *p = comp_dir + strlen (base_dir);
+ if (p[0] != '\0')
+ {
+ size_t size = strlen (p) + 1;
+ while (size > 0)
+ {
+ ssize_t ret = write (list_file_fd, p, size);
+ if (ret == -1)
+ break;
+ size -= ret;
+ p += ret;
+ }
+ }
}
}

View File

@ -17,7 +17,7 @@
%define rpmhome /usr/lib/rpm
%global rpmver 4.13.0
%global rpmver 4.13.0.2
#global snapver rc2
%global srcver %{version}%{?snapver:-%{snapver}}
%global srcdir %{?snapver:testing}%{!?snapver:%{name}-%(v=%{version}; echo ${v%.*}.x)}
@ -29,7 +29,7 @@
Summary: The RPM package management system
Name: rpm
Version: %{rpmver}
Release: %{?snapver:0.%{snapver}.}6%{?dist}
Release: %{?snapver:0.%{snapver}.}1%{?dist}
Group: System Environment/Base
Url: http://www.rpm.org/
Source0: http://rpm.org/releases/%{srcdir}/%{name}-%{srcver}.tar.bz2
@ -52,7 +52,7 @@ Patch4: rpm-4.8.1-use-gpg2.patch
Patch5: rpm-4.12.0-rpm2cpio-hack.patch
# Patches already upstream:
Patch100: rpm-4.13.x-transfiletriggerpostun-invalid-read.patch
Patch103: rpm-4.13.x-writable-tmp-dir.patch
Patch133: rpm-4.13.x-pythondistdeps.patch
Patch134: rpm-4.13.x-pythondistdeps-Makefile.patch
@ -61,6 +61,9 @@ Patch136: rpm-4.13.x-pythondistdeps.py-skip-distribution-metadata-if-ther.patch
Patch137: rpm-4.13.x-pythondistdeps.py-show-warning-if-version-is-not-fou.patch
Patch138: rpm-4.13.x-pythondistdeps.py-skip-.egg-link-files.patch
Patch139: rpm-4.13.x-pythondistdeps.py-add-forgotten-import.patch
# Upstream PR: https://github.com/rpm-software-management/rpm/pull/154
# rhbz#1421776
Patch141: rpm-4.13.x-pythondistdeps.py-fix-processing-wheels.patch
# These are not yet upstream
Patch302: rpm-4.7.1-geode-i686.patch
@ -558,6 +561,22 @@ exit 0
%doc doc/librpm/html/*
%changelog
* Thu Nov 02 2017 Panu Matilainen <pmatilai@redhat.com> - 4.13.0.2-1
- Update to rpm 4.13.02 (http://rpm.org/wiki/Releases/4.13.0.2)
* Wed Aug 16 2017 Panu Matilainen <pmatilai@redhat.com> - 4.13.0.1-2
- Really ignore unknown tags in the signature header (#1480492)
- Fix rpmsign python module import failing (#1462671)
- Fix rpmbuild world writable empty (tmp) dirs in debuginfo (#641022)
- Fix testsuite with recent NSS-versions
* Fri Feb 24 2017 Panu Matilainen <pmatilai@redhat.com> - 4.13.0.1-1
- Rebase to rpm 4.13.0.1 (http://rpm.org/wiki/Releases/4.13.0.1)
- Fixes #1410907, #1405570, #1399798, #1410907 etc
* Thu Feb 16 2017 Tomas Orsava <torsava@redhat.com> - 4.13.0-7
- Fix handling of Python wheels by pythondistdeps.py --provides (#1421776)
* Sat Dec 03 2016 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 4.13.0-6
- Fix arch-dependent requires in subpackages (RHBZ #1398591)

View File

@ -1 +1 @@
f64e70c7548911da51a11651a789e30e rpm-4.13.0.tar.bz2
SHA512 (rpm-4.13.0.2.tar.bz2) = 9b15acb2684bc963f7164763568615b2484478eaec0cea8b3bd4ddb94b862a70b2f4b4ab432d896e5885c9a191c4d7d2ede573a5feabc8ec290108956a8a4917