unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
* [PATCH] Update GCJ.
@ 2015-10-12  8:44 Ricardo Wurmus
  2015-10-12  9:49 ` Ricardo Wurmus
  0 siblings, 1 reply; 4+ messages in thread
From: Ricardo Wurmus @ 2015-10-12  8:44 UTC (permalink / raw)
  To: guix-devel

[-- Attachment #1: Type: text/plain, Size: 695 bytes --]

Hi Guix,

this commit message is a bit hairy.  Instead of just updating gcj-4.8 to
the latest version (4.9) I also made it inherit from our default “gcc”
and renamed it to just “gcj”.  Likewise, “ecj-bootstrap-4.8” is updated
to version 4.9 and renamed to just “ecj-bootstrap”.

The “gcj-4.8” package predates our use of a default “gcc” variable.

The same patch also updates the two packages that used “gcj-4.8” as an
input.

“ecj-bootstrap-4.8” appears to be broken on mips64el and armhf (using it
to bootstrap GCJ results in a broken GCJ on these platforms), and I’m
hoping that the situation is different for the 4.9 release.

~~ Ricardo


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-gnu-gcj-4.8-gcj-Update-to-default-GCC-version.patch --]
[-- Type: text/x-patch, Size: 3893 bytes --]

From 7bc6689ce482df255e9a1fb372736ad0059ebc2a Mon Sep 17 00:00:00 2001
From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
Date: Mon, 12 Oct 2015 10:36:27 +0200
Subject: [PATCH] gnu: gcj-4.8, gcj: Update to default GCC version.

* gnu/packages/gcc.scm (gcj-4.8): Inherit from "gcc" package and rename
  variable to...
  (gcj): ...this new variable.
  (ecj-bootstrap-4.8): Rename variable to...
  (ecj-bootstrap): ...this, updating to version 4.9.
* gnu/packages/java.scm (icedtea6)[native-inputs]: Replace "gcj-4.8"
  with "gcj".
* gnu/packages/music.scm (tuxguitar)[native-inputs]: Likewise.
---
 gnu/packages/gcc.scm   | 18 +++++++++---------
 gnu/packages/java.scm  |  2 +-
 gnu/packages/music.scm |  2 +-
 3 files changed, 11 insertions(+), 11 deletions(-)

diff --git a/gnu/packages/gcc.scm b/gnu/packages/gcc.scm
index d2652ae..7e4f18b 100644
--- a/gnu/packages/gcc.scm
+++ b/gnu/packages/gcc.scm
@@ -451,27 +451,27 @@ using compilers other than GCC."
     (sha256 (base32
               "1c3dk4z5yfj6ic2fn3lyxs27n6pmn2wy9k0r1s17lnkf1bzkrciv"))))
 
-(define-public gcj-4.8
-  (package (inherit gcc-4.8)
+(define-public gcj
+  (package (inherit gcc)
     (name "gcj")
     (inputs
      `(("fastjar" ,fastjar)
        ("perl" ,perl)
        ("javac.in" ,javac.in)
-       ("ecj-bootstrap" ,ecj-bootstrap-4.8)
-       ,@(package-inputs gcc-4.8)))
+       ("ecj-bootstrap" ,ecj-bootstrap)
+       ,@(package-inputs gcc)))
     ;; Suppress the separate "lib" output, because otherwise the
     ;; "lib" and "out" outputs would refer to each other, creating
     ;; a cyclic dependency.  <http://debbugs.gnu.org/18101>
     (outputs
-     (delete "lib" (package-outputs gcc-4.8)))
+     (delete "lib" (package-outputs gcc)))
     (arguments
      (substitute-keyword-arguments `(#:modules ((guix build gnu-build-system)
                                                 (guix build utils)
                                                 (ice-9 regex)
                                                 (srfi srfi-1)
                                                 (srfi srfi-26))
-                                               ,@(package-arguments gcc-4.8))
+                                               ,@(package-arguments gcc))
        ((#:configure-flags flags)
         `(let ((ecj (assoc-ref %build-inputs "ecj-bootstrap")))
            `("--enable-java-home"
@@ -532,13 +532,13 @@ using compilers other than GCC."
                                      ".*(c\\+\\+|cpp|g\\+\\+|gcc.*)"))))
               #t))))))))
 
-(define ecj-bootstrap-4.8
+(define ecj-bootstrap
   (origin
     (method url-fetch)
-    (uri "ftp://sourceware.org/pub/java/ecj-4.8.jar")
+    (uri "ftp://sourceware.org/pub/java/ecj-4.9.jar")
     (sha256
      (base32
-      "10fpqfbdzff1zcbxzh66xc8xbij9saykcj4xzm19wk9p3n7i5zcq"))))
+      "1k9lgm3qamf6zy534pa2zwskr8mpiqrngbv1vw9j4y1ghrdyf1lm"))))
 
 (define-public gcc-objc-4.8
   (custom-gcc gcc-4.8 "gcc-objc" '("objc")))
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 9304a92..9e632f3 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -578,7 +578,7 @@ build process and its dependencies, whereas Make uses Makefile format.")
        ("gtk" ,gtk+-2)
        ("fontconfig" ,fontconfig)
        ("freetype" ,freetype)
-       ("gcj" ,gcj-4.8)))
+       ("gcj" ,gcj)))
     (home-page "http://icedtea.classpath.org")
     (synopsis "Java development kit")
     (description
diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm
index 78310ed..9e767f0 100644
--- a/gnu/packages/music.scm
+++ b/gnu/packages/music.scm
@@ -587,7 +587,7 @@ Laurens Hammond and Don Leslie.")
     (inputs
      `(("swt" ,swt)))
     (native-inputs
-     `(("gcj" ,gcj-4.8)
+     `(("gcj" ,gcj)
        ("pkg-config" ,pkg-config)))
     (home-page "http://tuxguitar.com.ar")
     (synopsis "Multitrack tablature editor and player")
-- 
2.1.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] Update GCJ.
  2015-10-12  8:44 [PATCH] Update GCJ Ricardo Wurmus
@ 2015-10-12  9:49 ` Ricardo Wurmus
  2015-10-12 12:57   ` Ricardo Wurmus
  0 siblings, 1 reply; 4+ messages in thread
From: Ricardo Wurmus @ 2015-10-12  9:49 UTC (permalink / raw)
  To: guix-devel


Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de> writes:

> “ecj-bootstrap-4.8” appears to be broken on mips64el and armhf (using it
> to bootstrap GCJ results in a broken GCJ on these platforms), and I’m
> hoping that the situation is different for the 4.9 release.

I just tried to build both icedtea6 and icedtea7 with this, but both
fail with the same error, similar to this one:

~~~~~~~~~~~~~~
Rewriting and unlinking classes ... done. 
Calculating hash values for String objects .. done. 
Calculating fingerprints ... done. 
Removing unshareable information ... done. 
Moving common symbols to metadata section at 0x00007fffcc606ae0 ... done. 
Moving vmSymbols to metadata section at 0x00007fffcc8171b8 ... done. 
Moving the remaining symbols to metadata section at 0x00007fffcc818a48 ... done. 
Moved 57289 symbols, 2170728 bytes.
Moving pre-ordered read-only objects to shared space at 0x00007fffcae00000 ... done. 
Moving read-only objects to shared space at 0x00007fffcb468f10 ... done. 
Moving string char arrays to shared space at 0x00007fffcb46bbb0 ... done. 
Moving pre-ordered read-write objects to shared space at 0x00007fffcb800000 ... done. 
Moving read-write objects to shared space at 0x00007fffcc4260a8 ... done. 
Moving String objects to shared space at 0x00007fffcc4878b0 ... done. 
Read-write space ends at 0x00007fffcc4fec30, 13626416 bytes.
Updating references to shared objects ... done. 

An error has occurred while processing the shared archive file.
Unable to write to shared archive file.
Error occurred during initialization of VM
Unable to use shared archive.
Makefile:2670: recipe for target 'stamps/add-archive-ecj.stamp' failed
make: *** [stamps/add-archive-ecj.stamp] Error 1
phase `build' failed after 1465.3 seconds
~~~~~~~~~~~~~~

Earlier there is a warning about a version mismatch:

~~~~~~~~~~~~~~
WARNING: The file jvmti.h is not the same interface as the VM version.
          this workspace has jvmti.h 1.1.102 and 
          HOTSPOT_IMPORT_PATH contains jvmti.h 1.2.1 
 
WARNING: Possible HotSpot VM interface conflict. 
         HOTSPOT_IMPORT_PATH is used to import files from the VM build. 
         It is also used to verify that any copied files are consistent between 
         these two components. It has been detected that one or more of the 
         VM interface files inside this workspace may not match the interfaces 
         exported by the VM, or the VM versions could not be found. 
         The list of VM interface files is: 
             jvmti.h jvmticmlr.h. 
         This workspace has copies of these files at: 
           ./../src/share/javavm/export and ./../src/solaris/javavm/export 
         for build purposes, and they should contain the same interfaces 
         as the VM versions imported from: 
           $(HOTSPOT_IMPORT_PATH)/include 
                (i.e. /tmp/nix-build-icedtea6-1.13.7.drv-0/icedtea6-1.13.7/openjdk.build-ecj/hotspot/import/include) 
         If an interface indeed doesn't match, then the use of this interface 
         at JDK runtime could cause serious errors. 
 
 
VM Interface Differences: /tmp/nix-build-icedtea6-1.13.7.drv-0/icedtea6-1.13.7/openjdk.build-ecj/tmp/jvmti.hdiffs
Version mis-match
~~~~~~~~~~~~~~

This is probably related.  Too bad.  I’ll try to figure out what’s going
on here.

~~ Ricardo

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] Update GCJ.
  2015-10-12  9:49 ` Ricardo Wurmus
@ 2015-10-12 12:57   ` Ricardo Wurmus
  2015-10-12 19:02     ` Ludovic Courtès
  0 siblings, 1 reply; 4+ messages in thread
From: Ricardo Wurmus @ 2015-10-12 12:57 UTC (permalink / raw)
  To: guix-devel

[-- Attachment #1: Type: text/plain, Size: 1385 bytes --]


Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de> writes:

> Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de> writes:
>
>> “ecj-bootstrap-4.8” appears to be broken on mips64el and armhf (using it
>> to bootstrap GCJ results in a broken GCJ on these platforms), and I’m
>> hoping that the situation is different for the 4.9 release.
>
> I just tried to build both icedtea6 and icedtea7 with this, but both
> fail with the same error, similar to this one:

Turns out that it was just icedtea6 that was failing.  “icedtea7”
depends on “ant”, which is built by “icedtea6”.  This is unnecessary,
because “ant” can actually be built with the latest GCJ.

So I made the following changes:

* build “ant” with the new “gcj” package instead of “icedtea6”
* replace “ant-bootstrap” (the ugly binary version of “ant”) with the
  regular “ant” as it no longer results in a circular dependency.
  (Since “icedtea7” inherits from “icedtea6” I had to make a minor
  change to that package as well.)
* update “icedtea6” to latest version (overdue security update; sorry)

With these changes “icedtea6” builds fine and I’m happy that we could do
with one bootstrap binary less.  These four patches (the one to update
GCJ and the three attached here) are very simple and I’d be happy for a
review!

~~ Ricardo


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-gnu-ant-Build-with-GCJ.patch --]
[-- Type: text/x-patch, Size: 1392 bytes --]

From f7900bd2a3f999d18742c59ec58d7748c8c051dd Mon Sep 17 00:00:00 2001
From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
Date: Mon, 12 Oct 2015 14:21:15 +0200
Subject: [PATCH 1/3] gnu: ant: Build with GCJ.

* gnu/packages/java.scm (ant)[native-inputs]: Replace "icedtea6" with
  "gcj".
---
 gnu/packages/java.scm | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 9e632f3..e4d0afb 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -159,8 +159,8 @@ is implemented.")
         (alist-replace
          'build
          (lambda _
-           (setenv "JAVA_HOME"
-                   (assoc-ref %build-inputs "icedtea6"))
+           (setenv "JAVA_HOME" (string-append (assoc-ref %build-inputs "gcj")
+                                              "/lib/jvm"))
            ;; Disable tests to avoid dependency on hamcrest-core, which needs
            ;; Ant to build.  This is necessary in addition to disabling the
            ;; "check" phase, because the dependency on "test-jar" would always
@@ -174,7 +174,7 @@ is implemented.")
           'configure
           (alist-delete 'install %standard-phases))))))
     (native-inputs
-     `(("icedtea6" ,icedtea6 "jdk")))
+     `(("gcj" ,gcj)))
     (home-page "http://ant.apache.org")
     (synopsis "Build tool for Java")
     (description
-- 
2.1.0


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #3: 0002-gnu-icedtea6-Replace-ant-bootstrap-with-ant.patch --]
[-- Type: text/x-patch, Size: 3853 bytes --]

From 47a52495617510a7298beba9be06aa61397a2004 Mon Sep 17 00:00:00 2001
From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
Date: Mon, 12 Oct 2015 14:24:03 +0200
Subject: [PATCH 2/3] gnu: icedtea6: Replace "ant-bootstrap" with "ant".

* gnu/packages/java.scm (icedtea6)[native-inputs]: Replace
  "ant-bootstrap" with "ant".
  [arguments]: Remove steps to unpack and use "ant-bootstrap".
  (icedtea7)[native-inputs]: Remove explicit references to
  "ant-bootstrap" and "ant".
---
 gnu/packages/java.scm | 21 ++++-----------------
 1 file changed, 4 insertions(+), 17 deletions(-)

diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index e4d0afb..4bb0781 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -276,10 +276,7 @@ build process and its dependencies, whereas Make uses Makefile format.")
         'unpack
         (lambda* (#:key source inputs #:allow-other-keys)
           (and (zero? (system* "tar" "xvf" source))
-               (zero? (system* "tar" "xvjf"
-                               (assoc-ref inputs "ant-bootstrap")))
                (begin
-                 (patch-shebang "apache-ant-1.9.4/bin/ant")
                  (chdir (string-append ,name "-" ,version))
                  (mkdir "openjdk")
                  (with-directory-excursion "openjdk"
@@ -383,7 +380,6 @@ build process and its dependencies, whereas Make uses Makefile format.")
            (lambda* (#:key inputs #:allow-other-keys)
              (let* ((gcjdir  (assoc-ref %build-inputs "gcj"))
                     (gcjlib  (string-append gcjdir "/lib"))
-                    (antpath (string-append (getcwd) "/../apache-ant-1.9.4"))
                     ;; Get target-specific include directory so that
                     ;; libgcj-config.h is found when compiling hotspot.
                     (gcjinclude (let* ((port (open-input-pipe "gcj -print-file-name=include"))
@@ -407,9 +403,7 @@ build process and its dependencies, whereas Make uses Makefile format.")
                                       "/include"))
                (setenv "ALT_FREETYPE_LIB_PATH"
                        (string-append (assoc-ref %build-inputs "freetype")
-                                      "/lib"))
-               (setenv "PATH" (string-append antpath "/bin:"
-                                             (getenv "PATH")))))
+                                      "/lib"))))
            (alist-cons-before
             'check 'fix-test-framework
             (lambda _
@@ -528,13 +522,7 @@ build process and its dependencies, whereas Make uses Makefile format.")
                     (copy-recursively "openjdk.build/j2sdk-image" jdk)))
                 %standard-phases)))))))))))
     (native-inputs
-     `(("ant-bootstrap"
-        ,(origin
-           (method url-fetch)
-           (uri "https://www.apache.org/dist/ant/binaries/apache-ant-1.9.4-bin.tar.bz2")
-           (sha256
-            (base32
-             "1kw801p8h5x4f0g8i5yknppssrj5a3xy1aqrkpfnk22bd1snbh90"))))
+     `(("ant" ,ant)
        ("alsa-lib" ,alsa-lib)
        ("attr" ,attr)
        ("autoconf" ,autoconf)
@@ -738,8 +726,7 @@ build process and its dependencies, whereas Make uses Makefile format.")
                     #t))
                  (delete 'patch-patches))))))
       (native-inputs
-       `(("ant" ,ant)
-         ("openjdk-drop"
+       `(("openjdk-drop"
           ,(drop "openjdk"
                  "0gs6vbj5c09516r460r68i7vm652sb25h973kq9hfx749qbs0s01"))
          ("corba-drop"
@@ -761,4 +748,4 @@ build process and its dependencies, whereas Make uses Makefile format.")
           ,(drop "hotspot"
                  "1cv8df2s89mnjzg4rja4i89d4fr8n0c3v5y2cqbww1ma1463n100"))
          ,@(fold alist-delete (package-native-inputs icedtea6)
-                 '("openjdk6-src" "ant-bootstrap")))))))
+                 '("openjdk6-src")))))))
-- 
2.1.0


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #4: 0003-gnu-icedtea6-Update-to-1.13.8.patch --]
[-- Type: text/x-patch, Size: 1862 bytes --]

From 2a2a4e366b827138e171653aa694e605ebd75db3 Mon Sep 17 00:00:00 2001
From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
Date: Mon, 12 Oct 2015 14:29:06 +0200
Subject: [PATCH 3/3] gnu: icedtea6: Update to 1.13.8.

* gnu/packages/java.scm (icedtea6): Update to 1.13.8.
---
 gnu/packages/java.scm | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 4bb0781..5fa546a 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -187,7 +187,7 @@ build process and its dependencies, whereas Make uses Makefile format.")
 (define-public icedtea6
   (package
     (name "icedtea6")
-    (version "1.13.7")
+    (version "1.13.8")
     (source (origin
               (method url-fetch)
               (uri (string-append
@@ -195,7 +195,7 @@ build process and its dependencies, whereas Make uses Makefile format.")
                     version ".tar.xz"))
               (sha256
                (base32
-                "0fqq898h0mk554mya5z4j9p4x6sg2qj0ckqzx65x49zcjjp69jm5"))
+                "1nqaq2xjz88rfzm94l28c0cc48gdiwl8ijw9c46s14z3awwn5g7w"))
               (modules '((guix build utils)))
               (snippet
                '(substitute* "Makefile.in"
@@ -557,10 +557,10 @@ build process and its dependencies, whereas Make uses Makefile format.")
        ("openjdk6-src"
         ,(origin
            (method url-fetch)
-           (uri "https://java.net/downloads/openjdk6/openjdk-6-src-b35-14_apr_2015.tar.gz")
+           (uri "https://java.net/downloads/openjdk6/openjdk-6-src-b36-22_jul_2015.tar.gz")
            (sha256
             (base32
-             "05glw29vy4yw9rkjy9y8wg6ybzi89gjwi19qpnfda978x02r2x5p"))))
+             "0mdckpazjijf6ggxzah2nq99lgsi0jk9pjbxhfq39b9lawvb45ln"))))
        ("lcms" ,lcms)
        ("zlib" ,zlib)
        ("gtk" ,gtk+-2)
-- 
2.1.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] Update GCJ.
  2015-10-12 12:57   ` Ricardo Wurmus
@ 2015-10-12 19:02     ` Ludovic Courtès
  0 siblings, 0 replies; 4+ messages in thread
From: Ludovic Courtès @ 2015-10-12 19:02 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: guix-devel

Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de> skribis:

> So I made the following changes:
>
> * build “ant” with the new “gcj” package instead of “icedtea6”
> * replace “ant-bootstrap” (the ugly binary version of “ant”) with the
>   regular “ant” as it no longer results in a circular dependency.
>   (Since “icedtea7” inherits from “icedtea6” I had to make a minor
>   change to that package as well.)
> * update “icedtea6” to latest version (overdue security update; sorry)

OK.

> From f7900bd2a3f999d18742c59ec58d7748c8c051dd Mon Sep 17 00:00:00 2001
> From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
> Date: Mon, 12 Oct 2015 14:21:15 +0200
> Subject: [PATCH 1/3] gnu: ant: Build with GCJ.
>
> * gnu/packages/java.scm (ant)[native-inputs]: Replace "icedtea6" with
>   "gcj".

OK.  (I’m surprised it builds with GCJ without modifications; that’s
good news.)

> From 47a52495617510a7298beba9be06aa61397a2004 Mon Sep 17 00:00:00 2001
> From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
> Date: Mon, 12 Oct 2015 14:24:03 +0200
> Subject: [PATCH 2/3] gnu: icedtea6: Replace "ant-bootstrap" with "ant".
>
> * gnu/packages/java.scm (icedtea6)[native-inputs]: Replace
>   "ant-bootstrap" with "ant".
>   [arguments]: Remove steps to unpack and use "ant-bootstrap".
>   (icedtea7)[native-inputs]: Remove explicit references to
>   "ant-bootstrap" and "ant".

OK.

> From 2a2a4e366b827138e171653aa694e605ebd75db3 Mon Sep 17 00:00:00 2001
> From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
> Date: Mon, 12 Oct 2015 14:29:06 +0200
> Subject: [PATCH 3/3] gnu: icedtea6: Update to 1.13.8.
>
> * gnu/packages/java.scm (icedtea6): Update to 1.13.8.

OK.

The patch that updates GCJ at the beginning of this thread also LGTM.

Thanks!

Ludo’.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2015-10-12 19:02 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-12  8:44 [PATCH] Update GCJ Ricardo Wurmus
2015-10-12  9:49 ` Ricardo Wurmus
2015-10-12 12:57   ` Ricardo Wurmus
2015-10-12 19:02     ` Ludovic Courtès

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).