From: Chris Marusich <cmmarusich@gmail.com>
To: "Gábor Boskovits" <boskovits@gmail.com>
Cc: 29897@debbugs.gnu.org
Subject: [bug#29897] [PATCH core-updates] gnu: java-aqute-libg: Fix compilation on java8.
Date: Thu, 25 Jan 2018 01:30:22 -0800 [thread overview]
Message-ID: <87r2qel1zl.fsf@gmail.com> (raw)
In-Reply-To: <CAE4v=piHL3k237tULxQTR7qbhXfnFy-JRM7nsw+9CT8ggajuZA@mail.gmail.com> ("Gábor Boskovits"'s message of "Wed, 17 Jan 2018 13:15:56 +0100")
[-- Attachment #1.1: Type: text/plain, Size: 1057 bytes --]
Gábor Boskovits <boskovits@gmail.com> writes:
> Thanks for the corrections.
> Looks good to me,
> I won't send an updated patch then.
> Please commit with the modifications.
I made the modifications and also tried to enable the tests (see
attached patch), but I discovered that some of the tests are failing
(and some are passing). Perhaps we should try fixing the tests while
we're here? If you do
/pre-inst-env guix build --keep-failed java-aqute-libg
you can see the failures. The build directory will be kept. If we go
to it, we can find a report of the test failures under the path:
bnd-3.4.0.REL/aQute.libg/test/test-reports
Unfortunately, the ant-build-system doesn't compile the classes with
debug info by default. To enable line numbers etc. in the stack traces,
we'll need to add
debug="true"
to the relevant <javac> tags, as described here:
https://ant.apache.org/manual/Tasks/javac.html
If you could help debug the failures, that would be nice. I will also
look as I get time.
--
Chris
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1.2: 0001-gnu-java-aqute-libg-Explicitly-build-for-Java-7.patch --]
[-- Type: text/x-patch, Size: 2224 bytes --]
From ff975ea3c3e26a57bd97e13f20e7b8aa380b91e6 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?G=C3=A1bor=20Boskovits?= <boskovits@gmail.com>
Date: Fri, 29 Dec 2017 20:17:00 +0100
Subject: [PATCH] gnu: java-aqute-libg: Explicitly build for Java 7.
* gnu/packages/java.scm (java-aqute-libg)[arguments]: Add keyword make-flags
to use source and target 1.7.
Co-authored-by: Chris Marusich <cmmarusich@gmail.com>
---
gnu/packages/java.scm | 23 ++++++++++++++++++++++-
1 file changed, 22 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 2724f0f20..ae7e98977 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -6003,7 +6003,28 @@ it manages project dependencies, gives diffs jars, and much more.")
(arguments
`(#:jar-name "java-aqute-libg.jar"
#:source-dir "aQute.libg/src"
- #:tests? #f)); FIXME: tests are in "aQute.libg/test", not in a java directory
+ ;; The build fails when source/target are more recent than 1.7. This
+ ;; is a known issue. See: https://github.com/bndtools/bnd/issues/1327
+ ;;
+ ;; It is closed as won't fix. There is no way to change the source so
+ ;; that is works on 1.8, and it still works on 1.6, the upstream
+ ;; target. It works fine on 1.7, however, so we use 1.7.
+ #:make-flags (list "-Dant.build.javac.source=1.7"
+ "-Dant.build.javac.target=1.7")
+ #:phases
+ (modify-phases %standard-phases
+ (add-before 'check 'create-java-test-dir
+ ;; Move the test directory into test/java, since that's where
+ ;; ant-build-system's default project in build.xml expects to find
+ ;; the test classes.
+ (lambda _
+ (rename-file "aQute.libg/test" "aQute.libg/test.tmp")
+ (mkdir "aQute.libg/test")
+ (rename-file "aQute.libg/test.tmp" "aQute.libg/test/java"))))
+ #:test-dir "aQute.libg/test"))
+ (native-inputs
+ `(("hamcrest" ,java-hamcrest-core)
+ ("java-junit" ,java-junit)))
(inputs
`(("slf4j" ,java-slf4j-api)
("osgi-annot" ,java-osgi-annotation)
--
2.15.1
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]
next prev parent reply other threads:[~2018-01-25 9:31 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-29 19:17 [bug#29897] [PATCH core-updates] gnu: java-aqute-libg: Fix compilation on java8 Gábor Boskovits
2018-01-17 8:30 ` Chris Marusich
2018-01-17 12:15 ` Gábor Boskovits
2018-01-25 9:30 ` Chris Marusich [this message]
2018-01-25 21:47 ` Gábor Boskovits
2018-01-26 9:58 ` Gábor Boskovits
2018-01-26 10:33 ` Gábor Boskovits
2018-06-24 16:13 ` bug#29897: " Gábor Boskovits
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87r2qel1zl.fsf@gmail.com \
--to=cmmarusich@gmail.com \
--cc=29897@debbugs.gnu.org \
--cc=boskovits@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.