From 442e1bbaaba7f8274c8003b01e6c1ed8a38921f8 Mon Sep 17 00:00:00 2001 From: "Ricardo M. Correia" Date: Mon, 7 Apr 2014 23:17:05 +0200 Subject: [PATCH] icedtea7: Fix building v2.4.6 by backporting fix See http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1726 --- .../compilers/icedtea/build-fix-2.4.6.patch | 58 +++++++++++++++++++ .../development/compilers/icedtea/default.nix | 2 + 2 files changed, 60 insertions(+) create mode 100644 pkgs/development/compilers/icedtea/build-fix-2.4.6.patch diff --git a/pkgs/development/compilers/icedtea/build-fix-2.4.6.patch b/pkgs/development/compilers/icedtea/build-fix-2.4.6.patch new file mode 100644 index 00000000000..d5fcd9f4456 --- /dev/null +++ b/pkgs/development/compilers/icedtea/build-fix-2.4.6.patch @@ -0,0 +1,58 @@ + +# HG changeset patch +# User Andrew John Hughes +# Date 1396030366 0 +# Node ID e8e59c50a451b45bd10cd495b81e5c61b2b4bca8 +# Parent 46f9059509fec2498b1a04ccefee538a45aeff8c +PR1726: configure fails looking for ecj.jar before even trying to find javac + +2014-03-28 Andrew John Hughes + + * acinclude.m4: + (IT_FIND_COMPILER): Check value of ECJ_JAR + and JAVAC here ... + (IT_FIND_ECJ_JAR): ... rather than here where + ${JAVAC} may not yet be defined. + +diff -r 46f9059509fe -r e8e59c50a451 NEWS +--- a/NEWS Fri Mar 28 18:06:31 2014 +0000 ++++ b/NEWS Fri Mar 28 18:12:46 2014 +0000 +@@ -14,6 +14,9 @@ + + New in release 2.4.7 (2014-04-XX): + ++* Bug fixes ++ - PR1726: configure fails looking for ecj.jar before even trying to find javac ++ + New in release 2.4.6 (2014-03-28): + + * Backports +diff -r 46f9059509fe -r e8e59c50a451 acinclude.m4 +--- a/acinclude.m4 Fri Mar 28 18:06:31 2014 +0000 ++++ b/acinclude.m4 Fri Mar 28 18:12:46 2014 +0000 +@@ -134,6 +134,12 @@ + IT_USING_ECJ + IT_WITH_GCJ + ++ if test "x${ECJ_JAR}" = "xno"; then ++ if test "x${JAVAC}" = "x"; then ++ AC_MSG_ERROR("No compiler or ecj JAR file was found.") ++ fi ++ fi ++ + if test x"${GCJ}" != xno ; then + JAVAC="${JAVA} -classpath ${ECJ_JAR} org.eclipse.jdt.internal.compiler.batch.Main" + fi +@@ -350,11 +356,6 @@ + fi + fi + AC_MSG_RESULT(${ECJ_JAR}) +- if test "x${ECJ_JAR}" = "xno"; then +- if test "x${JAVAC}" = "x"; then +- AC_MSG_ERROR("No compiler or ecj JAR file was found.") +- fi +- fi + AC_SUBST(ECJ_JAR) + ]) + + diff --git a/pkgs/development/compilers/icedtea/default.nix b/pkgs/development/compilers/icedtea/default.nix index a8f9617a634..de3a013e7df 100644 --- a/pkgs/development/compilers/icedtea/default.nix +++ b/pkgs/development/compilers/icedtea/default.nix @@ -43,6 +43,8 @@ with srcInfo; stdenv.mkDerivation { inherit url sha256; }; + patches = [ ./build-fix-2.4.6.patch ]; + outputs = [ "out" "jre" ]; # TODO: Probably some more dependencies should be on this list but are being