--- /dev/null
+diff -ruNp file-5.34.orig/src/readelf.c file-5.34/src/readelf.c
+--- file-5.34.orig/src/readelf.c 2018-07-09 16:24:36.000000000 +0200
++++ file-5.34/src/readelf.c 2018-09-13 23:26:17.906332501 +0200
+@@ -1062,7 +1062,7 @@ dodynamic(struct magic_set *ms, void *vb
+
+ switch (xdh_tag) {
+ case DT_FLAGS_1:
+- if (xdh_val == DF_1_PIE)
++ if (xdh_val & DF_1_PIE)
+ ms->mode |= 0111;
+ else
+ ms->mode &= ~0111;
Summary(zh_TW.UTF-8): 用於決定檔案類型的一個工具程式。
Name: file
Version: 5.34
-Release: 2
+Release: 3
License: distributable
Group: Applications/File
Source0: ftp://ftp.astron.com/pub/file/%{name}-%{version}.tar.gz
Patch1: searchpath.patch
Patch2: automake.patch
Patch4: name-use-count.patch
+Patch5: %{name}-pie-so.patch
URL: http://www.darwinsys.com/file/
BuildRequires: autoconf >= 2.50
BuildRequires: automake
%patch1 -p1
%patch2 -p1
%patch4 -p1
+%patch5 -p1
%if "%{cc_version}" < "3.4"
%{__sed} -i -e 's,-Wextra,,' configure.ac