From 4fb59c9e4dbb6455ef273c83113472be9c8bb51e Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sat, 7 Sep 2019 16:17:39 +0200 Subject: gnu: classpath-bootstrap: Remove call to free. Fixes . * gnu/packages/java.scm (classpath-bootstrap)[arguments]: Add build phase "remove-call-to-free" to let us build ant-bootstrap later. --- gnu/packages/java.scm | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'gnu/packages/java.scm') diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index 403c446a82..cde32e451a 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -152,6 +152,17 @@ (define classpath-bootstrap "--disable-gjdoc") #:phases (modify-phases %standard-phases + ;; XXX: This introduces a memory leak as we remove a call to free up + ;; memory for the file name string. This was necessary because of a + ;; runtime error that would have prevented us from building + ;; ant-bootstrap later. See https://issues.guix.gnu.org/issue/36685 + ;; for the gnarly details. + (add-after 'unpack 'remove-call-to-free + (lambda _ + (substitute* "native/jni/java-io/java_io_VMFile.c" + (("result = cpio_isFileExists.*" m) + (string-append m "\n//"))) + #t)) (add-after 'install 'install-data (lambda _ (invoke "make" "install-data")))))) (native-inputs -- cgit v1.2.3 From 22bd735a3f060206ba42bd2542a4b82ff5e2bf6f Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sat, 7 Sep 2019 16:22:53 +0200 Subject: gnu: jamvm-1-bootstrap: Use older GCC and glibc. * gnu/packages/java.scm (jamvm-1-bootstrap)[native-inputs]: Add GCC version 5 and glibc 2.28. --- gnu/packages/java.scm | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'gnu/packages/java.scm') diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index cde32e451a..fee0970e74 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -202,6 +202,11 @@ (define jamvm-1-bootstrap `(("classpath" ,classpath-bootstrap) ("jikes" ,jikes) ("zlib" ,zlib))) + ;; When built with a recent GCC and glibc the configure step of icedtea-6 + ;; fails with an invalid instruction error. + (native-inputs + `(("gcc" ,gcc-5) + ("libc" ,glibc-2.28))) (home-page "http://jamvm.sourceforge.net/") (synopsis "Small Java Virtual Machine") (description "JamVM is a Java Virtual Machine conforming to the JVM -- cgit v1.2.3 From 306c1e614d617f02e9943c95a829395a2bc713fb Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sat, 7 Sep 2019 16:23:54 +0200 Subject: gnu: icedtea-6: Patch required freetype version. * gnu/packages/java.scm (icedtea-6)[arguments]: Patch hardcoded version string for freetype version check. --- gnu/packages/java.scm | 3 +++ 1 file changed, 3 insertions(+) (limited to 'gnu/packages/java.scm') diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index fee0970e74..e2c47e417f 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -756,6 +756,9 @@ (define-public icedtea-6 (with-directory-excursion "openjdk" (invoke "tar" "xvf" (assoc-ref inputs "hotspot-src")) (rename-file "hg-checkout" "hotspot")) + (substitute* "patches/freetypeversion.patch" + (("REQUIRED_FREETYPE_VERSION = 2.2.1") + "REQUIRED_FREETYPE_VERSION = 2.10.1")) (substitute* "Makefile.in" (("echo \"ERROR: No up-to-date OpenJDK zip available\"; exit -1;") "echo \"trust me\";") -- cgit v1.2.3 From 64ad3989d7ebe85c73d2f49ac65eebdbfbee3bf3 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sat, 7 Sep 2019 16:25:08 +0200 Subject: gnu: icedtea-6: Remove old GCC. * gnu/packages/java.scm (icedtea-6)[native-inputs]: Remove gcc-4.9. --- gnu/packages/java.scm | 1 - 1 file changed, 1 deletion(-) (limited to 'gnu/packages/java.scm') diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index e2c47e417f..51e738d864 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -926,7 +926,6 @@ (define-public icedtea-6 ("fastjar" ,fastjar) ("fontconfig" ,fontconfig) ("freetype" ,freetype) - ("gcc" ,gcc-4.9) ; there's a segmentation fault when compiling with gcc-5 or gcc-7 ("gtk" ,gtk+-2) ("gawk" ,gawk) ("giflib" ,giflib) -- cgit v1.2.3 From 6b7e09ae6bb78c9e2d07a259d93d9b4911234f4b Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sat, 7 Sep 2019 16:25:47 +0200 Subject: gnu: icedtea-7: Patch code to enable build with newer glibc. * gnu/packages/java.scm (icedtea-7)[arguments]: Add build phase "patch-bitrot". (icedtea-8)[arguments]: Remove phase "patch-bitrot". --- gnu/packages/java.scm | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'gnu/packages/java.scm') diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index 51e738d864..def2c8d92d 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -1125,6 +1125,18 @@ (define-public icedtea-7 ((name . _) name)) inputs)))) #t))) + (add-after 'unpack 'patch-bitrot + (lambda _ + (substitute* '("patches/boot/revert-6973616.patch" + "openjdk.src/jdk/make/common/shared/Defs-versions.gmk") + (("REQUIRED_FREETYPE_VERSION = 2.2.1") + "REQUIRED_FREETYPE_VERSION = 2.10.1")) + ;; As of attr 2.4.48 this header is no longer + ;; included. It is provided by the libc instead. + (substitute* '("configure" + "openjdk.src/jdk/src/solaris/native/sun/nio/fs/LinuxNativeDispatcher.c") + (("attr/xattr.h") "sys/xattr.h")) + #t)) (add-after 'unpack 'fix-x11-extension-include-path (lambda* (#:key inputs #:allow-other-keys) (substitute* "openjdk.src/jdk/make/sun/awt/mawt.gmk" @@ -1604,6 +1616,7 @@ (define-public icedtea-8 (delete 'patch-paths) (delete 'set-additional-paths) (delete 'patch-patches) + (delete 'patch-bitrot) ;; Prevent the keytool from recording the current time when ;; adding certificates at build time. (add-after 'unpack 'patch-keystore -- cgit v1.2.3