gnu: icedtea-7: Build with ECJ 4, Jamvm, and GNU Classpath.
* gnu/packages/java.scm (icedtea-7)[native-inputs]: Remove icedtea-6, you've served us well; add classpath-devel, ecj4-javac-wrapper, and jamvm-with-ecj4. [arguments]: Replace argument to --with-jdk-home configure flag; add --with-ecj, --with-java, and --with-jar; remove #:locale argument; add build phase 'use-classpath... (icedtea-8)[arguments]: ...and remove that new phase here. [native-inputs]: Remove classpath-devel, ecj4-javac-wrapper, jamvm, and fastjar.
This commit is contained in:
parent
9b809c2b87
commit
a53b898d2f
1 changed files with 36 additions and 15 deletions
|
@ -115,9 +115,9 @@
|
||||||
;; much more support for Java 1.6 than the latest release, but we need to
|
;; much more support for Java 1.6 than the latest release, but we need to
|
||||||
;; build 0.99 first to get a working version of javah. ECJ, the development
|
;; build 0.99 first to get a working version of javah. ECJ, the development
|
||||||
;; version of GNU Classpath, and the latest version of JamVM make up the
|
;; version of GNU Classpath, and the latest version of JamVM make up the
|
||||||
;; second stage JDK with which we can build the OpenJDK with the Icedtea 1.x
|
;; second stage JDK with which we can build the OpenJDK with the Icedtea 2.x
|
||||||
;; build framework. We then build the more recent JDKs Icedtea 2.x and
|
;; build framework. We then build the more recent JDK Icedtea 3.x, and all
|
||||||
;; Icedtea 3.x.
|
;; other versions of OpenJDK.
|
||||||
|
|
||||||
(define-public libantlr3c
|
(define-public libantlr3c
|
||||||
(package
|
(package
|
||||||
|
@ -1320,9 +1320,6 @@ bootstrapping purposes.")
|
||||||
;; gremlin) doesn't support it yet, so skip this phase.
|
;; gremlin) doesn't support it yet, so skip this phase.
|
||||||
#:validate-runpath? #f
|
#:validate-runpath? #f
|
||||||
|
|
||||||
;; Apparently, the C locale is needed for some of the tests.
|
|
||||||
#:locale "C"
|
|
||||||
|
|
||||||
#:modules ((guix build utils)
|
#:modules ((guix build utils)
|
||||||
(guix build gnu-build-system)
|
(guix build gnu-build-system)
|
||||||
(ice-9 match)
|
(ice-9 match)
|
||||||
|
@ -1343,9 +1340,17 @@ bootstrapping purposes.")
|
||||||
"--disable-downloading"
|
"--disable-downloading"
|
||||||
"--disable-tests" ;they are run in the check phase instead
|
"--disable-tests" ;they are run in the check phase instead
|
||||||
"--with-openjdk-src-dir=./openjdk.src"
|
"--with-openjdk-src-dir=./openjdk.src"
|
||||||
|
,(string-append "--with-ecj="
|
||||||
|
(assoc-ref %build-inputs "ecj4-javac-wrapper")
|
||||||
|
"/bin/javac")
|
||||||
,(string-append "--with-jdk-home="
|
,(string-append "--with-jdk-home="
|
||||||
(assoc-ref %build-inputs "jdk")))
|
(assoc-ref %build-inputs "classpath"))
|
||||||
|
,(string-append "--with-java="
|
||||||
|
(assoc-ref %build-inputs "jamvm")
|
||||||
|
"/bin/jamvm")
|
||||||
|
,(string-append "--with-jar="
|
||||||
|
(assoc-ref %build-inputs "classpath")
|
||||||
|
"/bin/gjar"))
|
||||||
#:phases
|
#:phases
|
||||||
(modify-phases %standard-phases
|
(modify-phases %standard-phases
|
||||||
(replace 'unpack
|
(replace 'unpack
|
||||||
|
@ -1369,8 +1374,20 @@ bootstrapping purposes.")
|
||||||
(filter (cut string-suffix? "-drop" <>)
|
(filter (cut string-suffix? "-drop" <>)
|
||||||
(map (match-lambda
|
(map (match-lambda
|
||||||
((name . _) name))
|
((name . _) name))
|
||||||
inputs))))
|
inputs)))))))
|
||||||
#t)))
|
(add-after 'unpack 'use-classpath
|
||||||
|
(lambda* (#:key inputs #:allow-other-keys)
|
||||||
|
(let ((tools (search-input-file inputs "/share/classpath/tools.zip"))
|
||||||
|
(rt.jar (search-input-file inputs "/lib/rt.jar")))
|
||||||
|
;; GNU Classpath does not provide rt.jar, but jamvm provides
|
||||||
|
;; Classpath's glibj.zip as rt.jar, so we just use that.
|
||||||
|
(substitute* "Makefile.in"
|
||||||
|
(("\\$\\(SYSTEM_JDK_DIR\\)/jre/lib/rt.jar") rt.jar))
|
||||||
|
;; Make sure we can find all classes.
|
||||||
|
(setenv "CLASSPATH"
|
||||||
|
(string-append rt.jar ":" tools))
|
||||||
|
(setenv "JAVACFLAGS"
|
||||||
|
(string-append "-cp " rt.jar ":" tools)))))
|
||||||
(add-after 'unpack 'patch-bitrot
|
(add-after 'unpack 'patch-bitrot
|
||||||
(lambda _
|
(lambda _
|
||||||
(substitute* '("patches/boot/revert-6973616.patch"
|
(substitute* '("patches/boot/revert-6973616.patch"
|
||||||
|
@ -1779,10 +1796,14 @@ bootstrapping purposes.")
|
||||||
"icedtea-7-hotspot-aarch64-use-c++98.patch"))))
|
"icedtea-7-hotspot-aarch64-use-c++98.patch"))))
|
||||||
("ant" ,ant-bootstrap)
|
("ant" ,ant-bootstrap)
|
||||||
("attr" ,attr)
|
("attr" ,attr)
|
||||||
|
("classpath" ,classpath-devel)
|
||||||
("coreutils" ,coreutils)
|
("coreutils" ,coreutils)
|
||||||
("diffutils" ,diffutils) ;for tests
|
("diffutils" ,diffutils) ;for tests
|
||||||
|
("ecj4-javac-wrapper" ,ecj4-javac-wrapper)
|
||||||
|
("fastjar" ,fastjar) ;only for the configure phase; we actually use gjar
|
||||||
("gawk" ,gawk)
|
("gawk" ,gawk)
|
||||||
("grep" ,grep)
|
("grep" ,grep)
|
||||||
|
("jamvm" ,jamvm-with-ecj4)
|
||||||
("libtool" ,libtool)
|
("libtool" ,libtool)
|
||||||
("pkg-config" ,pkg-config)
|
("pkg-config" ,pkg-config)
|
||||||
("wget" ,wget)
|
("wget" ,wget)
|
||||||
|
@ -1790,12 +1811,10 @@ bootstrapping purposes.")
|
||||||
("cpio" ,cpio)
|
("cpio" ,cpio)
|
||||||
("zip" ,zip)
|
("zip" ,zip)
|
||||||
("unzip" ,unzip)
|
("unzip" ,unzip)
|
||||||
("fastjar" ,fastjar)
|
|
||||||
("libxslt" ,libxslt) ;for xsltproc
|
("libxslt" ,libxslt) ;for xsltproc
|
||||||
("nss-certs" ,nss-certs)
|
("nss-certs" ,nss-certs)
|
||||||
("perl" ,perl)
|
("perl" ,perl)
|
||||||
("procps" ,procps) ;for "free", even though I'm not sure we should use it
|
("procps" ,procps))) ;for "free", even though I'm not sure we should use it
|
||||||
("jdk" ,icedtea-6 "jdk")))
|
|
||||||
(inputs
|
(inputs
|
||||||
(list alsa-lib
|
(list alsa-lib
|
||||||
cups
|
cups
|
||||||
|
@ -1900,6 +1919,7 @@ IcedTea build harness.")
|
||||||
(delete 'set-additional-paths)
|
(delete 'set-additional-paths)
|
||||||
(delete 'patch-patches)
|
(delete 'patch-patches)
|
||||||
(delete 'patch-bitrot)
|
(delete 'patch-bitrot)
|
||||||
|
(delete 'use-classpath)
|
||||||
;; Prevent the keytool from recording the current time when
|
;; Prevent the keytool from recording the current time when
|
||||||
;; adding certificates at build time.
|
;; adding certificates at build time.
|
||||||
(add-after 'unpack 'patch-keystore
|
(add-after 'unpack 'patch-keystore
|
||||||
|
@ -2003,8 +2023,9 @@ new Date();"))
|
||||||
,(drop "shenandoah"
|
,(drop "shenandoah"
|
||||||
"0k33anxdzw1icn072wynfmmdjhsv50hay0j1sfkfxny12rb3vgdy"))
|
"0k33anxdzw1icn072wynfmmdjhsv50hay0j1sfkfxny12rb3vgdy"))
|
||||||
,@(fold alist-delete (package-native-inputs icedtea-7)
|
,@(fold alist-delete (package-native-inputs icedtea-7)
|
||||||
'("jdk" "openjdk-src" "corba-drop" "jaxp-drop" "jaxws-drop"
|
'("openjdk-src" "corba-drop" "jaxp-drop" "jaxws-drop"
|
||||||
"jdk-drop" "langtools-drop" "hotspot-drop")))))))
|
"jdk-drop" "langtools-drop" "hotspot-drop"
|
||||||
|
"classpath" "ecj4-javac-wrapper" "jamvm" "fastjar")))))))
|
||||||
|
|
||||||
(define-public openjdk9
|
(define-public openjdk9
|
||||||
(package
|
(package
|
||||||
|
|
Reference in a new issue