提交 444b1e78 编写于 作者: O openeuler-ci-bot 提交者: Gitee

!3 add help package & do /usr/bin/ check

Merge pull request !3 from myeuler/master
...@@ -766,6 +766,7 @@ sub build_spec(%) { ...@@ -766,6 +766,7 @@ sub build_spec(%) {
my @doc = @{$args{doc}}; my @doc = @{$args{doc}};
print $spec <<END; print $spec <<END;
\%global _empty_manifest_terminate_build 0
Name: $g_prefix$args{name} Name: $g_prefix$args{name}
Version: $args{version} Version: $args{version}
Release: $g_release$g_disttag Release: $g_release$g_disttag
...@@ -828,24 +829,33 @@ END ...@@ -828,24 +829,33 @@ END
my $buildpath=$args{path}; my $buildpath=$args{path};
$buildpath=~s/$args{version}/\%{version}/; $buildpath=~s/$args{version}/\%{version}/;
print $spec <<END;
print $spec <<END;
\%description \%description
$args{desc} $args{desc}
END
print $spec <<END;
\%package help
Summary : $args{summary}
Provides: $g_prefix$args{name}-doc
\%description help
$args{desc}
END
print $spec <<END;
\%prep \%prep
\%setup -q@{[(" -n $buildpath")]} \%setup -q@{[(" -n $buildpath")]}
END END
if (grep { $_ eq "pm_to_blib" } $args{files}) { if (grep { $_ eq "pm_to_blib" } $args{files}) {
print $spec <<'END'; print $spec <<'END';
rm -f pm_to_blib rm -f pm_to_blib
END END
} }
print $spec <<END; print $spec <<END;
\%build \%build
export PERL_MM_OPT="" export PERL_MM_OPT=""
END END
...@@ -892,13 +902,26 @@ END ...@@ -892,13 +902,26 @@ END
print $spec <<END; print $spec <<END;
find $macro{buildroot} -type f -name '*.bs' -size 0 -exec rm -f {} \\; find $macro{buildroot} -type f -name '*.bs' -size 0 -exec rm -f {} \\;
END END
} }
print $spec <<END; print $spec <<END;
find $macro{buildroot} -depth -type d -exec rmdir {} 2>/dev/null \\; find $macro{buildroot} -depth -type d -exec rmdir {} 2>/dev/null \\;
\%{_fixperms} $macro{buildroot}/* \%{_fixperms} $macro{buildroot}/*
END
print $spec <<END;
pushd \%{buildroot}
touch filelist.lst
if [ -d usr/bin ];then
find usr/bin -type f -printf "/\%h/\%f\\n" >> filelist.lst
fi
if [ -d usr/sbin ];then
find usr/bin -type f -printf "/\%h/\%f\\n" >> filelist.lst
fi
popd
mv \%{buildroot}/filelist.lst .
END END
print $spec <<END; print $spec <<END;
...@@ -915,7 +938,7 @@ END ...@@ -915,7 +938,7 @@ END
\%clean \%clean
rm -rf $macro{buildroot} rm -rf $macro{buildroot}
\%files \%files -f filelist.lst
\%defattr(-,root,root,-) \%defattr(-,root,root,-)
\%doc @doc \%doc @doc
END END
...@@ -933,7 +956,11 @@ END ...@@ -933,7 +956,11 @@ END
my $date=strftime("%a %b %d %Y", localtime); my $date=strftime("%a %b %d %Y", localtime);
print $spec <<END; print $spec <<END;
\%{_mandir}/man3/* \%files help
\%{_mandir}/*
END
print $spec <<END;
\%changelog \%changelog
* $date Perl_Bot <Perl_Bot\@openeuler.org> $args{version}-$g_release * $date Perl_Bot <Perl_Bot\@openeuler.org> $args{version}-$g_release
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册