This week's book giveaway is in the Agile and Other Processes forum.
We're giving away four copies of Darcy DeClute's Scrum Master Certification Guide: The Definitive Resource for Passing the CSM and PSM Exams and have Darcy DeClute on-line!
See this thread for details.
  • 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
  • Devaka Cooray
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Jeanne Boyarsky
  • Tim Cooke
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Tim Moores
  • Mikalai Zaikin
  • Carey Brown
Bartenders:

${env.JBOSS_HOME}\client not found.

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
build.xml file i am using. I set JAVA_HOME, ANT_HOME, JBOSS_HOME, classpath, path. Jboss server is started. when i execute ant command on prompt, all files get compiled but it gives the error:${env.JBOSS_HOME}\client not found. How can solve this problem. I am using jboss4.0.2

build.xml
--------
<?xml version="1.0"?>

<!-- ======================================================================= -->
<!-- JBoss build file -->
<!-- ======================================================================= -->

<project name="JBoss" default="ejbjar" basedir=".">

<property environment="env"/>
<property name="src.dir" value="${basedir}/src/main"/>
<property name="src.resources" value="${basedir}/src/resources"/>
<property name="jboss.home" value="${env.JBOSS_HOME}"/>
<property name="build.dir" value="${basedir}/build"/>
<property name="build.classes.dir" value="${build.dir}/classes"/>

<!-- Build classpath -->
<path id="classpath">
<fileset dir="${jboss.home}/client">
<include name="**/*.jar"/>
</fileset>
<pathelement location="${build.classes.dir}"/>
<!-- So that we can get jndi.properties for InitialContext -->
<pathelement location="${basedir}/jndi"/>
</path>

<property name="build.classpath" refid="classpath"/>

<!-- =================================================================== -->
<!-- Prepares the build directory -->
<!-- =================================================================== -->
<target name="prepare" >
<mkdir dir="${build.dir}"/>
<mkdir dir="${build.classes.dir}"/>
</target>

<!-- =================================================================== -->
<!-- Compiles the source code -->
<!-- =================================================================== -->
<target name="compile" depends="prepare">
<javac srcdir="${src.dir}"
destdir="${build.classes.dir}"
debug="on"
deprecation="on"
optimize="off"
includes="**">
<classpath refid="classpath"/>
</javac>
</target>

<target name="ejbjar" depends="compile">
<jar jarfile="build/titan.jar">
<fileset dir="${build.classes.dir}">
<include name="com/titan/cabin/*.class"/>
</fileset>
<fileset dir="${src.resources}/">
<include name="**/*.xml"/>
</fileset>
</jar>
<copy file="build/titan.jar" todir="${jboss.home}/server/default/deploy"/>
</target>

<target name="run.client_41a" depends="ejbjar">
<java classname="com.titan.clients.Client_1" fork="yes" dir=".">
<classpath refid="classpath"/>
</java>
</target>

<target name="run.client_41b" depends="ejbjar">
<java classname="com.titan.clients.Client_2" fork="yes" dir=".">
<classpath refid="classpath"/>
</java>
</target>

<!-- =================================================================== -->
<!-- Cleans up generated stuff -->
<!-- =================================================================== -->
<target name="clean.db">
<delete dir="${jboss.home}/server/default/data/hypersonic"/>
</target>

<target name="clean">
<delete dir="${build.dir}"/>
<delete file="${jboss.home}/server/default/deploy/titan.jar"/>
</target>


</project>
 
amit fulambarkar
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by amit fulambarkar:
build.xml file i am using. I set JAVA_HOME, ANT_HOME, JBOSS_HOME, classpath, path. Jboss server is started. when i execute ant command on prompt, all files get compiled but it gives the error:${env.JBOSS_HOME}\client not found. How can solve this problem. I am using jboss4.0.2

build.xml
--------
<?xml version="1.0"?>

<!-- ======================================================================= -->
<!-- JBoss build file -->
<!-- ======================================================================= -->

<project name="JBoss" default="ejbjar" basedir=".">

<property environment="env"/>
<property name="src.dir" value="${basedir}/src/main"/>
<property name="src.resources" value="${basedir}/src/resources"/>
<property name="jboss.home" value="${env.JBOSS_HOME}"/>
<property name="build.dir" value="${basedir}/build"/>
<property name="build.classes.dir" value="${build.dir}/classes"/>

<!-- Build classpath -->
<path id="classpath">
<fileset dir="${jboss.home}/client">
<include name="**/*.jar"/>
</fileset>
<pathelement location="${build.classes.dir}"/>
<!-- So that we can get jndi.properties for InitialContext -->
<pathelement location="${basedir}/jndi"/>
</path>

<property name="build.classpath" refid="classpath"/>

<!-- =================================================================== -->
<!-- Prepares the build directory -->
<!-- =================================================================== -->
<target name="prepare" >
<mkdir dir="${build.dir}"/>
<mkdir dir="${build.classes.dir}"/>
</target>

<!-- =================================================================== -->
<!-- Compiles the source code -->
<!-- =================================================================== -->
<target name="compile" depends="prepare">
<javac srcdir="${src.dir}"
destdir="${build.classes.dir}"
debug="on"
deprecation="on"
optimize="off"
includes="**">
<classpath refid="classpath"/>
</javac>
</target>

<target name="ejbjar" depends="compile">
<jar jarfile="build/titan.jar">
<fileset dir="${build.classes.dir}">
<include name="com/titan/cabin/*.class"/>
</fileset>
<fileset dir="${src.resources}/">
<include name="**/*.xml"/>
</fileset>
</jar>
<copy file="build/titan.jar" todir="${jboss.home}/server/default/deploy"/>
</target>

<target name="run.client_41a" depends="ejbjar">
<java classname="com.titan.clients.Client_1" fork="yes" dir=".">
<classpath refid="classpath"/>
</java>
</target>

<target name="run.client_41b" depends="ejbjar">
<java classname="com.titan.clients.Client_2" fork="yes" dir=".">
<classpath refid="classpath"/>
</java>
</target>

<!-- =================================================================== -->
<!-- Cleans up generated stuff -->
<!-- =================================================================== -->
<target name="clean.db">
<delete dir="${jboss.home}/server/default/data/hypersonic"/>
</target>

<target name="clean">
<delete dir="${build.dir}"/>
<delete file="${jboss.home}/server/default/deploy/titan.jar"/>
</target>


</project>




OK i solved the problem . JBOSS_HOME was not set correctly.
 
All that thinking. Doesn't it hurt? What do you think about this tiny ad?
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic