• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

problem while build

 
Ranch Hand
Posts: 58
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
when i am building

it says

[war] Warning: selected war files include a WEB-INF/web.xml which will be ignored (please use webxml attribute to war task)



my web.xml is

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">

<web-app>
<!-- ========== Welcome File ============================== -->
<welcome-file-list>
<welcome-file>/login/login.jsp</welcome-file>
<welcome-file>/login.jsp</welcome-file>
</welcome-file-list>

<!-- ========== Servlet Definitions ============================== -->
<servlet>
<servlet-name>UIServlet</servlet-name>
<servlet-class>org.apache.struts.action.ActionServlet</servlet-class>
<init-param>
<param-name>config</param-name>
<param-value>/WEB-INF/struts-config.xml</param-value>
</init-param>
<init-param>
<param-name>debug</param-name>
<param-value>3</param-value>
</init-param>
<init-param>
<param-name>detail</param-name>
<param-value>3</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet>
<servlet-name>CewolfServlet</servlet-name>
<servlet-class>de.laures.cewolf.CewolfRenderer</servlet-class>
<init-param>
<param-name>storage</param-name>
<param-value>de.laures.cewolf.storage.TransientSessionStorage</param-value>
</init-param>
<init-param>
<param-name>overliburl</param-name>
<param-value>/etc/overlib.js</param-value>
</init-param>
<init-param>
<param-name>debug</param-name>
<param-value>true</param-value>
</init-param>
<load-on-startup>2</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>CewolfServlet</servlet-name>
<url-pattern>/cewolf/*</url-pattern>
</servlet-mapping>

<servlet-mapping>
<servlet-name>UIServlet</servlet-name>
<url-pattern>*.do</url-pattern>
</servlet-mapping>


<!-- ========== Error page definitions =========================== -->
<error-page>
<error-code>500</error-code>
<location>/login.do</location>
</error-page>

<!-- ========== Tag Library definitions =========================== -->
<taglib>
<taglib-uri>/WEB-INF/struts-html.tld</taglib-uri>
<taglib-location>/tld/struts-html.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/struts-logic.tld</taglib-uri>
<taglib-location>/tld/struts-logic.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/struts-bean.tld</taglib-uri>
<taglib-location>/tld/struts-bean.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/struts-tiles.tld</taglib-uri>
<taglib-location>/tld/struts-tiles.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/mcube-security.tld</taglib-uri>
<taglib-location>/tld/mcube-security.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/mcube-logic.tld</taglib-uri>
<taglib-location>/tld/mcube-logic.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/c.tld</taglib-uri>
<taglib-location>/tld/c.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/template.tld</taglib-uri>
<taglib-location>/tld/template.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/struts-layout.tld</taglib-uri>
<taglib-location>/tld/struts-layout.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/ajaxtags.tld</taglib-uri>
<taglib-location>/tld/ajaxtags.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/displaytag-11.tld</taglib-uri>
<taglib-location>/tld/displaytag-11.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/displaytag-12.tld</taglib-uri>
<taglib-location>/tld/displaytag-12.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/mcube-chart.tld</taglib-uri>
<taglib-location>/tld/mcube-chart.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/cewolf.tld</taglib-uri>
<taglib-location>/tld/cewolf.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/mcube-tag1.0.tld</taglib-uri>
<taglib-location>/tld/mcube-tag1.0.tld</taglib-location>
</taglib>

</web-app>


and my build.xml is

<?xml version="1.0" encoding="UTF-8"?>

<!-- *********************************************************************** -->
<!-- * * -->
<!-- * Veloz MCube master build script. It includes all other component * -->
<!-- * build scripts to provide a single consolidated view of all build * -->
<!-- * tasks for the MCube platform. * -->
<!-- * * -->
<!-- * Author: $author$ * -->
<!-- * Version: $revision$ * -->
<!-- * * -->
<!-- *********************************************************************** -->
<project name="Veloz MCube Implementation" default="impl.jar" basedir="..">

<!-- =================================================================== -->
<!-- Import the component build files -->
<!-- =================================================================== -->
<import file="build-common.xml" optional="false"/>
<import file="build-package.xml" optional="true"/>
<import file="build-install.xml" optional="true"/>
<import file="build-release.xml" optional="true"/>
<import file="build-deploy.xml" optional="true"/>
<import file="build-portal.xml" optional="true"/>

<!-- ******************************************************************* -->
<!-- * * -->
<!-- * High Level Tasks * -->
<!-- * * -->
<!-- * ***************************************************************** -->

<!-- =================================================================== -->
<!-- Builds all the components -->
<!-- =================================================================== -->
<target name="impl.compile" depends="common.init, common.compile" description="Incremental compilations of all components"/>
<target name="impl.recompile" depends="common.clean, common.init, common.compile" description="Fresh compilations of all components"/>

<!-- =================================================================== -->
<!-- Component archive of all implementation classes -->
<!-- =================================================================== -->
<target name="impl.jar" depends="impl.compile,common.init.dist" description="Creates the archive of all implementation classes">

<jar destfile="${dist.binaries}/${impl.jar}">

<!-- Class files needed for the implementation -->
<fileset dir="${classes}" casesensitive="false">
<include name="**/*.*"/>
</fileset>

<!-- Manifest entry -->
<manifest>
<attribute name="Built-By" value="${user.name}"/>
<attribute name="Implementation-Title" value="Veloz MCube Implementation"/>
<attribute name="Implementation-Version" value="${TODAY}"/>
<attribute name="Implementation-Vendor" value="Veloz Global Solutions Ltd."/>
</manifest>
</jar>

</target>

</project>



please help!!!



Regards,
Abhishek.
 
author
Posts: 14112
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Have you tried using the webxml attribute, like the warning suggests?
 
Saloon Keeper
Posts: 28319
210
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This is a pet peeve of mine. The Ant task doesn't like it when you include the web.xml in the WAR input, it wants the web.xml to be added separately.

Until someone on the Ant team has mercy on us and makes it optional, you have 2 choices:

1. Realize it's just a warning and ignore it

2. Use the JAR task instead of WAR. A WAR is just a JAR with the web file layout anyway. WAR is just a convenient extension of it that will fetch in an external web.xml. And, of course, document the fast that the JAR is really a WAR.
 
Ilja Preuss
author
Posts: 14112
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
3. Use a fileset that excludes the file.
 
He got surgery to replace his foot with a pig. He said it was because of this tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic