What JAR files are needed for Eclipse to use JSTL so it ultimately works on GAE/J?

I had the same issue and I simply put the prefix = "c" at the end of the taglib definition

before:

<%@ taglib  prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>

after:

<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>

And all warnings disappear from Eclipse.


You only need to specify this dependency in your Maven POM:

<dependency>
    <groupId>jstl</groupId>
    <artifactId>jstl</artifactId>
    <version>1.2</version>
</dependency>

In my code, this provided everything I needed for the following JSP taglib to work:

<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>

Ensure that your web.xml root declaration complies at least Servlet 2.4.

<web-app
    xmlns="http://java.sun.com/xml/ns/j2ee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
    version="2.4">

    <!-- Config here. -->

</web-app>

Or if your servletcontainer supports it, prefer 2.5:

<web-app 
    xmlns="http://java.sun.com/xml/ns/javaee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
    version="2.5">

    <!-- Config here. -->

</web-app>

O if it supports the latest version3.0

<web-app 
    xmlns="http://java.sun.com/xml/ns/javaee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"
    version="3.0">

    <!-- Config here. -->

</web-app>

Otherwise everything will fall back to least supported modus and taglibs may break like that.

Also ensure that you don't have loose tld files wandering around in the classpath (the /WEB-INF/lib folder, among others), they will collide with the ones in JAR files. Oh, also ensure that you didn't manually define the tlds in web.xml, keep it clean.