Changeset ac38e9dc for general/prog/gcc-java.xml
- Timestamp:
- 08/01/2015 04:26:22 AM (9 years ago)
- Branches:
- systemd-13485
- Children:
- ad6910d
- Parents:
- 4a83293
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
general/prog/gcc-java.xml
r4a83293 rac38e9dc 5 5 %general-entities; 6 6 7 <!ENTITY gcc-java-download-http "http ://ftp.gnu.org/gnu/gcc/gcc-&gcc-version;/gcc-&gcc-version;.tar.bz2">7 <!ENTITY gcc-java-download-http "https://ftp.gnu.org/gnu/gcc/gcc-&gcc-version;/gcc-&gcc-version;.tar.bz2"> 8 8 <!ENTITY gcc-java-download-ftp "ftp://ftp.gnu.org/gnu/gcc/gcc-&gcc-version;/gcc-&gcc-version;.tar.bz2"> 9 <!ENTITY gcc-java-md5sum " 4df8ee253b7f3863ad0b86359cd39c43">10 <!ENTITY gcc-java-size " 86MB">11 <!ENTITY gcc-java-buildsize " 3.0GB">12 <!ENTITY gcc-java-time " 84 SBU (including 70SBU for tests)">9 <!ENTITY gcc-java-md5sum "d5525b1127d07d215960e6051c5da35e"> 10 <!ENTITY gcc-java-size "91 MB"> 11 <!ENTITY gcc-java-buildsize "4.1 GB"> 12 <!ENTITY gcc-java-time "78 SBU (including 65 SBU for tests)"> 13 13 14 14 <!ENTITY ecj-download-ftp "ftp://sourceware.org/pub/java/ecj-latest.jar"> 15 15 16 <!ENTITY antlr-version "4. 2.2">16 <!ENTITY antlr-version "4.5"> 17 17 <!ENTITY antlr-download-http "http://www.antlr.org/download/antlr-&antlr-version;-complete.jar"> 18 18 ]> … … 29 29 30 30 <indexterm zone="gcc"> 31 <primary sortas="a-gcc-java- 4-0">GCC-Java-&gcc-version;</primary>31 <primary sortas="a-gcc-java-5-0">GCC-Java-&gcc-version;</primary> 32 32 </indexterm> 33 33 … … 35 35 <title>Introduction to GCC-Java</title> 36 36 37 <para> See the introduction to the Java language and system at38 <xref linkend="java"/>. The GNU Compiler Collection (GCC) contains39 a Java compiler to native code. Together with the40 <application>ecj</application> Java compiler from Eclipse (to bytecode),41 it provides a way to build an acceptable JVM from source. However, since42 the release of <application>OpenJDK</application>, the development43 of GCC-Java has almost stopped, and the built JVM is an old version.44 One reason to build45 this system is that it can be used to bootstrap <xref linkend="openjdk"/>,46 without the need for downloading a Java binary.</para>47 48 &lfs7 6_checked;37 <para> 38 See the introduction to the Java language and system at 39 <xref linkend="java"/>. The GNU Compiler Collection (GCC) contains 40 a Java compiler to native code. Together with the 41 <application>ecj</application> Java compiler from Eclipse (to bytecode), 42 it provides a way to build an acceptable JVM from source. However, since 43 the release of <application>OpenJDK</application>, the development 44 of GCC-Java has almost stopped, and the built JVM is an old version, 45 which cannot be used for building <xref linkend="openjdk"/>. 46 </para> 47 48 &lfs77_checked; 49 49 50 50 <caution> 51 <para>Using the instructions on this page will have the effect that 52 the C and C++ compiler and libraries will be reinstalled, overwriting 53 the ones on your system. This may lead to some issues. Please read the 54 note and caution on the <xref linkend="gcc"/> page.</para> 51 <para> 52 Using the instructions on this page will have the effect that 53 the C and C++ compiler and libraries will be reinstalled, overwriting 54 the ones on your system. This may lead to some issues. Please read the 55 note and caution on the <xref linkend="gcc"/> page. 56 </para> 55 57 </caution> 56 58 … … 58 60 <itemizedlist spacing="compact"> 59 61 <listitem> 60 <para>Download (HTTP): <ulink url="&gcc-java-download-http;"/></para> 61 </listitem> 62 <listitem> 63 <para>Download (FTP): <ulink url="&gcc-java-download-ftp;"/></para> 64 </listitem> 65 <listitem> 66 <para>Download MD5 sum: &gcc-java-md5sum;</para> 67 </listitem> 68 <listitem> 69 <para>Download size: &gcc-java-size;</para> 70 </listitem> 71 <listitem> 72 <para>Estimated disk space required: &gcc-java-buildsize;</para> 73 </listitem> 74 <listitem> 75 <para>Estimated build time: &gcc-java-time;</para> 62 <para> 63 Download (HTTP): <ulink url="&gcc-java-download-http;"/> 64 </para> 65 </listitem> 66 <listitem> 67 <para> 68 Download (FTP): <ulink url="&gcc-java-download-ftp;"/> 69 </para> 70 </listitem> 71 <listitem> 72 <para> 73 Download MD5 sum: &gcc-java-md5sum; 74 </para> 75 </listitem> 76 <listitem> 77 <para> 78 Download size: &gcc-java-size; 79 </para> 80 </listitem> 81 <listitem> 82 <para> 83 Estimated disk space required: &gcc-java-buildsize; 84 </para> 85 </listitem> 86 <listitem> 87 <para> 88 Estimated build time: &gcc-java-time; 89 </para> 76 90 </listitem> 77 91 </itemizedlist> … … 81 95 <listitem> 82 96 <para> 83 Eclipse Java compiler: 84 <ulink url="&ecj-download-ftp;"/> 97 Eclipse Java compiler: <ulink url="&ecj-download-ftp;"/> 85 98 </para> 86 99 </listitem> … … 91 104 </para> 92 105 </listitem> 93 <!--<listitem>106 <listitem> 94 107 <para> 95 108 Required patch: 96 109 <ulink url="&patch-root;/gcc-&gcc-version;-upstream_fixes-1.patch"/> 97 110 </para> 98 </listitem> -->111 </listitem> 99 112 </itemizedlist> 100 113 101 <bridgehead renderas="sect3">GCC Dependencies</bridgehead>114 <bridgehead renderas="sect3">GCC Java Dependencies</bridgehead> 102 115 103 116 <bridgehead renderas="sect4">Required</bridgehead> 104 117 <para role="required"> 105 <xref linkend=" zip"/>,106 <xref linkend=" unzip"/>, and107 <xref linkend=" which"/>118 <xref linkend="unzip"/>, 119 <xref linkend="which"/>, and 120 <xref linkend="zip"/> 108 121 </para> 109 122 … … 129 142 <title>Installation of GCC Java</title> 130 143 131 <para>The instructions below assume that the C and C++ compilers have 132 the same version as the one you are installing, so that a 133 <quote>bootstrap</quote> is not necessary. If you are upgrading 134 the GCC version, then remove the <option>--disable-bootstrap</option> from 135 the <command>./configure</command> options below.</para> 136 <!-- 137 <para>As in LFS, fix a problem identified upstream:</para> 138 139 <screen><userinput>sed -i 's/if \((code.*))\)/if (\1 \&\& \!DEBUG_INSN_P (insn))/' gcc/sched-deps.c</userinput></screen> 140 --> 141 142 <para>Install <application>GCC Java</application> by running the 143 following commands:</para> 144 <para> 145 The instructions below assume that the C and C++ compilers have 146 the same version as the one you are installing, so that a 147 <quote>bootstrap</quote> is not necessary. If you are upgrading 148 the GCC version, then remove the <option>--disable-bootstrap</option> from 149 the <command>./configure</command> options below. 150 </para> 151 152 <para> 153 As in LFS, fix some problems identified upstream: 154 </para> 155 156 <screen><userinput>patch -Np1 -i ../gcc-&gcc-version;-upstream_fixes-1.patch</userinput></screen> 157 158 <para> 159 Install <application>GCC Java</application> by running the 160 following commands: 161 </para> 144 162 145 163 <screen><userinput>sed -i 's/\(install.*:\) install-.*recursive/\1/' libffi/Makefile.in && 146 164 sed -i 's/\(install-data-am:\).*/\1/' libffi/include/Makefile.in && 147 <!--148 patch -Np1 -i ../gcc-&gcc-version;-upstream_fixes-1.patch &&149 -->150 165 151 166 cp ../ecj-latest.jar ./ecj.jar && … … 165 180 make</userinput></screen> 166 181 167 <para>If you have installed additional packages such as 168 <application>Valgrind</application> and <application>GDB</application>, 169 the <application>GCC</application> part of the testsuite will run more 170 tests than in LFS. Some of those will report FAIL and others XPASS 171 (pass when expected to FAIL). To run the tests, issue:</para> 182 <para> 183 If you have installed additional packages such as 184 <application>Valgrind</application> and <application>GDB</application>, 185 the <application>GCC</application> part of the testsuite will run more 186 tests than in LFS. Some of those will report FAIL and others XPASS 187 (pass when expected to FAIL). To run the tests, issue: 188 </para> 172 189 173 190 <screen><userinput>ulimit -s 32768 && … … 176 193 to be run. --> 177 194 178 <para>The tests are very long, and the results may be hard to find in the 179 logs, specially if you use job control with make. You can get a summary 180 of the tests with:</para> 195 <para> 196 The tests are very long, and the results may be hard to find in the 197 logs, specially if you use job control with make. You can get a summary 198 of the tests with: 199 </para> 181 200 182 201 <screen><userinput>../gcc-&gcc-version;/contrib/test_summary</userinput></screen> 183 202 184 <para>Now, as the <systemitem class="username">root</systemitem> user:</para> 203 <para> 204 Now, as the <systemitem class="username">root</systemitem> user: 205 </para> 185 206 186 207 <screen role="root"><userinput>make install && … … 202 223 <title>Command Explanations</title> 203 224 204 <para>The two <command>sed</command> commands prevent the 205 installation of the <application>libffi</application> library bundled 206 with <application>GCC</application>, since it is outdated compared to 207 <xref linkend="libffi"/>.</para> 208 <!-- 209 <para> 210 <command>patch ... gcc-&gcc-version;-upstream_fixes-1.patch</command>: 211 This patch corrects bugs in the C++ compiler, which lead to 212 segmentation faults in some cases. 213 </para> 214 --> 215 216 <para><command>mkdir ../gcc-build; cd ../gcc-build</command>: The 217 <application>GCC</application> documentation recommends 218 building the package in a dedicated build directory.</para> 219 220 <para><parameter>--disable-multilib</parameter>: This parameter ensures 221 that files are created for the specific architecture of your computer.</para> 225 <para> 226 The two <command>sed</command> commands prevent the 227 installation of the <application>libffi</application> library bundled 228 with <application>GCC</application>, since it is outdated compared to 229 <xref linkend="libffi"/>. 230 </para> 231 232 <para> 233 <command>mkdir ../gcc-build; cd ../gcc-build</command>: The 234 <application>GCC</application> documentation recommends 235 building the package in a dedicated build directory. 236 </para> 237 238 <para> 239 <parameter>--disable-multilib</parameter>: This parameter ensures 240 that files are created for the specific architecture of your computer. 241 </para> 222 242 223 243 <para> … … 250 270 251 271 <para> 252 <parameter>--enable-languages=java</parameter>: 253 This command identifies which language to build. Note it is unavoidable 254 that the <application>C</application> and <application>C++</application> 255 compilers be built too.</para> 272 <parameter>--enable-languages=java</parameter>: 273 This command identifies which language to build. Note it is unavoidable 274 that the <application>C</application> and <application>C++</application> 275 compilers be built too. 276 </para> 256 277 257 278 <para> … … 261 282 </para> 262 283 263 <para><command>ulimit -s 32768</command>: This command prevents several 264 tests from running out of stack space.</para> 265 266 <para><command>make -k check</command>: This command runs the test suite 267 without stopping if any errors are encountered.</para> 268 269 <para><command>../gcc-&gcc-version;/contrib/test_summary</command>: This 270 command will produce a summary of the test suite results. You can append 271 <command>| grep -A7 Summ</command> to the command to produce an even more 272 condensed version of the summary. You may also wish to redirect the output 273 to a file for review and comparison later on.</para> 274 275 <para><command>chown -v -R root:root 276 /usr/lib/gcc/*linux-gnu/...</command>: 277 If the package is built by a user other than root, the ownership of the 278 installed <filename class="directory">include</filename> directory (and its 279 content) will be incorrect. This commands changes the ownership to the 280 <systemitem class="username">root</systemitem> user and group.</para> 284 <para> 285 <command>ulimit -s 32768</command>: This command prevents several 286 tests from running out of stack space. 287 </para> 288 289 <para> 290 <command>make -k check</command>: This command runs the test suite 291 without stopping if any errors are encountered. 292 </para> 293 294 <para> 295 <command>../gcc-&gcc-version;/contrib/test_summary</command>: This 296 command will produce a summary of the test suite results. You can append 297 <command>| grep -A7 Summ</command> to the command to produce an even more 298 condensed version of the summary. You may also wish to redirect the output 299 to a file for review and comparison later on. 300 </para> 301 302 <para> 303 <command>chown -v -R root:root 304 /usr/lib/gcc/*linux-gnu/...</command>: 305 If the package is built by a user other than root, the ownership of the 306 installed <filename class="directory">include</filename> directory (and its 307 content) will be incorrect. This commands changes the ownership to the 308 <systemitem class="username">root</systemitem> user and group. 309 </para> 281 310 282 311 <para> … … 295 324 296 325 <para> 297 The configuration is the same as for <xref linkend="openjdk"/>,326 The configuration is the same as <xref linkend="ojdk-conf"/>, 298 327 replacing <filename class="directory">/opt/jdk</filename> with 299 328 <filename class="directory">/opt/gcj</filename>. … … 329 358 <seg> 330 359 /usr/include/c++/&gcc-version;/{gcj,gnu,java,javax,org,sun}, 331 /usr/lib/gcj-&gcc-version;-15, 332 /usr/lib/security, /opt/gcj/{bin,jre,include,lib} and 333 /usr/share/java 360 /usr/lib/gcj-&gcc-version;-16, /usr/lib/jvm-exports, 361 /usr/lib/security, /opt/gcj and /usr/share/java 334 362 </seg> 335 363 </seglistitem> 336 364 </segmentedlist> 337 365 338 <para>Some program and library names and descriptions are not listed here, 339 but can be found at 340 <ulink url="&lfs-root;/chapter06/gcc.html#contents-gcc"/> as they were 341 initially installed during the building of LFS.</para> 366 <para> 367 Some program and library names and descriptions are not listed here, 368 but can be found at 369 <ulink url="&lfs-root;/chapter06/gcc.html#contents-gcc"/> as they were 370 initially installed during the building of LFS. 371 </para> 342 372 343 373 <variablelist> … … 349 379 <term><command>aot-compile</command></term> 350 380 <listitem> 351 <para>searches a directory for Java bytecode and uses 352 <command>gcj</command> to compile it to native code.</para> 381 <para> 382 searches a directory for Java bytecode and uses 383 <command>gcj</command> to compile it to native code. 384 </para> 353 385 <indexterm zone="gcc aot-compile"> 354 386 <primary sortas="b-aot-compile">aot-compile</primary> … … 360 392 <term><command>ecj</command></term> 361 393 <listitem> 362 <para>is the eclipse compiler.</para> 394 <para> 395 is the eclipse compiler. 396 </para> 363 397 <indexterm zone="gcc ecj"> 364 398 <primary sortas="b-ecj">ecj</primary> … … 370 404 <term><command>gappletviewer</command></term> 371 405 <listitem> 372 <para>loads and run a <application>Java</application> applet.</para> 406 <para> 407 loads and run a <application>Java</application> applet. 408 </para> 373 409 <indexterm zone="gcc gappletviewer"> 374 410 <primary sortas="b-gappletviewer">gappletviewer</primary> … … 380 416 <term><command>gc-analyze</command></term> 381 417 <listitem> 382 <para>analyzes garbage collector (GC) memory dumps from 383 <application>Java</application> code.</para> 418 <para> 419 analyzes garbage collector (GC) memory dumps from 420 <application>Java</application> code. 421 </para> 384 422 <indexterm zone="gcc gc-analyze"> 385 423 <primary sortas="b-gc-analyze">gc-analyze</primary> … … 391 429 <term><command>gcj</command></term> 392 430 <listitem> 393 <para>is an ahead-of-time compiler for the 394 <application>Java</application> language.</para> 431 <para> 432 is an ahead-of-time compiler for the <application>Java</application> 433 language. 434 </para> 395 435 <indexterm zone="gcc gcj"> 396 436 <primary sortas="b-gcj">gcj</primary> … … 402 442 <term><command>gcj-dbtool</command></term> 403 443 <listitem> 404 <para>is a tool for creating and manipulating class file mapping 405 databases.</para> 444 <para> 445 is a tool for creating and manipulating class file mapping databases. 446 </para> 406 447 <indexterm zone="gcc gcj-dbtool"> 407 448 <primary sortas="b-gcj-dbtool">gcj-dbtool</primary> … … 413 454 <term><command>gcjh</command></term> 414 455 <listitem> 415 <para>generates header files from <application>Java</application> 416 class files.</para> 456 <para> 457 generates header files from <application>Java</application> class files. 458 </para> 417 459 <indexterm zone="gcc gcjh"> 418 460 <primary sortas="b-gcjh">gcjh</primary> … … 424 466 <term><command>gij</command></term> 425 467 <listitem> 426 <para>is the GNU interpreter for <application>Java</application> 427 bytecode.</para> 468 <para> 469 is the GNU interpreter for <application>Java</application> bytecode. 470 </para> 428 471 <indexterm zone="gcc gij"> 429 472 <primary sortas="b-gij">gij</primary> … … 435 478 <term><command>gjar</command></term> 436 479 <listitem> 437 <para>is an (partial) implementation of the <command>jar</command> 438 utility that comes with Sun's JDK.</para> 480 <para> 481 is an (partial) implementation of the <command>jar</command> 482 utility that comes with Sun's JDK. 483 </para> 439 484 <indexterm zone="gcc gjar"> 440 485 <primary sortas="b-gjar">gjar</primary> … … 446 491 <term><command>gjarsigner</command></term> 447 492 <listitem> 448 <para>is a Java ARchive (JAR) file signing and verification 449 tool.</para> 493 <para> 494 is a Java ARchive (JAR) file signing and verification tool. 495 </para> 450 496 <indexterm zone="gcc gjarsigner"> 451 497 <primary sortas="b-gjarsigner">gjarsigner</primary> … … 457 503 <term><command>gjavah</command></term> 458 504 <listitem> 459 <para>generates header files from Java class files.</para> 505 <para> 506 generates header files from Java class files. 507 </para> 460 508 <indexterm zone="gcc gjavah"> 461 509 <primary sortas="b-gjavah">gjavah</primary> … … 467 515 <term><command>gjdoc</command></term> 468 516 <listitem> 469 <para>is a documentation tool similar to <command>javadoc</command>. 517 <para> 518 is a documentation tool similar to <command>javadoc</command>. 470 519 </para> 471 520 <indexterm zone="gcc gjdoc"> … … 478 527 <term><command>gkeytool</command></term> 479 528 <listitem> 480 <para>manages private keys and public certificates in a 481 <application>Java</application> environment.</para> 529 <para> 530 manages private keys and public certificates in a 531 <application>Java</application> environment. 532 </para> 482 533 <indexterm zone="gcc gkeytool"> 483 534 <primary sortas="b-gkeytool">gkeytool</primary> … … 489 540 <term><command>gnative2ascii</command></term> 490 541 <listitem> 491 <para>is an encoding converter for <application>Java</application>.</para> 542 <para> 543 is an encoding converter for <application>Java</application>. 544 </para> 492 545 <indexterm zone="gcc gnative2ascii"> 493 546 <primary sortas="b-gnative2ascii">gnative2ascii</primary> … … 499 552 <term><command>gorbd</command></term> 500 553 <listitem> 501 <para>is an object request broker daemon.</para> 554 <para> 555 is an object request broker daemon. 556 </para> 502 557 <indexterm zone="gcc gorbd"> 503 558 <primary sortas="b-gorbd">gorbd</primary> … … 509 564 <term><command>grmic</command></term> 510 565 <listitem> 511 <para>generates stubs for Remote Method Invocation.</para> 566 <para> 567 generates stubs for Remote Method Invocation. 568 </para> 512 569 <indexterm zone="gcc grmic-gcc"> 513 570 <primary sortas="b-grmic">grmic</primary> … … 519 576 <term><command>grmid</command></term> 520 577 <listitem> 521 <para>RMI activation system daemon.</para> 578 <para> 579 RMI activation system daemon. 580 </para> 522 581 <indexterm zone="gcc grmid-gcc"> 523 582 <primary sortas="b-grmid">grmid</primary> … … 529 588 <term><command>grmiregistry</command></term> 530 589 <listitem> 531 <para> starts a remote object registry on the current host.</para> 590 <para> 591 starts a remote object registry on the current host. 592 </para> 532 593 <indexterm zone="gcc grmiregistry-gcc"> 533 594 <primary sortas="b-grmiregistry">grmiregistry</primary> … … 539 600 <term><command>gserialver</command></term> 540 601 <listitem> 541 <para> prints the serialVersionUID of the specified class.</para> 602 <para> 603 prints the serialVersionUID of the specified class. 604 </para> 542 605 <indexterm zone="gcc gserialver"> 543 606 <primary sortas="b-gserialver">gserialver</primary> … … 549 612 <term><command>gtnameserv</command></term> 550 613 <listitem> 551 <para> starts a naming service.</para> 614 <para> 615 starts a naming service. 616 </para> 552 617 <indexterm zone="gcc gtnameserv"> 553 618 <primary sortas="b-gtnameserv">gtnameserv</primary> … … 559 624 <term><command>jcf-dump</command></term> 560 625 <listitem> 561 <para>prints information about <application>Java</application> 562 class files.</para> 626 <para> 627 prints information about <application>Java</application> 628 class files. 629 </para> 563 630 <indexterm zone="gcc jcf-dump"> 564 631 <primary sortas="b-jcf-dump">jcf-dump</primary> … … 570 637 <term><command>jv-convert</command></term> 571 638 <listitem> 572 <para>converts files from one encoding to another.</para> 639 <para> 640 converts files from one encoding to another. 641 </para> 573 642 <indexterm zone="gcc jv-convert"> 574 643 <primary sortas="b-jv-convert">jv-convert</primary> … … 580 649 <term><command>rebuild-gcj-db</command></term> 581 650 <listitem> 582 <para>Merge the per-solib databases made by 583 <application>aot-compile</application> into one system-wide 584 database.</para> 651 <para> 652 Merge the per-solib databases made by 653 <application>aot-compile</application> into one system-wide 654 database. 655 </para> 585 656 <indexterm zone="gcc rebuild-gcj-db"> 586 657 <primary sortas="b-rebuild-gcj-db">rebuild-gcj-db</primary>
Note:
See TracChangeset
for help on using the changeset viewer.