commit d42a01a648b725059ec32c6c369af2563f0fcb28
Author: Jan RÄ™korajski <[email protected]>
Date:   Fri Feb 19 09:17:44 2021 +0100

    - don't treat symlinks as executables when classyfying files for dependency 
extraction
    
    If a symlink points to an executable, it would be added as duplicate, if
    not, then it should not be added. And in case of a symlink pointing to
    non-existing file (ex. absolute path) the build would break.

 rpm.spec            |  2 ++
 skip-symlinks.patch | 11 +++++++++++
 2 files changed, 13 insertions(+)
---
diff --git a/rpm.spec b/rpm.spec
index 9296756..98edca3 100644
--- a/rpm.spec
+++ b/rpm.spec
@@ -81,6 +81,7 @@ Patch30:      missing-ghost-terminate-build.patch
 Patch31:       missing-doc-terminate-build.patch
 Patch32:       noexpand.patch
 Patch33:       sqlite-db-backend.patch
+Patch34:       skip-symlinks.patch
 URL:           https://rpm.org/
 BuildRequires: acl-devel
 BuildRequires: db-devel >= %{db_ver}
@@ -579,6 +580,7 @@ Dokumentacja API RPM-a oraz przewodniki w formacie HTML 
generowane ze
 %patch31 -p1
 %patch32 -p1
 %patch33 -p1
+%patch34 -p1
 
 install %{SOURCE15} scripts/perl.prov.in
 
diff --git a/skip-symlinks.patch b/skip-symlinks.patch
new file mode 100644
index 0000000..1f3eea5
--- /dev/null
+++ b/skip-symlinks.patch
@@ -0,0 +1,11 @@
+--- rpm-4.16.1.2/build/rpmfc.c~        2021-01-24 09:43:15.000000000 +0100
++++ rpm-4.16.1.2/build/rpmfc.c 2021-02-19 09:14:46.031544586 +0100
+@@ -1231,7 +1231,7 @@
+       size_t slen = strlen(s);
+       int fcolor = RPMFC_BLACK;
+       rpm_mode_t mode = (fmode ? fmode[ix] : 0);
+-      int is_executable = (mode & (S_IXUSR|S_IXGRP|S_IXOTH));
++      int is_executable = ((mode & S_IFREG) && (mode & 
(S_IXUSR|S_IXGRP|S_IXOTH)));
+ 
+       switch (mode & S_IFMT) {
+       case S_IFCHR:   ftype = "character special";    break;
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/rpm.git/commitdiff/d42a01a648b725059ec32c6c369af2563f0fcb28

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to