spec-create, templates: move part of package documemtation to the devel package or add a comment if the devel package is not provided by the template.
This commit is contained in:
parent
cc23a330ba
commit
1d2c39f52c
@ -29,6 +29,12 @@ Changes in version 1.8.1
|
|||||||
Support source packages with a makefile but no configure script.
|
Support source packages with a makefile but no configure script.
|
||||||
(Issue reported by Silvan Calarco)
|
(Issue reported by Silvan Calarco)
|
||||||
|
|
||||||
|
+ update
|
||||||
|
* spec-create, templates/* - Davide Madrisan:
|
||||||
|
Move part of package documemtation to the devel package or add a comment
|
||||||
|
if the devel package is not provided by the template.
|
||||||
|
(Pointed out by Silvan Calarco)
|
||||||
|
|
||||||
--------------------------------------------------------------------------------
|
--------------------------------------------------------------------------------
|
||||||
|
|
||||||
Changes in version 1.8.0
|
Changes in version 1.8.0
|
||||||
|
@ -228,9 +228,9 @@ remember to modify the value for \`${NOTE}$id${NORM}'" ;;
|
|||||||
|
|
||||||
function template.expand() {
|
function template.expand() {
|
||||||
local OPTIONS=`LANG=C getopt \
|
local OPTIONS=`LANG=C getopt \
|
||||||
-o t:T:n:v:s:l:S:d:b: \
|
-o t:T:n:v:s:l:S:b: \
|
||||||
--long template:,type:,pckname:,pckversion:,setupmacro:,summary:,license:,\
|
--long template:,type:,pckname:,pckversion:,setupmacro:,summary:,license:,\
|
||||||
source:,standard-docs:,build-technology:,\
|
source:,standard-docs:,standard-docs-devel:,build-technology:,\
|
||||||
i18n:,icons-mimetypes:,\
|
i18n:,icons-mimetypes:,\
|
||||||
infopages:,manpages:,\
|
infopages:,manpages:,\
|
||||||
pck-apidocs:,pck-tools:,\
|
pck-apidocs:,pck-tools:,\
|
||||||
@ -247,6 +247,7 @@ shared-libraries:,\
|
|||||||
local spec_summary="$spec_default_summary"
|
local spec_summary="$spec_default_summary"
|
||||||
local spec_license="$spec_default_license"
|
local spec_license="$spec_default_license"
|
||||||
local standard_docs
|
local standard_docs
|
||||||
|
local standard_docs_devel
|
||||||
local build_technology
|
local build_technology
|
||||||
|
|
||||||
local i18n="0"
|
local i18n="0"
|
||||||
@ -275,8 +276,10 @@ shared-libraries:,\
|
|||||||
spec_license="$2"; shift ;;
|
spec_license="$2"; shift ;;
|
||||||
-S|--source)
|
-S|--source)
|
||||||
spec_source="$2"; shift ;;
|
spec_source="$2"; shift ;;
|
||||||
-d|--standard-docs)
|
--standard-docs)
|
||||||
standard_docs="$2"; shift ;;
|
standard_docs="$2"; shift ;;
|
||||||
|
--standard-docs-devel)
|
||||||
|
standard_docs_devel="$2"; shift ;;
|
||||||
-b|--build-technology)
|
-b|--build-technology)
|
||||||
build_technology="$2"; shift ;;
|
build_technology="$2"; shift ;;
|
||||||
--i18n)
|
--i18n)
|
||||||
@ -378,6 +381,7 @@ s,^\([ \t]*Source[ \t]*:[ \t]*\).*,\1${spec_source},
|
|||||||
s,@make@,$spec_cmd_make,
|
s,@make@,$spec_cmd_make,
|
||||||
s,@makeinstall@,$spec_cmd_makeinstall,
|
s,@makeinstall@,$spec_cmd_makeinstall,
|
||||||
s,@standard_docs@,${standard_docs:+%doc $standard_docs},
|
s,@standard_docs@,${standard_docs:+%doc $standard_docs},
|
||||||
|
s,@standard_docs_devel@,${standard_docs_devel:+%doc $standard_docs_devel},
|
||||||
s,@spec_changelog_date@,$spec_changelog_date,
|
s,@spec_changelog_date@,$spec_changelog_date,
|
||||||
s,@spec_changelog_comment@,$spec_changelog_comment,
|
s,@spec_changelog_comment@,$spec_changelog_comment,
|
||||||
"
|
"
|
||||||
@ -658,21 +662,23 @@ looks like a python module (use \`-t python' if this is true)" ;;
|
|||||||
# + some other documentation files commonly found in several packages
|
# + some other documentation files commonly found in several packages
|
||||||
local standard_docs_list='
|
local standard_docs_list='
|
||||||
AUTHORS
|
AUTHORS
|
||||||
BACKLOG
|
|
||||||
BUGS
|
|
||||||
CHANGES
|
|
||||||
COPYING
|
COPYING
|
||||||
COPYING.DOC
|
COPYING.DOC
|
||||||
COPYING.LESSER
|
COPYING.LESSER
|
||||||
COPYING.LIB
|
COPYING.LIB
|
||||||
CREDITS
|
CREDITS
|
||||||
ChangeLog*
|
|
||||||
LICENCE
|
LICENCE
|
||||||
LICENSE
|
LICENSE
|
||||||
MANUAL
|
MANUAL
|
||||||
|
THANKS'
|
||||||
|
|
||||||
|
local standard_docs_devel_list='
|
||||||
|
BACKLOG
|
||||||
|
BUGS
|
||||||
|
CHANGES
|
||||||
|
ChangeLog*
|
||||||
NEWS
|
NEWS
|
||||||
README*
|
README*
|
||||||
THANKS
|
|
||||||
TODO
|
TODO
|
||||||
WHATSNEW
|
WHATSNEW
|
||||||
WHERE'
|
WHERE'
|
||||||
@ -684,9 +690,19 @@ looks like a python module (use \`-t python' if this is true)" ;;
|
|||||||
for currdoc in $currdocs; do
|
for currdoc in $currdocs; do
|
||||||
# ignore empty documentation files
|
# ignore empty documentation files
|
||||||
[ -s $tmpdir/$pck_rootdir/$currdoc ] &&
|
[ -s $tmpdir/$pck_rootdir/$currdoc ] &&
|
||||||
standard_docs="${standard_docs:+$standard_docs }$currdoc"
|
standard_docs="\
|
||||||
|
${standard_docs:+$standard_docs }$currdoc"
|
||||||
done
|
done
|
||||||
done
|
done
|
||||||
|
for doc in $standard_docs_devel_list; do
|
||||||
|
currdocs=$(cd $tmpdir/$pck_rootdir && ls $doc 2>/dev/null)
|
||||||
|
for currdoc in $currdocs; do
|
||||||
|
[ -s $tmpdir/$pck_rootdir/$currdoc ] &&
|
||||||
|
standard_docs_devel="\
|
||||||
|
${standard_docs_devel:+$standard_docs_devel }$currdoc"
|
||||||
|
done
|
||||||
|
done
|
||||||
|
|
||||||
# split the list of docs into multiple lines if necessary
|
# split the list of docs into multiple lines if necessary
|
||||||
#[ "$docs" ] && docs=`echo $docs | fmt -u -w 77 | sed 's,.*,%doc &,'`
|
#[ "$docs" ] && docs=`echo $docs | fmt -u -w 77 | sed 's,.*,%doc &,'`
|
||||||
|
|
||||||
@ -761,6 +777,7 @@ $spec_cmd_configure_autotools --enable-gtk-doc"
|
|||||||
--license "$spec_license" \
|
--license "$spec_license" \
|
||||||
--source "${spec_preamble_source:-$spec_preamble_tarball}" \
|
--source "${spec_preamble_source:-$spec_preamble_tarball}" \
|
||||||
--standard-docs "$standard_docs" \
|
--standard-docs "$standard_docs" \
|
||||||
|
--standard-docs-devel "$standard_docs_devel" \
|
||||||
--build-technology "$build_techology" \
|
--build-technology "$build_techology" \
|
||||||
--i18n "$spec_i18n" \
|
--i18n "$spec_i18n" \
|
||||||
--icons-mimetypes "1" \
|
--icons-mimetypes "1" \
|
||||||
|
@ -56,6 +56,8 @@ Requires: gtk-doc
|
|||||||
%files
|
%files
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
@standard_docs@
|
@standard_docs@
|
||||||
|
## note: eventually add the remaining documents (if any)
|
||||||
|
# @standard_docs_devel@
|
||||||
|
|
||||||
@if:library_apidocs
|
@if:library_apidocs
|
||||||
%files apidocs
|
%files apidocs
|
||||||
|
@ -36,6 +36,8 @@ BuildRoot: @rpm_default_buildroot@
|
|||||||
%files
|
%files
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
@standard_docs@
|
@standard_docs@
|
||||||
|
## note: eventually add the remaining documents (if any)
|
||||||
|
# @standard_docs_devel@
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* @spec_changelog_date@ @packager_fullname@ <@packager_email@> @pck_version@-@spec_first_release@@DISTRO_rpm@
|
* @spec_changelog_date@ @packager_fullname@ <@packager_email@> @pck_version@-@spec_first_release@@DISTRO_rpm@
|
||||||
|
@ -107,6 +107,8 @@ exit 0
|
|||||||
## note: "man3" pages normally goes to devel package if any
|
## note: "man3" pages normally goes to devel package if any
|
||||||
# %{_mandir}/man?/%{name}.*
|
# %{_mandir}/man?/%{name}.*
|
||||||
@standard_docs@
|
@standard_docs@
|
||||||
|
## note: eventually add the remaining documents (if any)
|
||||||
|
# @standard_docs_devel@
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* @spec_changelog_date@ @packager_fullname@ <@packager_email@> @pck_version@-@spec_first_release@@DISTRO_rpm@
|
* @spec_changelog_date@ @packager_fullname@ <@packager_email@> @pck_version@-@spec_first_release@@DISTRO_rpm@
|
||||||
|
@ -115,6 +115,7 @@ exit 0
|
|||||||
@if:infopages
|
@if:infopages
|
||||||
# %{_infodir}/*.info.*
|
# %{_infodir}/*.info.*
|
||||||
@fi:infopages
|
@fi:infopages
|
||||||
|
@standard_docs_devel@
|
||||||
|
|
||||||
@if:pck_tools
|
@if:pck_tools
|
||||||
%files tools
|
%files tools
|
||||||
|
@ -52,6 +52,8 @@ done
|
|||||||
%files -f .packlist
|
%files -f .packlist
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
@standard_docs@
|
@standard_docs@
|
||||||
|
## note: eventually add the remaining documents (if any)
|
||||||
|
# @standard_docs_devel@
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* @spec_changelog_date@ @packager_fullname@ <@packager_email@> @pck_version@-@spec_first_release@@DISTRO_rpm@
|
* @spec_changelog_date@ @packager_fullname@ <@packager_email@> @pck_version@-@spec_first_release@@DISTRO_rpm@
|
||||||
|
@ -42,6 +42,8 @@ sed -i "\\,\\.egg-info/,d;s,.*/man/.*,&.gz," %{name}.filelist
|
|||||||
%files -f %{name}.filelist
|
%files -f %{name}.filelist
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
@standard_docs@
|
@standard_docs@
|
||||||
|
## note: eventually add the remaining documents (if any)
|
||||||
|
# @standard_docs_devel@
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* @spec_changelog_date@ @packager_fullname@ <@packager_email@> @pck_version@-@spec_first_release@@DISTRO_rpm@
|
* @spec_changelog_date@ @packager_fullname@ <@packager_email@> @pck_version@-@spec_first_release@@DISTRO_rpm@
|
||||||
|
@ -82,6 +82,8 @@ exit 0
|
|||||||
# %{_infodir}/*.info.*
|
# %{_infodir}/*.info.*
|
||||||
@fi:infopages
|
@fi:infopages
|
||||||
@standard_docs@
|
@standard_docs@
|
||||||
|
## note: eventually add the remaining documents (if any)
|
||||||
|
# @standard_docs_devel@
|
||||||
|
|
||||||
@if:pck_apidocs
|
@if:pck_apidocs
|
||||||
%files apidocs
|
%files apidocs
|
||||||
|
@ -106,6 +106,8 @@ exit 0
|
|||||||
# %{_infodir}/*.info.*
|
# %{_infodir}/*.info.*
|
||||||
@fi:infopages
|
@fi:infopages
|
||||||
@standard_docs@
|
@standard_docs@
|
||||||
|
## note: eventually add the remaining documents (if any)
|
||||||
|
# @standard_docs_devel@
|
||||||
|
|
||||||
@if:pck_apidocs
|
@if:pck_apidocs
|
||||||
%files apidocs
|
%files apidocs
|
||||||
|
Loading…
Reference in New Issue
Block a user