Commit 4231917d authored by Vitaly Lipatov's avatar Vitaly Lipatov

epm-requires: use file -L for binaries

parent 17810719
......@@ -44,7 +44,7 @@ check_pkg_integrity()
docmd apkg verify $PKG
;;
exe)
file $PKG | grep -q "executable for MS Windows"
file -L $PKG | grep -q "executable for MS Windows"
;;
msi)
# TODO: add to patool via cabextract
......
......@@ -64,9 +64,9 @@ __epm_elf_requires()
fi
for i in $* ; do
if file "$i" | grep -q " ELF 32-bit " ; then
if file -L "$i" | grep -q " ELF 32-bit " ; then
__epm_elf32_requires "$i"
elif file "$i" | grep -q " ELF 64-bit " ; then
elif file -L "$i" | grep -q " ELF 64-bit " ; then
__epm_elf64_requires "$i"
else
warning "Unknown ELF binary"
......
......@@ -795,7 +795,7 @@ get_package_type()
return
;;
*)
if [ -r "$1" ] && file "$1" | grep -q " ELF " ; then
if [ -r "$1" ] && file -L "$1" | grep -q " ELF " ; then
echo "ELF"
return
fi
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment