Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 357437

Summary: tomcat-6.0.32-r1 with USE doc --> no docs
Product: Gentoo Linux Reporter: Thomas Kohler <g2t>
Component: [OLD] ServerAssignee: Java team <java>
Status: RESOLVED FIXED    
Severity: minor    
Priority: High    
Version: unspecified   
Hardware: AMD64   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 322979    
Attachments: Fix for ebuild copying the wrong doc directory

Description Thomas Kohler 2011-03-04 21:08:29 UTC
/docs/ will be not opened

Reproducible: Always

Steps to Reproduce:
1.compile tomcat with doc (add "www-servers/tomcat doc" to /etc/portage/package.use)
2. open http://localhost:8080/docs/

Actual Results:  
HTTP Status 404 - /docs/
type Status report
message /docs/
description The requested resource (/docs/) is not available.
Apache Tomcat/6.0.32

Expected Results:  
docs site will be open

Look to "http://localhost:8080/manager/html" docs is a running application.
Comment 1 William L. Thomson Jr. 2011-03-07 21:11:27 UTC
Do you have the examples use flag enabled? I think the docs webapp is some what dependent on that. However it should be available on its own, surely if the manager is showing it as a running web app.

I must say I really don't care much about tomcat being able to serve up its own documentation that is readily available via the net or else where. My interest in maintaining Tomcat is for those who run it in a production server environment. Which there is no need to serve up local documentation. Changing the importance to minor as a result. Tons of tomcat bugs that need to be addressed before ones like this are addressed.
Comment 2 Thomas Kohler 2011-03-08 04:39:16 UTC
I have also enabled the examples use flag. But also no examples are available (but shown as running application).

I'm a newbie with tomcat and this test was only made for a quick tour for my own.
Next step should be make "icescrum" running with tomcat (at the moment showing as NOT running application). This can be discussed on another place (but where?).

Please give me some hints to looking for (log files, error messages). I'm sure I will be find out the problematic point.

Yes I have seen the bug list for tomcat during search for my problem and I understand your point of view.

Please, can you tell me (possible via e-mail) which development environment do you use for tomcat?
Comment 3 Thomas Kohler 2011-03-19 17:26:09 UTC
I have solved the issue for the examples directory:
/var/lib/tomcat-6/webapps/examples/WEB-INF/lib/jstl.jar was included as symbolic link to /usr/share/jakarta-jstl/lib/jstl.jar

this caused an error:
Failed to access resource /WEB-INF/lib/jstl.jar

I have deleted the link and copied the jstl.jar in the directory, same with standard.jar.

After restart the tomcat server the error is gone and the "examples" are accessible.

But "docs" not working.
Comment 4 Thomas Kohler 2011-03-19 18:50:08 UTC
It seems the sites with an index.html are working f.e. "docs/appdev/sample/" or "docs/api" are shown. But the .xml files are not available.
Comment 5 Matt O 2011-07-30 04:53:33 UTC
The issue is that the docs/ directory that gets copied is the one with the XML files before the Ant scripts do their XSLT work on them, transforming them into .html files.

Changing one line to copy the correct directory fixes the problem.


--- tomcat-6.0.32-r1.ebuild	2011-07-29 23:47:45.899988500 -0500
+++ tomcat-6.0.32-r1-doc-fix.ebuild	2011-07-29 23:36:20.635894953 -0500
@@ -137,7 +137,7 @@
 	cp -pR host-manager "${D}"/usr/share/${TOMCAT_NAME}/webapps || die
 	cp -pR manager "${D}"/usr/share/${TOMCAT_NAME}/webapps || die
 	if use doc; then
-		cp -pR docs "${D}"/usr/share/${TOMCAT_NAME}/webapps || die
+		cp -pR "${S}"/output/build/webapps/docs "${D}"/usr/share/${TOMCAT_NAME}/webapps || die
 	fi
 	if use examples; then
 		cd "${S}"/webapps/examples/WEB-INF/lib
Comment 6 Matt O 2011-07-30 04:54:18 UTC
Created attachment 281531 [details, diff]
Fix for ebuild copying the wrong doc directory
Comment 7 Miroslav Ć ulc gentoo-dev 2011-12-24 19:44:22 UTC
fixed in 6.0.35 which will be stabilized soon because it also fixes CVE-2011-3190.