This is similar to bug 34034. The org.apache.jasper.compiler.TldLocationsCache class parses the web.xml (again!). The processWebDotXml method of this class should be modified to create an InputSource over the InputStream, and set the systemId of the InputSource to the URI of the web.xml document, similar to the change made to org.apache.jaspser.compiler.JspConfig for bug 34034.
This is now fixed in the SVN trunk, and will appear in 5.5.13.
*** Bug 37143 has been marked as a duplicate of this bug. ***