Suggestions to improve the JAVA guidelines
by Orcan Ogetbil
Hi,
As I promised overholt on IRC, I wanted to share my views about the Fedora Java packaging guidelines from a non-Java-coder point of view.
JAVA GUIDELINES:
- "JNI-using JAR files"
This link is broken. It can be fixed easily.
- BuildRequires: jpackage-utils
Why do we need this? I understand Requires: jpackage-utils for directory ownership etc, but the BR is not necessary for most packages (at least all the ones I saw so far). I think this should *not* be required.
- In certain cases, we can build applications GCJ-natively (producing .so files). But these won't work with any JVM. What should be the packager's primary preference? GCJ-native or OpenJDK? The first one runs faster, but the second one has larger coverage.
For instance, tuxguitar (that I packaged) provides GNU Makefiles (that use GCJ) for this. Are the resulting .so files going to be the same as the ones built by aot-compile-rpm? (More about AOT later)
This case has confused me a lot in the past.
- Some explanation in the beginning about what GCJ can do and what openjdk can do; and some information about byte-code vs. machine-code will be very useful.
- BuildRequires: java-devel [>= specific_version]
How will the packager get to know the "specific_version"? For openjdk this is 1:1.6.0 , but for GCJ this is 1.5.0 . Are there other numbers that we need to know? Can't we put the numbers for all the cases in the guidelines?
- The Specfile Templates for ant and maven contradict with what was written in the BuildRequires and Requires section.
- the abbreviation "SNPG" should be defined in the first possible place, not in the third iteration (both for ant and maven).
- "Will this preserve the line ending as the this page says it must?"
This would be an artistic ending if we were writing a novel. But I think a guideline shouldn't end with open questions :)
GCJ GUIDELINES:
- It would be nice if there was a definition of GCJ-AOT bits. What do they do? Why do we like them? What does gij do? etc
- "Note: For Fedora versions < 8, no JDK was available other than GCJ so java packages with executable code MUST have the GCJ AOT bits."
This notice can be removed safely.
- The occurences of
%attr(-,root,root)
should be removed.
- GCJ AOT bits SHOULD be built and included in packages.
This needs to be more explicit. ie. 's@in packages@in all Java packages@'. I also think that this sentence should go to JAVA GUIDELINES so people click on the link for "GCJ Guidelines". The way that "GCJ Guidelines" link is put there, doesn't give an impression that it should be visited for any possible Java package.
These are all issues I encountered. If I remember more I will post them here. I thought a review on the guidelines from a Java-ignorant person would help other Java-ignorant people in the future. Thanks for reading :)
-oget
14 years, 2 months
why does openjdk need to depend on netbeans?
by Harshad
Hi,
I just tried installing java-1.6.0-openjdk-devel, and this causes a 38M download because of a dependency on netbeans. Is this really intended or is there a bug/oversight? (I am on a limited download internet connection)
Here's my complete yum trace:
yum install java-1.6.0-openjdk-devel.i386
Loaded plugins: fastestmirror, refresh-packagekit
Loading mirror speeds from cached hostfile
* fedora: ftp.iitm.ac.in
* rpmfusion-free-updates: lordmorgul.net
* rpmfusion-nonfree-updates: lordmorgul.net
* rpmfusion-free: lordmorgul.net
* rpmfusion-nonfree: lordmorgul.net
* updates: ftp.iitm.ac.in
fedora | 2.8 kB 00:00
rpmfusion-free-updates | 2.7 kB 00:00
rpmfusion-nonfree-updates | 2.7 kB 00:00
rpmfusion-free | 2.7 kB 00:00
rpmfusion-nonfree | 2.7 kB 00:00
updates | 2.3 kB 00:00
Setting up Install Process
Parsing package install arguments
Resolving Dependencies
--> Running transaction check
---> Package java-1.6.0-openjdk-devel.i386 1:1.6.0.0-7.b12.fc10 set to be updated
--> Processing Dependency: netbeans-platform8 for package: java-1.6.0-openjdk-devel
--> Running transaction check
---> Package netbeans-platform8.noarch 0:6.1-5.fc10 set to be updated
--> Processing Dependency: swing-layout >= 1.0 for package: netbeans-platform8
--> Processing Dependency: jna >= 3.0.2 for package: netbeans-platform8
--> Processing Dependency: javahelp2 >= 2.0.05 for package: netbeans-platform8
--> Running transaction check
---> Package javahelp2.noarch 0:2.0.05-5.fc10 set to be updated
---> Package swing-layout.i386 0:1.0.3-2.fc9 set to be updated
--> Processing Dependency: java-gcj-compat >= 1.0.31 for package: swing-layout
--> Processing Dependency: libgcj_bc.so.1 for package: swing-layout
---> Package jna.i386 0:3.0.4-10.svn729.fc10 set to be updated
--> Processing Dependency: libffi.so.5 for package: jna
--> Running transaction check
---> Package java-1.5.0-gcj.i386 0:1.5.0.0-22.fc10 set to be updated
updates/filelists_db | 2.8 MB 00:14
--> Processing Dependency: sinjdoc for package: java-1.5.0-gcj
---> Package libffi.i386 0:3.0.5-1.fc10 set to be updated
---> Package libgcj.i386 0:4.3.2-7 set to be updated
--> Running transaction check
---> Package sinjdoc.i386 0:0.5-7.fc10 set to be updated
--> Processing Dependency: java_cup >= 0.10 for package: sinjdoc
--> Running transaction check
---> Package java_cup.i386 1:0.10k-1 set to be updated
--> Finished Dependency Resolution
Dependencies Resolved
===========================================================================================================
Package Arch Version Repository Size
===========================================================================================================
Installing:
java-1.6.0-openjdk-devel i386 1:1.6.0.0-7.b12.fc10 updates 12 M
Installing for dependencies:
java-1.5.0-gcj i386 1.5.0.0-22.fc10 fedora 132 k
java_cup i386 1:0.10k-1 fedora 175 k
javahelp2 noarch 2.0.05-5.fc10 fedora 551 k
jna i386 3.0.4-10.svn729.fc10 fedora 187 k
libffi i386 3.0.5-1.fc10 fedora 22 k
libgcj i386 4.3.2-7 fedora 19 M
netbeans-platform8 noarch 6.1-5.fc10 fedora 5.2 M
sinjdoc i386 0.5-7.fc10 fedora 786 k
swing-layout i386 1.0.3-2.fc9 fedora 144 k
Transaction Summary
===========================================================================================================
Install 10 Package(s)
Update 0 Package(s)
Remove 0 Package(s)
Total download size: 38 M
Is this ok [y/N]: N
Exiting on user Command
Complete!
thanks,
Harshad
14 years, 7 months
Re: [fedora-java] XML editors in Fedora Eclipse, the hole WTP while you're at it
by Andrew Overholt
* Nicolas MONNET <nico(a)altiva.fr> [2008-12-22 12:01]:
> On Mon, 2008-12-22 at 11:09 -0500, Andrew Overholt wrote:
>
> * NMONNET <nico(a)altiva.fr> [2008-12-21 10:05]:
> > Is there a way to install WTP (Web Tools Platform) and WST on Fedora
> > Eclipse? Just using their update site from Fedora Eclipse fails with
> > various dependency problems.
>
> It shouldn't fail. Please file a bug at bugzilla.redhat.com and include
> more details like a screenshot showing the missing dependencies.
>
>
> Thank you for your answer, it helped me find out that I needed to have the EMF
> update site added to the mix.
Cool. The entire Ganymede site would have done the trick, too:
http://download.eclipse.org/releases/ganymede/
Andrew
14 years, 9 months