Skip Menu |

This queue is for tickets about the Inline-Java CPAN distribution.

Report information
The Basics
Id: 98683
Status: resolved
Worked: 1 hour (60 min)
Priority: 0/
Queue: Inline-Java

People
Owner: ETJ [...] cpan.org
Requestors: gregoa [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



From: gregoa [...] cpan.org
Subject: libinline-java-perl: FTBFS on mips: test suite issues
We have the following bug reported to the Debian package of Inline-Java (https://bugs.debian.org/754755): It doesn't seem to be a bug in the packaging, so you may want to take a look. Thanks! The original bug report is about mips but actually the package fails to build on all kinds of architectures; cf. the build logs at https://buildd.debian.org/status/logs.php?pkg=libinline-java-perl ------8<-----------8<-----------8<-----------8<-----------8<----- Source: libinline-java-perl Version: 0.53-2 Severity: serious Justification: FTBFS Hi, your package no longer builds on mips: | Test Summary Report | ------------------- | t/04_members.t (Wstat: 11 Tests: 0 Failed: 0) | Non-zero wait status: 11 | Parse errors: Bad plan. You planned 28 tests but ran 0. | t/13_handles.t (Wstat: 11 Tests: 0 Failed: 0) | Non-zero wait status: 11 | Parse errors: Bad plan. You planned 12 tests but ran 0. | Files=19, Tests=287, 995 wallclock secs ( 1.60 usr 0.64 sys + 501.64 cusr 494.28 csys = 998.16 CPU) | Result: FAIL | Failed 2/19 test programs. 0/287 subtests failed. | make[1]: *** [test_dynamic] Error 255 | Makefile:886: recipe for target 'test_dynamic' failed | make[1]: Leaving directory '/«PKGBUILDDIR»' | make: *** [debian/stamp-makefile-check] Error 2 | /usr/share/cdbs/1/class/makefile.mk:67: recipe for target 'debian/stamp-makefile-check' failed | dpkg-buildpackage: error: debian/rules build-arch gave error exit status 2 Full build log: https://buildd.debian.org/status/fetch.php?pkg=libinline-java-perl&arch=mips&ver=0.53-2&stamp=1405227323 Mraw, KiBi. ------8<-----------8<-----------8<-----------8<-----------8<----- Thanks for considering, gregor herrmann, Debian Perl Group
On the git master version, these tests pass. This is my Java version: $ java -version java version "1.5.0" gij (GNU libgcj) version 4.4.7 20120313 (Red Hat 4.4.7-4) Copyright (C) 2007 Free Software Foundation, Inc. Is it possible for you to try against latest (0.54, on CPAN shortly)?
The CPAN release of 0.540 has been withdrawn. Please get in touch with Ingy on this matter.
From: jurica.stanojkovic [...] rt-rk.com
Hello, I have tried to build libinline-java-perl_0.53-3 from Debian on mips. Package FTBFS on mips. But same package (libinline-java-perl_0.53-3) can be built from same source manually with following commands: perl Makefile.PL J2SDK=/usr/ make make test If built manually all tests pass on mips. java version is "1.7.0_65" Can someone please help with this issue? Thank you! Regards, Jurica On Mon Sep 08 21:44:11 2014, ETJ wrote: Show quoted text
> On the git master version, these tests pass. This is my Java version: > > $ java -version > java version "1.5.0" > gij (GNU libgcj) version 4.4.7 20120313 (Red Hat 4.4.7-4) > Copyright (C) 2007 Free Software Foundation, Inc. > > Is it possible for you to try against latest (0.54, on CPAN shortly)?
RT-Send-CC: jurica.stanojkovic [...] rt-rk.com
Could you try with version 0.55, just released?
CC: 754755 [...] bugs.debian.org
Subject: Re: [rt.cpan.org #98683] libinline-java-perl: FTBFS on mips: test suite issues
Date: Fri, 14 Nov 2014 19:07:13 +0100
To: Ed J via RT <bug-Inline-Java [...] rt.cpan.org>
From: gregor herrmann <gregoa [...] debian.org>
On Fri, 14 Nov 2014 10:16:59 -0500, Ed J via RT wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=98683 > > > Could you try with version 0.55, just released?
I've now tried 0.55 on gabrielli.debian.org (the mips portbox). The first build attempt fails with: #v+ Running Mkbootstrap for Inline::Java::JNI () chmod 644 JNI.bs /usr/bin/perl /usr/share/perl/5.20.1/ExtUtils/xsubpp -typemap /usr/share/perl/5.20/ExtUtils/typemap -typemap typemap JNI.xs > JNI.xsc && mv JNI.xsc JNI.c cc -c -I/usr/lib/jvm/default-java/include -I/usr/lib/jvm/default-java/include -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fwrapv -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wall -D_FORTIFY_SOURCE=2 -DVERSION=\"0.53_90\" -DXS_VERSION=\"0.53_90\" -fPIC "-I/usr/lib/mips-linux-gnu/perl/5.20/CORE" JNI.c JNI.xs: In function 'check_exception_from_perl': JNI.xs:51:3: error: format not a string literal and no format arguments [-Werror=format-security] croak(msg) ; ^ #v- After fixing this with #v+ --- a/Java/JNI.xs +++ b/Java/JNI.xs @@ -48,7 +48,7 @@ if ((*(env))->ExceptionCheck(env)){ (*(env))->ExceptionDescribe(env) ; (*(env))->ExceptionClear(env) ; - croak(msg) ; + croak("%s", msg) ; } } #v- the build succeeds but the tests still fail: #v- Test Summary Report ------------------- t/01_init.t (Wstat: 11 Tests: 0 Failed: 0) Non-zero wait status: 11 Parse errors: Bad plan. You planned 1 tests but ran 0. t/02_primitives.t (Wstat: 11 Tests: 0 Failed: 0) Non-zero wait status: 11 Parse errors: Bad plan. You planned 102 tests but ran 0. t/03_objects.t (Wstat: 11 Tests: 0 Failed: 0) Non-zero wait status: 11 Parse errors: Bad plan. You planned 16 tests but ran 0. t/05_arrays.t (Wstat: 11 Tests: 0 Failed: 0) Non-zero wait status: 11 Parse errors: Bad plan. You planned 55 tests but ran 0. t/07_polymorph.t (Wstat: 11 Tests: 0 Failed: 0) Non-zero wait status: 11 Parse errors: Bad plan. You planned 24 tests but ran 0. t/08_study.t (Wstat: 11 Tests: 0 Failed: 0) Non-zero wait status: 11 Parse errors: No plan found in TAP output t/09_usages.t (Wstat: 11 Tests: 0 Failed: 0) Non-zero wait status: 11 Parse errors: Bad plan. You planned 6 tests but ran 0. t/14_encoding.t (Wstat: 11 Tests: 0 Failed: 0) Non-zero wait status: 11 Parse errors: Bad plan. You planned 9 tests but ran 0. t/99_end.t (Wstat: 11 Tests: 0 Failed: 0) Non-zero wait status: 11 Parse errors: Bad plan. You planned 1 tests but ran 0. Files=19, Tests=102, 812 wallclock secs ( 1.06 usr 0.42 sys + 406.64 cusr 404.04 csys = 812.16 CPU) Result: FAIL Failed 9/19 test programs. 0/102 subtests failed. #v- (full build log attached) Cheers, gregor -- .''`. Homepage: http://info.comodo.priv.at/ - OpenPGP key 0xBB3A68018649AA06 : :' : Debian GNU/Linux user, admin, and developer - http://www.debian.org/ `. `' Member of VIBE!AT & SPI, fellow of the Free Software Foundation Europe `- NP: U2: Love Comes Tumbling

Message body is not shown because sender requested not to inline it.

Download signature.asc
application/pgp-signature 949b

Message body not shown because it is not plain text.

Thanks for the patch, I put it on git. Could you try this and paste results? make && prove -bv t
Subject: Re: [rt.cpan.org #98683] libinline-java-perl: FTBFS on mips: test suite issues
Date: Mon, 17 Nov 2014 18:25:34 +0100
To: Ed J via RT <bug-Inline-Java [...] rt.cpan.org>
From: gregor herrmann <gregoa [...] debian.org>

Message body is not shown because it is too large.

Message body is not shown because sender requested not to inline it.

Download signature.asc
application/pgp-signature 949b

Message body not shown because it is not plain text.

CC: "gregoa [...] debian.org" <gregoa [...] debian.org>, "bug-Inline-Java [...] rt.cpan.org" <bug-Inline-Java [...] rt.cpan.org>
Subject: Re: [rt.cpan.org #98683] libinline-java-perl: FTBFS on mips: test suite issues
Date: Fri, 21 Nov 2014 13:37:16 +0000
To: "754755 [...] bugs.debian.org" <754755 [...] bugs.debian.org>
From: Jurica Stanojkovic <Jurica.Stanojkovic [...] imgtec.com>
Hello, Firstly, I have applied proposed patch. patch for Java/JNI.xs: --- a/Java/JNI.xs +++ b/Java/JNI.xs @@ -48,7 +48,7 @@ if ((*(env))->ExceptionCheck(env)){ (*(env))->ExceptionDescribe(env) ; (*(env))->ExceptionClear(env) ; - croak(msg) ; + croak("%s", msg) ; } } Secondly, I have tried to replace CDBS debian/rules in package libinline-java-perl file with the folowing debian/rules: debian/rules: ------------------------------------------------------------------------------- #!/usr/bin/make -f export PERL_MM_USE_DEFAULT := 1 %: dh $@ override_dh_auto_configure: DESTDIR=$$(pwd)/ perl Makefile.PL J2SDK=/usr/lib/jvm/default-java override_dh_usrlocal: ------------------------------------------------------------------------------- With these changes package does build successfully (using sbuild) on mips, mipsel, and i386. We are not sure why this issue is happening only on mips and not on mipsel, i386, etc. I have noticed that package is also FTBFS on sparc with similar error. Could somebody please test this on sparc? Thank you! Regards, Jurica
RT-Send-CC: Jurica.Stanojkovic [...] imgtec.com, 754755 [...] bugs.debian.org, jurica.stanojkovic [...] rt-rk.com, gregoa [...] debian.org
Please could you try the new 0.56 rather than stick with 0.53?
Subject: Bug#754755: Info received ([rt.cpan.org #98683] libinline-java-perl: FTBFS on mips: test suite issues)
Date: Fri, 21 Nov 2014 15:51:09 +0000
To: bug-Inline-Java [...] rt.cpan.org
From: owner [...] bugs.debian.org (Debian Bug Tracking System)
Thank you for the additional information you have supplied regarding this Bug report. This is an automatically generated reply to let you know your message has been received. Your message is being forwarded to the package maintainers and other interested parties for their attention; they will reply in due course. Your message has been sent to the package maintainer(s): Debian Perl Group <pkg-perl-maintainers@lists.alioth.debian.org> If you wish to submit further information on this problem, please send it to 754755@bugs.debian.org. Please do not send mail to owner@bugs.debian.org unless you wish to report a problem with the Bug-tracking system. -- 754755: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=754755 Debian Bug Tracking System Contact owner@bugs.debian.org with problems
CC: "gregoa [...] debian.org" <gregoa [...] debian.org>
Subject: RE: [rt.cpan.org #98683] libinline-java-perl: FTBFS on mips: test suite issues
Date: Wed, 26 Nov 2014 17:23:04 +0000
To: "754755 [...] bugs.debian.org" <754755 [...] bugs.debian.org>, "bug-Inline-Java [...] rt.cpan.org" <bug-Inline-Java [...] rt.cpan.org>
From: Jurica Stanojkovic <Jurica.Stanojkovic [...] imgtec.com>
Hello, Tests are still failing in new version 0.56 during build. I have used sbuild for package build. Build log is attached. Regards, Jurica Show quoted text
________________________________________ From: Ed J via RT [bug-Inline-Java@rt.cpan.org] Sent: 21 November 2014 16:39 Cc: Jurica Stanojkovic; 754755@bugs.debian.org; jurica.stanojkovic@rt-rk.com; gregoa@debian.org Subject: [rt.cpan.org #98683] libinline-java-perl: FTBFS on mips: test suite issues <URL: https://rt.cpan.org/Ticket/Display.html?id=98683 > Please could you try the new 0.56 rather than stick with 0.53?

Message body is not shown because sender requested not to inline it.

CC: Jurica.Stanojkovic [...] imgtec.com, 754755 [...] bugs.debian.org, jurica.stanojkovic [...] rt-rk.com
Subject: Re: [rt.cpan.org #98683] libinline-java-perl: FTBFS on mips: test suite issues
Date: Wed, 26 Nov 2014 18:38:10 +0100
To: Ed J via RT <bug-Inline-Java [...] rt.cpan.org>
From: gregor herrmann <gregoa [...] debian.org>
On Fri, 21 Nov 2014 10:39:51 -0500, Ed J via RT wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=98683 > > > Please could you try the new 0.56 rather than stick with 0.53?
0.56 has been uploaded to Debian unstable. Build results will soon show up at https://buildd.debian.org/status/logs.php?pkg=libinline-java-perl (and http://buildd.debian-ports.org/status/logs.php?pkg=libinline-java-perl for other architectures) Cheers, gregor -- .''`. Homepage: http://info.comodo.priv.at/ - OpenPGP key 0xBB3A68018649AA06 : :' : Debian GNU/Linux user, admin, and developer - http://www.debian.org/ `. `' Member of VIBE!AT & SPI, fellow of the Free Software Foundation Europe `-
Download signature.asc
application/pgp-signature 949b

Message body not shown because it is not plain text.

RT-Send-CC: gregoa [...] debian.org
Show quoted text
> Tests are still failing in new version 0.56 during build. > I have used sbuild for package build. > Build log is attached.
Thanks for the log, I can see the failures, but I'm not seeing them on my machine. Could you tell me what Java version you're using? (and where to obtain it - I'm using very stale CentOS JVM and I think I need to update)
On Sat Nov 29 02:27:08 2014, ETJ wrote: Show quoted text
> Thanks for the log, I can see the failures, but I'm not seeing them on > my machine. Could you tell me what Java version you're using?
The last attempted (and failed) build log: https://buildd.debian.org/status/fetch.php?pkg=libinline-java-perl&arch=mips&ver=0.58%7Edfsg-1&stamp=1459786777 ... used openjdk-8-jre 8u77-b03-3 from Debian unstable.
Subject: Re: [rt.cpan.org #98683] libinline-java-perl: FTBFS on mips: test suite issues
Date: Tue, 2 Aug 2016 13:53:06 +0000
To: "754755 [...] bugs.debian.org" <754755 [...] bugs.debian.org>, "bug-Inline-Java [...] rt.cpan.org" <bug-Inline-Java [...] rt.cpan.org>
From: Daniel Knezevic <Daniel.Knezevic [...] imgtec.com>
Hi, Tests are still failing in version 0.58 during build. I have found out that the tests are failing when Inline::Java uses JNI extensions (PERL_INLINE_JAVA_JNI is set to 1), but the tests pass when Inline::Java run JVM in the default client/server mode (PERL_INLINE_JAVA_JNI is unset). --- debian/rules_orig 2016-08-02 12:16:34.206089692 +0000 +++ debian/rules 2016-08-02 12:16:46.476196564 +0000 @@ -49,9 +49,6 @@ export JAVA_HOME=/usr/lib/jvm/default-java -# Have testsuite use JNI -export PERL_INLINE_JAVA_JNI=1 - # Put aside upstream cruft during build DEB_UPSTREAM_CRUFT_MOVE = t/t13.txt It may be some mips/mipsel specific issue, because the build succeeds on mips64el. We are still investigating, any tip will be useful. Can we use Inline::Java without JNI extension for mips/mipsel? Regards, Daniel
CC: bug-inline-java [...] rt.cpan.org
Subject: Re: Bug#754755: [rt.cpan.org #98683] libinline-java-perl: FTBFS on mips: test suite issues
Date: Sat, 10 Sep 2016 22:46:21 +0200
To: Daniel Knezevic <Daniel.Knezevic [...] imgtec.com>, 754755 [...] bugs.debian.org
From: gregor herrmann <gregoa [...] debian.org>
On Tue, 02 Aug 2016 13:53:06 +0000, Daniel Knezevic wrote: Show quoted text
> Tests are still failing in version 0.58 during build. > > I have found out that the tests are failing when Inline::Java uses JNI extensions > (PERL_INLINE_JAVA_JNI is set to 1), but the tests pass when Inline::Java run JVM in > the default client/server mode (PERL_INLINE_JAVA_JNI is unset). > > --- debian/rules_orig 2016-08-02 12:16:34.206089692 +0000 > +++ debian/rules 2016-08-02 12:16:46.476196564 +0000 > @@ -49,9 +49,6 @@ > > export JAVA_HOME=/usr/lib/jvm/default-java > > -# Have testsuite use JNI > -export PERL_INLINE_JAVA_JNI=1 > - > # Put aside upstream cruft during build > DEB_UPSTREAM_CRUFT_MOVE = t/t13.txt > > It may be some mips/mipsel specific issue, because the build succeeds on mips64el. > We are still investigating, any tip will be useful. > > Can we use Inline::Java without JNI extension for mips/mipsel?
Thanks for your findings! I think the idea to drop PERL_INLINE_JAVA_JNI solves only half of the problem; it doesn't use the JNI extension during the tests but it still builds them. In order not to build them on architectures where they apparently don't work, we probably shouldn't build them in the first place. I've come up with the following patch now (committed in git but not yet uploaded in the hope of getting more eyeballs to look at it): #v+ --- a/debian/rules +++ b/debian/rules @@ -49,8 +49,15 @@ CDBS_DEPENDS_$(pkg) = $(deps) export JAVA_HOME=/usr/lib/jvm/default-java +DEB_HOST_ARCH = $(shell dpkg-architecture -qDEB_HOST_ARCH) +NO_JNI_ARCH = hppa hurd-i386 mips mipsel +ifeq (,$(filter $(DEB_HOST_ARCH), $(NO_JNI_ARCH))) # Have testsuite use JNI export PERL_INLINE_JAVA_JNI=1 +else +# Don't build JNI extension +DEB_MAKEMAKER_USER_FLAGS = BUILD_JNI=0 +endif # Put aside upstream cruft during build DEB_UPSTREAM_CRUFT_MOVE = t/t13.txt @@ -58,6 +65,7 @@ DEB_UPSTREAM_CRUFT_MOVE = t/t13.txt # Have testsuite use the C locale's decimal point DEB_MAKE_CHECK_TARGET += LC_NUMERIC=C +ifeq (,$(filter $(DEB_HOST_ARCH), $(NO_JNI_ARCH))) binary-post-install/$(pkg):: chrpath -d $(cdbs_curdestdir)$(perlpath)/auto/Inline/Java/JNI/JNI.so @@ -67,3 +75,4 @@ binary-post-install/$(pkg):: $(cdbs_curdestdir)$(perlpath)/Inline/Java/*.jar dh_link usr/share/$(pkg)/InlineJavaServer.jar $(perlpath)/Inline/Java/InlineJavaServer.jar \ usr/share/$(pkg)/InlineJavaUser.jar $(perlpath)/Inline/Java/InlineJavaUser.jar +endif #v- This seems to work for both cases; what's not so nice is that in the case of the NO_JNI_ARCH we get a hint from lintian: X: libinline-java-perl: package-contains-no-arch-dependent-files and indeed everything ends up in /usr/share/perl5 despite the package saying it's arch:any. Alternatives: - just remove PERL_INLINE_JAVA_JNI and ignore the fact that the JNI stuff might be broken on some architectures - don't build it on all architectures (and make the package arch:all) Cheers, gregor -- .''`. Homepage https://info.comodo.priv.at/ - OpenPGP key 0xBB3A68018649AA06 : :' : Debian GNU/Linux user, admin, and developer - https://www.debian.org/ `. `' Member of VIBE!AT & SPI, fellow of the Free Software Foundation Europe `- NP: JBO: Frauen
Download signature.asc
application/pgp-signature 931b

Message body not shown because it is not plain text.

Any of the above options look sensible to me. I'm taking a look at making PerlInterpreter et al all built by default, and fixing any resulting problems. Do you folks need anything else from me, or can we close this ticket?
I believe the issues are all resolved on this (the upstream) end, so I will close the ticket. If I am wrong, please reopen it!