File tree Expand file tree Collapse file tree 1 file changed +5
-11
lines changed Expand file tree Collapse file tree 1 file changed +5
-11
lines changed Original file line number Diff line number Diff line change @@ -56,41 +56,35 @@ if ! type zip > /dev/null 2>&1; then
56
56
exit 1
57
57
fi
58
58
59
- function pluck_so_files () {
59
+ function find_so_files () {
60
60
sed -E ' /\.so$|\.so\.[0-9]+$/!d'
61
61
}
62
62
63
63
function package_libc_alpine() {
64
64
if grep -F " Alpine Linux" < /etc/os-release > /dev/null; then
65
65
if type apk > /dev/null 2>&1 ; then
66
- apk info --contents musl 2> /dev/null | pluck_so_files | sed ' s/^/\//'
66
+ apk info --contents musl 2> /dev/null | find_so_files | sed ' s/^/\//'
67
67
fi
68
68
fi
69
69
}
70
70
71
71
function package_libc_pacman() {
72
72
if grep --extended-regexp " Arch Linux|Manjaro Linux" < /etc/os-release > /dev/null 2>&1 ; then
73
73
if type pacman > /dev/null 2>&1 ; then
74
- pacman --query --list --quiet glibc | pluck_so_files
74
+ pacman --query --list --quiet glibc | find_so_files
75
75
fi
76
76
fi
77
77
}
78
78
79
79
function package_libc_dpkg() {
80
80
if type dpkg-query > /dev/null 2>&1 ; then
81
- if [[ $( dpkg-query --listfiles libc6 | wc -l) -gt 0 ]]; then
82
- dpkg-query --listfiles libc6 | pluck_so_files
83
- fi
81
+ dpkg-query --listfiles libc6 | find_so_files
84
82
fi
85
83
}
86
84
87
85
function package_libc_rpm() {
88
- arch=$( uname -m)
89
-
90
86
if type rpm > /dev/null 2>&1 ; then
91
- if [[ $( rpm --query --list glibc.$arch | wc -l) -gt 1 ]]; then
92
- rpm --query --list glibc.$arch | pluck_so_files
93
- fi
87
+ rpm --query --list glibc.$( uname -m) | find_so_files
94
88
fi
95
89
}
96
90
You can’t perform that action at this time.
0 commit comments