1 Star 0 Fork 107

yinchuang/openEuler-rpm-config_test

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
brp-clean-perl-files 628 Bytes
一键复制 编辑 原始数据 按行查看 历史
#!/bin/sh
if [ -z "$RPM_BUILD_ROOT" ]; then
printf '%s\n' "No build root defined" >&2
exit 1
fi
if [ ! -d "$RPM_BUILD_ROOT" ]; then
printf '%s\n' "Invalid build root" >&2
exit 1
fi
perldirs="$RPM_BUILD_ROOT/usr/lib/perl5 $RPM_BUILD_ROOT/usr/lib64/perl5 $RPM_BUILD_ROOT/usr/share/perl5"
d=""
for i in $perldirs; do
[ -d "$i" ] || continue
d="$d $i"
done
[ -z "$d" ] && exit 0
find $d -name ".packlist" -o -name perllocal.pod | xargs rm -f
for i in $(find $d -name "*.bs"); do
if [ -s "$i" ]; then
printf '%s\n' "non empty .bs file!"
else
rm -f "$i"
fi
done
find $d -depth -type d -exec rmdir {} 2>/dev/null \;
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/ychuawei/openEuler-rpm-config_test.git
git@gitee.com:ychuawei/openEuler-rpm-config_test.git
ychuawei
openEuler-rpm-config_test
openEuler-rpm-config_test
master

搜索帮助