Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 503090 - www-servers/tomcat-7.0.52 USE=doc - .../work/apache-tomcat-7.0.52-src/build.xml:1467: The java.7.home property must be set for javadoc build
Summary: www-servers/tomcat-7.0.52 USE=doc - .../work/apache-tomcat-7.0.52-src/build.x...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Java (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Java team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-03-01 03:46 UTC by Alex Brandt (RETIRED)
Modified: 2015-03-09 04:54 UTC (History)
6 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
environment (environment,161.26 KB, text/plain)
2014-03-01 03:47 UTC, Alex Brandt (RETIRED)
Details
build.log (build.log,41.17 KB, text/plain)
2014-03-01 03:47 UTC, Alex Brandt (RETIRED)
Details
emerge -pqv '=www-servers/tomcat-7.0.52::gentoo' (file_503090.txt,87 bytes, text/plain)
2014-03-01 03:48 UTC, Alex Brandt (RETIRED)
Details
emerge --info '=www-servers/tomcat-7.0.52::gentoo' (file_503090.txt,5.90 KB, text/plain)
2014-03-01 03:49 UTC, Alex Brandt (RETIRED)
Details
patched ebuild (ebuild.patch,1018 bytes, patch)
2014-12-01 12:50 UTC, Horst Prote
Details | Diff
corrected patch (ebuild.patch,1020 bytes, patch)
2014-12-01 14:26 UTC, Horst Prote
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alex Brandt (RETIRED) gentoo-dev 2014-03-01 03:46:31 UTC
When building tomcat-7.0.52 as part of normal updates the build fails when USE=doc is set on the build.

Reproducible: Always

Steps to Reproduce:
1. USE=doc emerge -v1 \=www-servers/tomcat-7.0.52
2. build failure
3.
Actual Results:  
Failed Build

Expected Results:  
Successful Build

Without the doc flag set the build is successful but not with the doc flag.
Comment 1 Alex Brandt (RETIRED) gentoo-dev 2014-03-01 03:47:07 UTC
Created attachment 371470 [details]
environment
Comment 2 Alex Brandt (RETIRED) gentoo-dev 2014-03-01 03:47:39 UTC
Created attachment 371472 [details]
build.log
Comment 3 Alex Brandt (RETIRED) gentoo-dev 2014-03-01 03:48:44 UTC
Created attachment 371474 [details]
emerge -pqv '=www-servers/tomcat-7.0.52::gentoo'
Comment 4 Alex Brandt (RETIRED) gentoo-dev 2014-03-01 03:49:06 UTC
Created attachment 371476 [details]
emerge --info '=www-servers/tomcat-7.0.52::gentoo'
Comment 6 Johann Schmitz (ercpe) (RETIRED) gentoo-dev 2014-11-02 10:25:14 UTC
Fixed in tomcat-7.0.56.
Comment 7 sf 2014-11-14 10:32:45 UTC
Re comment #6: How is it fixed? I get

BUILD FAILED
/gentoo/tmp/portage/www-servers/tomcat-7.0.56/work/apache-tomcat-7.0.56-src/build.xml:1499: The java.7.home property must be set for javadoc build
Comment 8 Horst Prote 2014-12-01 12:50:26 UTC
Created attachment 390704 [details, diff]
patched ebuild

(In reply to Johann Schmitz (ercpe) from comment #6)
> Fixed in tomcat-7.0.56.

Not really. As you write in the ChangeLog
  Use new websocket use flag (requires java7) to build websocket as it won't
  work on java < 7.
you fixed the problem if one activates the new websocket USE flag. And even in that fix I think the dependencies should be
	websockets? ( >=virtual/jre-1.7 )
	!websockets? ( >=virtual/jre-1.6 )
instead of
	websockets? ( >=virtual/jre-1.6 )
	!websockets? ( >=virtual/jre-1.6 )
in order to pull in the required java7.

The error of Alex needs a similar fix for the doc USE flag since the build.xml requires java7 for the doc target, too (see my attached ebuild patch).
Comment 9 Horst Prote 2014-12-01 14:26:11 UTC
Created attachment 390720 [details, diff]
corrected patch

Arrg, sorry: buggy patch. This one works.
Comment 10 Johann Schmitz (ercpe) (RETIRED) gentoo-dev 2014-12-14 11:55:25 UTC
Sorry for the late reply. Of course, the 7.0.56 ebuild has wrong *DEPEND.

I have bumped it to tomcat-7.0.57.

+  14 Dec 2014; Johann Schmitz <ercpe@gentoo.org>
+  +files/tomcat-7.0.57-build.xml.patch, +tomcat-7.0.57.ebuild:
+  Version bump to 7.0.57 with fix for bug #503090  * JDK/JRE 1.7 is required for
+  +websockets. * JDK 1.7 restriction for javadocs removed from build.xml   This
+  will open up CVE-2013-1571, but this is true for any other package in the tree
+  build with USE="doc" and an old JDK.


Horst, thanks for your patch. Unfortunatly, it wouldn't work as intended: Once the java.7.home property is set, the build.xml script tries to build java-7 code which failes with jdk 1.6.

I've decided to remove the jdk 1.7 restriction from the build.xml even it opens up CVE-2013-1571 (http://markmail.org/message/344mf45rhjfttuim?q=CVE-2013-1571%2C+VU%23225657+list:org%2Eapache%2Etomcat%2Edev/).
Comment 11 Pavel Goran 2015-03-09 04:54:04 UTC
This bug is back in 7.0.59. Apparently because files/tomcat-7.0.59-build.xml.patch doesn't include the same java.7.home fix found in files/tomcat-7.0.57-build.xml.patch.