2010/5/7 Alexander Boström <abo(a)root.snowtree.se>:
fre 2010-05-07 klockan 13:41 -0400 skrev Andrew Overholt:
>> Sometimes *-javadoc sub-packages explicitly requires main package, and
>> sometimes - not. I'm not a java-expert, so I don't know which is
>> correct.
>
> I don't think it really matters. In some cases, sure, it would be nice
> to ensure that the package is around if someone is looking at the API
> documentation. Other times someone may only want to peruse the APIs
> without installing the implementation.
Agreed. Those deps are now removed from the examples in
https://fedoraproject.org/wiki/User:Abo/JavaPackagingDraftUpdate which I
previously submitted as a proposed guideline update. (I hope I submitted
it the right way...)
I think there are use cases for which you want to install javadocs without
installing the bytecode; besides that, the Requires: tag is to make explicit
some runtime dependency, not a simple relation like this one.
Someone would disagree with me; however i think any decision is taken on
that topic would be turned in a MUST (depend or not depend) for the sake
of coherency.
Somehow I managed to not notice the java-devel list until recently so
I
think this is the first time I've mentioned the draft here. Please read
and comment on it! The number of changes are growing...
Some notes:
1- BuildRequires and Requires
At a minimum, Java packages MUST:
BuildRequires: java-devel [>= specific_version]
BuildRequires: jpackage-utils
Requires: java >= specific_version
Requires: jpackage-utils
This code snippet is telling me that specifying ">= specific_version"
in BuildRequires: java-devel is optional, while it is mandatory in
Requires: java
I have no objections to that, but the ant and maven templates below
must be updated consistently with that.
2- JavaDoc installation
"The name of the subdirectory SHOULD be either %{name}
or %{name}-%{version} with a symlink %{name} pointing to it."
I would turn that in a "MUST be either " one or the other: different directory
naming should be a rare exception and SHOULD doesnt seem strong enough.
3- maven template
You could drop the dependency on the main package for the manual too.
Anyway, the line should be:
Requires: %{name} = %{version}-%{release}
not
Requires: %{name}-%{version}-%{release}
I also would write a more general %add_to_maven_depmap macro call, from:
%add_to_maven_depmap org.apache.maven %{name} %{version} JPP %{name}
to:
%add_to_maven_depmap [groupId] [artifactId] %{version}
JPP[/optional_subDir] [jarName]
Finally, in the %files section:
%{_datadir}/maven2/poms/*
or
%{mavenpomdir}/*
Hope that helps
guido
--
Guido Grazioli <guido.grazioli(a)gmail.com>
Via Parri 11 48011 - Alfonsine (RA)
Mobile: +39 347 1017202 (10-18)
Key FP = 7040 F398 0DED A737 7337 DAE1 12DC A698 5E81 2278
Linked in:
http://www.linkedin.com/in/guidograzioli