/[gentoo]/xml/htdocs/doc/en/java.xml
Gentoo

Contents of /xml/htdocs/doc/en/java.xml

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.43 - (hide annotations) (download) (as text)
Wed Sep 16 15:26:43 2009 UTC (4 years, 7 months ago) by nightmorph
Branch: MAIN
Changes since 1.42: +36 -11 lines
File MIME type: application/xml
new stuff about build-only VMs added, bug 285181

1 neysx 1.11 <?xml version="1.0" encoding="UTF-8"?>
2 nightmorph 1.43 <!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/java.xml,v 1.42 2008/09/28 20:29:25 nightmorph Exp $ -->
3 swift 1.8 <!DOCTYPE guide SYSTEM "/dtd/guide.dtd">
4 zhen 1.4
5 neysx 1.11 <guide link="/doc/en/java.xml">
6     <title>Gentoo Java Guide</title>
7    
8 nightmorph 1.23 <author title="Author">
9 rane 1.28 <mail link="nichoj@gentoo.org">Joshua Nichols</mail>
10 neysx 1.11 </author>
11 nightmorph 1.23 <author title="Author">
12 rane 1.28 <mail link="karltk@gentoo.org">Karl Trygve Kalleberg</mail>
13 neysx 1.11 </author>
14 swift 1.13 <author title="Editor">
15 nightmorph 1.23 <mail link="nightmorph@gentoo.org">Joshua Saddler</mail>
16 swift 1.13 </author>
17 neysx 1.11
18     <abstract>
19 nightmorph 1.23 This guide will introduce you to Java and explain how to use Java with Gentoo
20     Linux.
21 neysx 1.11 </abstract>
22    
23 nightmorph 1.23 <!-- The content of this document is licensed under the CC-BY-SA license -->
24     <!-- See http://creativecommons.org/licenses/by-sa/2.5 -->
25 neysx 1.11 <license/>
26    
27 nightmorph 1.43 <version>0.18</version>
28     <date>2009-09-16</date>
29 neysx 1.11
30     <chapter>
31 swift 1.13 <title>What is Java?</title>
32 neysx 1.11 <section>
33     <title>Overview</title>
34     <body>
35    
36     <p>
37 nightmorph 1.23 Java is a programming language developed by engineers of Sun Microsystems. The
38     language is object-oriented and designed to run on multiple platforms without
39     the need of recompiling code for each platform. Although Java can be compiled
40     as a native program, much of Java's popularity can be attributed to its
41     portability, along with other features such as garbage collection. To make
42     platform independence possible the Java compiler compiles the Java code to an
43     intermediate representation called "Java bytecode" that runs on a JRE (Java
44     Runtime Environment) and not directly on the operating system.
45 swift 1.13 </p>
46    
47     <p>
48 nightmorph 1.23 In order to run Java bytecode, one needs to have a JRE (Java Runtime
49     Environment) installed. A JRE provides core libraries, a platform dependent
50 nightmorph 1.39 Java Virtual Machine, plugins for browsers, among other things. A JDK (Java
51 nightmorph 1.23 Development Kit) adds programming tools, such as a bytecode compiler and a
52     debugger.
53 swift 1.13 </p>
54    
55     </body>
56     </section>
57     </chapter>
58    
59     <chapter>
60 nightmorph 1.35 <title>Before You Begin</title>
61 rane 1.28 <section>
62     <title>Existing installs</title>
63     <body>
64    
65     <p>
66     For existing installs, regardless of if you have installed anything Java
67     before, make sure you have followed the <uri
68     link="/proj/en/java/java-upgrade.xml">Java Upgrade Guide</uri>.
69     </p>
70    
71     </body>
72     </section>
73     <section>
74     <title>New installs</title>
75     <body>
76    
77     <p>
78     New installs should require no further preparation.
79     </p>
80    
81     </body>
82     </section>
83     </chapter>
84    
85     <chapter>
86     <title>Installing a Virtual Machine</title>
87 swift 1.13 <section>
88     <title>The choices</title>
89     <body>
90    
91     <p>
92 rane 1.28 Gentoo provides numerous Runtime Environments (JREs) and Development Kits
93     (JDKs). Among the current choices, we have:
94 swift 1.13 </p>
95    
96 nightmorph 1.23 <table>
97     <tr>
98     <th>Vendor</th>
99     <th>JDK</th>
100     <th>JRE</th>
101     </tr>
102     <tr>
103     <ti>The Blackdown Java Kit</ti>
104 rane 1.27 <ti>dev-java/blackdown-jdk</ti>
105 nightmorph 1.23 <ti>dev-java/blackdown-jre</ti>
106     </tr>
107     <tr>
108     <ti>Sun's Java Kit</ti>
109     <ti>dev-java/sun-jdk</ti>
110     <ti>dev-java/sun-jre-bin</ti>
111     </tr>
112     <tr>
113     <ti>The IBM Java Kit</ti>
114     <ti>dev-java/ibm-jdk-bin</ti>
115     <ti>dev-java/ibm-jre-bin</ti>
116     </tr>
117     <tr>
118     <ti>BEA WebLogic's J2SE Development Kit</ti>
119     <ti>dev-java/jrockit-jdk-bin</ti>
120     </tr>
121     </table>
122    
123     <!--
124 swift 1.41 TODO: list free implementations?
125 rane 1.26 note about not drop-in replacements
126 swift 1.41 kaffe/sablevm/gcj/jamvm
127 nightmorph 1.23 -->
128 swift 1.13 <p>
129 swift 1.41 The default for Java 1.4 is the Blackdown JRE/JDK pair, as it is freely
130 rane 1.28 ("free as in beer") available without any registration fuss.
131 neysx 1.11 </p>
132    
133     <p>
134 rane 1.28 JREs and JDKs from Sun, IBM, and BEA are generally faster, but getting them
135     is a bit more work, as you are required to read and accept their license before
136     downloading (IBM additionally requires you to register).
137 neysx 1.11 </p>
138    
139 nightmorph 1.23 </body>
140     </section>
141     <section>
142     <title>Installing a JRE/JDKs</title>
143     <body>
144    
145 neysx 1.11 <p>
146 nightmorph 1.23 To install your profile's default JDK, you can run <c>emerge virtual/jdk</c>.
147     Or to install your profile's default JRE, you can <c>emerge virtual/jre</c>.
148 neysx 1.11 </p>
149    
150 rane 1.28 <p>
151     In recent events, Sun has relicensed their JDK and JRE under a more Linux
152     distro friendly license. As a result, Sun releases Java 1.5 and onwards are
153     freely downloadable, without any further hassle.
154     </p>
155    
156 nightmorph 1.23 <note>
157     A JDK also includes a JRE, so if you install a JDK you shouldn't have to also
158     have to install a JRE.
159     </note>
160    
161 neysx 1.11 </body>
162     </section>
163     <section>
164 rane 1.28 <title>Installing fetch-restricted virtual machines</title>
165 neysx 1.11 <body>
166    
167     <p>
168 rane 1.28 As already mentioned, some of the JDKs and JREs require you to jump through a
169     few hoops before installing. Simply emerge the packages as you normally would.
170     The ebuilds will then instruct you where to go and what to download.
171 neysx 1.11 </p>
172    
173     <p>
174     You should download the indicated file(s) into
175 nightmorph 1.23 <path>/usr/portage/distfiles</path>. Once there, you can rerun the emerge
176     command, at which point the JRE/JDK will be begin to install.
177 neysx 1.11 </p>
178    
179     </body>
180     </section>
181     </chapter>
182    
183     <chapter>
184 rane 1.28 <title>Configuring your virtual machine</title>
185 neysx 1.11 <section>
186     <title>Overview</title>
187     <body>
188    
189     <p>
190 nightmorph 1.23 Gentoo has the ability to have multiple JDKs and JREs installed without causing
191     conflicts.
192 neysx 1.11 </p>
193    
194     <p>
195 nightmorph 1.23 Using the <c>java-config</c> tool, you can set the system-wide default
196     (provided you have root access). Users can also use <c>java-config</c> to set
197     up their own personal default.
198 neysx 1.11 </p>
199    
200 nightmorph 1.23 <note>
201     You can also use <e>eselect</e> to change the system and user vm. See
202 nightmorph 1.24 <c>eselect java-vm help</c>.
203 nightmorph 1.23 </note>
204    
205 neysx 1.11 </body>
206     </section>
207     <section>
208 rane 1.28 <title>Setting a default virtual machine</title>
209 neysx 1.11 <body>
210    
211     <p>
212 nightmorph 1.23 Running the command <c>java-config --list-available-vms</c> will give you a
213     list of all JREs and JDKs installed on your system. Here is an example of
214     output:
215 neysx 1.11 </p>
216    
217     <pre caption="Listing available VMs">
218 neysx 1.12 # <i>java-config --list-available-vms</i>
219 nightmorph 1.34 The following VMs are available for generation-2:
220 nightmorph 1.43 1) Blackdown JDK 1.4.2.03 [blackdown-jdk-1.4.2] <comment>(Build Only)</comment>
221     2) Blackdown JRE 1.4.2.03 [blackdown-jre-1.4.2] <comment>(Build Only)</comment>
222     3) IcedTea6-bin 1.4.1 [icedtea6-bin]
223     4) Sun JDK 1.5.0.20 [sun-jdk-1.5] <comment>(Build Only)</comment>
224     *) Sun JDK 1.6.0.16 [sun-jdk-1.6]
225 neysx 1.11 </pre>
226    
227 nightmorph 1.43 <note>
228     VMs marked as Build Only may contain security vulnerabilities and/or be EOL.
229     Gentoo recommends not setting these VMs as either your system or user VM.
230     Please see <uri link="java.xml#build-only">Build Only VM</uri> for more
231     information.
232     </note>
233    
234 neysx 1.11 <p>
235 nightmorph 1.23 The <e>*</e> indicates this is the current active vm (system-vm or user-vm when
236     set). The name in the brackets (<e>[]</e>) is the handle or ID for that
237     particular VM. You use the handle or the number to <c>java-config
238     --set-system-vm</c>. Here is an example of how to set the system VM.
239 neysx 1.11 </p>
240 zhen 1.4
241 neysx 1.11 <pre caption="Setting the System VM">
242 nightmorph 1.23 <comment>(By handle (preferred))</comment>
243     # <i>java-config --set-system-vm blackdown-jdk-1.4</i>
244 nightmorph 1.34 Now using blackdown-jdk-1.4 as your generation-2 system JVM
245 nightmorph 1.43 WARNING: blackdown-jdk-1.4 is marked as a build-only JVM. Using this vm is not recommended.
246 nightmorph 1.23 <comment>(By number)</comment>
247 nightmorph 1.43 # <i>java-config --set-system-vm 5</i>
248     Now using sun-jdk-1.6 as your generation-2 system JVM
249 neysx 1.11 </pre>
250 drobbins 1.1
251 nightmorph 1.23 <p>
252     As a regular user, you can use <c>java-config --set-user-vm</c>.
253     </p>
254    
255 neysx 1.11 <note>
256 nightmorph 1.23 You no longer have to <c>source</c> the profile for updates to the user/system
257     VM take place.
258 neysx 1.11 </note>
259    
260 nightmorph 1.23 </body>
261     </section>
262 nightmorph 1.43 <section id="build-only">
263     <title>Build Only VM</title>
264     <body>
265    
266     <p>
267     Some virtual machines are flagged as build-only due to being EOL and/or
268     containing security vulnerabilities. These virtual machines will not
269     automatically be used by Gentoo for the running of applications using Gentoo
270     launchers but will still be available for use by Gentoo's build environment as
271     some packages may require them for building. The setting of these virtual
272     machines as either your system or user VM is strongly discouraged as these VMs
273     will then be used when running the <path>/usr/bin/{java,javac,..}</path>
274     executables and will also be used by any packages not using Gentoo's launcher
275     scripts.
276     </p>
277    
278     </body>
279     </section>
280 nightmorph 1.23 <section id="preferred-vm">
281     <title>Preferred VM</title>
282     <body>
283    
284     <p>
285     While merging Java packages, the VM can and will be switched as necessary.
286     </p>
287    
288     <p>
289     Because of the wide variety of available VMs, we do not have the resources to
290     test and verify every package works on all of them. So to ensure that every
291     packages merges smoothly, we have defined a list of <e>default/supported
292     VMs</e> per arch. You can find them in
293 nightmorph 1.37 <path>/usr/share/java-config-2/config/jdk-defaults.conf</path>. When you are
294 nightmorph 1.23 merging a Java package, and it detects one of the VM in that file is installed,
295     it will automatically use that VM, instead of the system-vm.
296     </p>
297    
298 neysx 1.11 <p>
299 nightmorph 1.23 The merge time VM switching is also needed when, for example, your system-vm is
300     set a 1.4 VM and the package you are merging requires a 1.5 VM. While merging
301     it will use the preferred 1.5 VM, leaving your system-vm choice intact.
302 neysx 1.11 </p>
303 drobbins 1.1
304 nightmorph 1.23 <p>
305     Of course, Gentoo is all about choice, so you can override these defaults in
306     <path>/etc/java-config-2/build/jdk.conf</path> and have complete control over
307     which VM will get used. Some examples:
308     </p>
309    
310     <pre caption="Example /etc/java-config-2/build/jdk.conf">
311     <comment>(I always want it to use a sun-jdk, ie sun-jdk-1.4 for 1.4, sun-jdk-1.5 for 1.5, etc)</comment>
312     *=sun-jdk
313 neysx 1.11 </pre>
314 drobbins 1.1
315 nightmorph 1.23 <pre caption="Example /etc/java-config-2/build/jdk.conf">
316     <comment>(Always use sun-jdk-1.5 wherever possible, except for when a 1.4 or 1.3 VM is explicitly required)</comment>
317     *=sun-jdk-1.5
318     </pre>
319    
320     <pre caption="Example /etc/java-config-2/build/jdk.conf">
321     <comment># For 1.3 I prefer sun-jdk 1.4 but when it is not available, use ibm-jdk-bin,
322     # For 1.4, use blackdown-jdk, and for 1.5, use sun-jdk </comment>
323     1.3=sun-jdk-1.4 ibm-jdk-bin
324     1.4=blackdown-jdk
325     1.5=sun-jdk
326     </pre>
327    
328     <warn>
329     You do not have to edit this file. If you change these options to use a
330     unsupported VM, things could possibly break. Bugs reported with a unsupported
331 rane 1.26 VM won't be prioritized as much as bugs present within supported VMs.
332 nightmorph 1.23 </warn>
333    
334     </body>
335     </section>
336     </chapter>
337    
338     <chapter>
339     <title>Compilers</title>
340     <section>
341     <body>
342    
343 neysx 1.11 <p>
344 nightmorph 1.23 The standard Java compiler used for building is javac, which comes with each
345     JDK. In addition to configuring the VM used at build time, it is also possible
346     configure which compiler is used. Essentially, you define a list your
347     preference for which compiler to use in
348     <path>/etc/java-config-2/build/compilers.conf</path>.
349 neysx 1.11 </p>
350    
351 nightmorph 1.23 <pre caption="/etc/java-config-2/build/compilers.conf">
352     # If the ebuild supports it
353     # it will check the COMPILERS var front to back and
354     # use the first compiler that is installed
355    
356     COMPILERS="ecj-3.1 jikes javac"
357     </pre>
358    
359 neysx 1.11 <p>
360 nightmorph 1.23 Some compilers don't support all possible -target and -source arguments.
361     Therefore, each compiler in the list is checked to see if it can support the
362     desired -source/-target. javac will work in all cases, so if no other suitable
363     compiler is found, it will be used instead.
364 neysx 1.11 </p>
365    
366 nightmorph 1.23 <p>
367     More details about each compiler are provided below:
368     </p>
369    
370     <table>
371     <tr>
372     <th>Name</th>
373     <th>Handle</th>
374     <th>Package</th>
375     <th>Description</th>
376     </tr>
377     <tr>
378     <ti>javac</ti>
379     <ti>javac</ti>
380     <ti>N/A</ti>
381     <ti>
382     This is the default compiler that will be used, and comes with each JDK.
383     </ti>
384     </tr>
385     <tr>
386     <ti>jikes</ti>
387     <ti>jikes</ti>
388     <ti>dev-java/jikes</ti>
389     <ti>
390     Jikes was originally developed by IBM. Anecdotally, it is generally quicker
391     than javac. Note however, that it is more pedantic, and will fail under a
392     few circumstances where javac has no issue. It also does not support Java
393     1.5 syntax yet.
394     </ti>
395     </tr>
396     <tr>
397     <ti>Eclipse Compiler for Java</ti>
398     <ti>ecj-3.1</ti>
399     <ti>=dev-java/eclipse-ecj-3.1*</ti>
400     <ti>
401     ECJ is the compiler used by the Eclipse software development kit. It is
402     very full featured, and is pretty fast. It does support Java 1.5 syntax.
403     </ti>
404     </tr>
405     </table>
406    
407     </body>
408     </section>
409     </chapter>
410    
411     <chapter>
412     <title>Setting a default CLASSPATH</title>
413     <section>
414     <body>
415    
416     <warn>
417     The options explained in this section should be considered deprecated and will
418 rane 1.26 most likely be removed in the future. We strongly recommend against using
419 nightmorph 1.23 these, because your Java projects or application should ideally manage their
420     own classpaths. If you choose to specify a default CLASSPATH, some applications
421     may behave unexpectedly, because classes they weren't expecting would be on the
422     classpath.
423     </warn>
424    
425     <p>
426     <c>java-config</c> can also be used to set a system-wide default CLASSPATH, as
427     well a user-specific default CLASSPATH.
428     </p>
429    
430     <p>
431     First, you will want to list available Java libraries installed on your system
432     that might want to be put in your CLASSPATH. Here is an example of output:
433     </p>
434    
435     <pre caption="Listing classes">
436     # <i>java-config --list-available-packages</i>
437     [xerces-2] The next generation of high performance, fully compliant XML parsers in the Apache Xerces family (/usr/share/xerces-2/package.env)
438     [junit] Simple framework to write repeatable tests (/usr/share/junit/package.env)
439     [bsh] BeanShell: A small embeddable Java source interpreter (/usr/share/bsh/package.env)
440     [bcel] The Byte Code Engineering Library: analyze, create, manipulate Java class files (/usr/share/bcel/package.env)
441     [log4j] A low-overhead robust logging package for Java (/usr/share/log4j/package.env)
442     ...
443     </pre>
444    
445     <p>
446     Again, the names in brackets (<e>[]</e>) are the IDs that you have to pass to
447     <c>java-config --set-system-classpath</c>. Here is an example:
448     </p>
449    
450     <pre caption="Setting classpaths">
451     # <i>java-config --set-system-classpath log4j,xerces-2</i>
452     </pre>
453    
454     <note>
455     The current directory (<path>.</path>) will not be part of the system
456     classpath, as that should be added in your system's login profile.
457     </note>
458    
459     <p>
460 rane 1.26 You will have to update your environment by logging out, then in again or
461     sourcing <path>/etc/profile</path>.
462 nightmorph 1.23 </p>
463    
464     <p>
465     For users, <c>java-config --set-user-classpath</c> will create
466     <path>~/.gentoo/java-env-classpath</path>, which you should then source from
467 swift 1.41 your shell's profile.
468 nightmorph 1.23 </p>
469    
470     <pre caption="Sourcing user specific classpath">
471     <i>if [[ -f "${HOME}/.gentoo/java-env-classpath" ]]; then
472     source ${HOME}/.gentoo/java-env-classpath
473     fi</i>
474     </pre>
475    
476     <p>
477     If you really want a system wide or user default classpath you can add
478 rane 1.25 something like the following to your shell's profile. But we would advise
479 nightmorph 1.23 against it.
480     </p>
481    
482     <pre caption="Setting classpath">
483 swift 1.41 # <i>export CLASSPATH="${CLASSPATH}:$(java-config --classpath log4j,xerces-2)"</i>
484 nightmorph 1.23 </pre>
485    
486 neysx 1.11 </body>
487     </section>
488 swift 1.13 </chapter>
489    
490     <chapter>
491 nightmorph 1.39 <title>Java Browser Plugins</title>
492 nightmorph 1.34 <section>
493 nightmorph 1.39 <title>Installing a plugin</title>
494 nightmorph 1.34 <body>
495    
496     <p>
497 nightmorph 1.39 You can install a Java plugin for your web browser by emerging a Java VM with
498 nightmorph 1.34 the <c>nsplugin</c> USE flag set.
499     </p>
500    
501     <note>
502     <c>nsplugin</c> is not available for all architectures. Check for available
503 nightmorph 1.39 plugins on your arch before trying to install a VM by running <c>emerge -pv
504 nightmorph 1.34 &lt;java-vm&gt;</c>.
505     </note>
506    
507     <p>
508 nightmorph 1.39 Portage will allow you to install multiple versions of Java plugins, though
509 nightmorph 1.34 only one will be used by your browser. You can check the list of available
510 nightmorph 1.39 plugins by running:
511 nightmorph 1.34 </p>
512    
513 nightmorph 1.39 <pre caption="Viewing available plugins">
514 nightmorph 1.34 # <i>eselect java-nsplugin list</i>
515     [1] sun-jre-bin-1.5
516     [2] blackdown-jre-1.4.2
517     </pre>
518    
519     <p>
520 nightmorph 1.39 In this example, <c>sun-jre-bin</c> is selected for the browser plugin.
521 nightmorph 1.34 </p>
522    
523 nightmorph 1.39 <pre caption="Selecting a plugin">
524 nightmorph 1.36 # <i>eselect java-nsplugin set sun-jre-bin-1.5</i>
525 nightmorph 1.34 </pre>
526    
527     <p>
528 nightmorph 1.39 Verify that the correct plugin was selected:
529 nightmorph 1.34 </p>
530    
531 nightmorph 1.39 <pre caption="Verifying the correct plugin">
532 nightmorph 1.34 # <i>eselect java-nsplugin list</i>
533     [1] sun-jre-bin-1.5 current
534     [2] blackdown-jre-1.4.2
535     </pre>
536    
537     <p>
538     Java.com also provides a link to <uri
539     link="http://java.com/en/download/installed.jsp">verify your installed
540 nightmorph 1.39 plugin</uri>. Additionally, if you are using a Mozilla-based browser, you can
541     verify your Java plugin by typing <c>about:plugins</c> into the address bar.
542 nightmorph 1.34 </p>
543    
544     </body>
545     </section>
546     <section>
547 nightmorph 1.39 <title>Plugins on multilib systems</title>
548 nightmorph 1.34 <body>
549    
550     <p>
551 swift 1.41 If you are running a mixed 64-bit and 32-bit multilib system (for example, on
552     AMD64), you can only use 32-bit Java plugins.
553 nightmorph 1.34 </p>
554    
555     <p>
556 nightmorph 1.39 To use a 32-bit plugin, you will need to emerge <c>emul-linux-x86-java</c> with
557 nightmorph 1.38 the <c>nsplugin</c> USE flag enabled.
558     </p>
559    
560 nightmorph 1.39 <pre caption="Installing a 32-bit plugin">
561 nightmorph 1.38 # <i>echo "app-emulation/emul-linux-x86-java nsplugin" >> /etc/portage/package.use</i>
562     # <i>emerge emul-linux-x86-java</i>
563     </pre>
564    
565     <p>
566 nightmorph 1.39 Next, check which plugins are available:
567 nightmorph 1.34 </p>
568    
569 nightmorph 1.39 <pre caption="Viewing available plugins">
570 nightmorph 1.34 # <i>eselect java-nsplugin list</i>
571     Available 32-bit Java browser plugins
572     [1] emul-linux-x86-java-1.4.2
573     [2] emul-linux-x86-java-1.5
574     </pre>
575    
576     <p>
577 nightmorph 1.39 Although you must select a 32-bit browser (such as <c>mozilla-firefox-bin</c>)
578     to use with your 32-bit plugin, the 64-bit version of <c>konqueror</c> uses your
579     Java VM directly, so it's possible to use the 64-bit version of <c>blackdown</c>
580     with this browser; no further configuration is necessary.
581 nightmorph 1.34 </p>
582    
583 nightmorph 1.39 <p>
584     Now select the right plugin for your 32-bit browser:
585     </p>
586    
587     <pre caption="Selecting plugins">
588     # <i>eselect java-nsplugin set 32bit emul-linux-x86-java-1.5</i>
589 nightmorph 1.34 </pre>
590    
591     <p>
592 nightmorph 1.39 Verify the correct plugin was selected:
593 nightmorph 1.34 </p>
594    
595 nightmorph 1.39 <pre caption="Verifying the correct plugin">
596 nightmorph 1.34 # <i>eselect java-nsplugin list</i>
597     Available 32-bit Java browser plugins
598 nightmorph 1.39 [1] emul-linux-x86-java-1.4.2
599     [2] emul-linux-x86-java-1.5 current
600 nightmorph 1.34 </pre>
601    
602     </body>
603     </section>
604     </chapter>
605    
606     <chapter>
607 swift 1.13 <title>USE flags for use with Java</title>
608     <section>
609     <title>Setting USE flags</title>
610     <body>
611    
612     <p>
613 rane 1.17 For more information regarding USE flags, refer to the <uri
614     link="/doc/en/handbook/handbook-x86.xml?part=2&amp;chap=2">USE flags</uri>
615 swift 1.13 chapter from the Gentoo Handbook.
616 neysx 1.11 </p>
617    
618     </body>
619     </section>
620 swift 1.13 <section>
621     <title>The flags</title>
622     <body>
623    
624     <ul>
625 nightmorph 1.23 <li>The <b>java</b> flag adds support for Java in a variety of programs</li>
626     <li>
627     The <b>nsplugin</b> flag adds support for Mozilla-like browsers (including
628 nightmorph 1.33 Firefox). You will need this for viewing Java applets in your Mozilla-like
629 nightmorph 1.23 browser.
630     </li>
631 rane 1.17 <li>
632 rane 1.28 The <b>source</b> flag installs a zip of the source code of a package.
633 nightmorph 1.33 This is traditionally used for IDEs to 'attach' source to the libraries you
634     are using.
635 rane 1.28 </li>
636 nightmorph 1.40 <li>The <b>jce</b> flag adds support for the Java Cryptography Engine</li>
637 rane 1.28 <li>
638     For Java packages, the <b>doc</b> flag will build API documentation using
639     javadoc.
640     </li>
641 swift 1.13 </ul>
642    
643     </body>
644     </section>
645 neysx 1.11 </chapter>
646    
647     <chapter>
648     <title>Additional resources</title>
649     <section>
650     <title>Off-line resources</title>
651     <body>
652    
653     <ul>
654 rane 1.17 <li>java-config man page</li>
655     <li><c>java-config --help</c></li>
656 neysx 1.11 </ul>
657    
658     </body>
659     </section>
660     <section>
661     <title>Online resources</title>
662     <body>
663 rane 1.17
664 neysx 1.11 <ul>
665 nightmorph 1.23 <li>
666     The <uri link="http://www.gentoo.org/proj/en/java/">Java Project
667     Page</uri>
668     </li>
669 rane 1.17 <li>
670     The <uri
671 nightmorph 1.23 link="http://news.gmane.org/gmane.linux.gentoo.java">gentoo-java</uri>,
672     <uri
673     link="http://news.gmane.org/gmane.linux.gentoo.user">gentoo-user</uri>, and
674     <uri
675     link="http://news.gmane.org/gmane.linux.gentoo.devel">gentoo-dev</uri>
676 alin 1.18 mailing list archives
677 rane 1.17 </li>
678 nightmorph 1.42 <li>
679     <uri link="irc://irc.gentoo.org/gentoo">#gentoo</uri> and <uri
680     link="irc://irc.gentoo.org/gentoo-java">#gentoo-java</uri> on IRC
681     </li>
682 rane 1.17 <li>
683     <uri
684     link="http://en.wikipedia.org/wiki/Java_programming_language">Wikipedia's
685     entry for Java</uri>
686     </li>
687 nightmorph 1.40 <li>
688     If you have suggestions or questions regarding this document, please email
689     the Gentoo Java team: <mail>java@gentoo.org</mail>
690     </li>
691 neysx 1.11 </ul>
692    
693     </body>
694     </section>
695     </chapter>
696 neysx 1.12 </guide>

  ViewVC Help
Powered by ViewVC 1.1.20