red1.org Forum Index red1.org
Nihili est - in vita priore ego imperator romanus fui
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

unable to build project

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    red1.org Forum Index -> Strictly Technical
View previous topic :: View next topic  
Author Message
chris



Joined: 05 Oct 2005
Posts: 15

PostPosted: Mon Oct 24, 2005 11:21 pm    Post subject: unable to build project Reply with quote

Hi All,
I have imported the compiere source into Eclipse. I am getting the following errors:

1. The project was not built due to "Could not delete: /Compiere251/bin/org.".
Fix the problem, then try refreshing this project and building it since it
may be inconsistent.


2. taskdef class xdoclet.ejb.EjbDocletTask cannot be found

How to resolve this error?

Thanks in advance.
chris
Back to top
View user's profile Send private message
new_soft



Joined: 21 Dec 2004
Posts: 28
Location: TUNISIA

PostPosted: Tue Oct 25, 2005 6:40 am    Post subject: Reply with quote

Hi Chris,

1- Try to start eclipse with option -clear ( i.e for eg : C:\eclipse.exe -clear ).

2- You must add xdoclet.jar to the ANT classpath ( Window->preferences->Ant->Runtime->Classpath and under "Ant Home Entries" try to add your xdoclet.jar )

Hope that help you.

Khaled.N
_________________
Best Regards,

Khaled Najeh.
Back to top
View user's profile Send private message Send e-mail AIM Address
chris



Joined: 05 Oct 2005
Posts: 15

PostPosted: Wed Oct 26, 2005 1:03 pm    Post subject: Reply with quote

Hi New soft,
Thank you very much for your response. I have implemented the things you said to do. But now I am getting this new error:


xdoclet-generate:
[echo] XDoclet=D:\XDOCLET\xdoclet-1.2.3\
[echo] UpToDate=true

BUILD FAILED
D:\Compiere\compiere-all\serverRoot\build.xml:115: java.lang.NoClassDefFoundError: org/apache/log4j/Category

Please help me.

Regards,
chris
Back to top
View user's profile Send private message
new_soft



Joined: 21 Dec 2004
Posts: 28
Location: TUNISIA

PostPosted: Wed Oct 26, 2005 3:37 pm    Post subject: Reply with quote

Hi Chris,
As you added the xdoclet.jar to ANT classpath, try to find the log4j.jar and add it also. ( Samething like xdoclet ).

Hope that help,
If any error, post it again.

Khaled.N
_________________
Best Regards,

Khaled Najeh.
Back to top
View user's profile Send private message Send e-mail AIM Address
chris



Joined: 05 Oct 2005
Posts: 15

PostPosted: Wed Oct 26, 2005 4:04 pm    Post subject: Reply with quote

Hi New_soft
I have added the log4j file. I am getting this error now as source files and packages have been not specified.

[echo] =========== Build Server Root
[echo] (D:\XDOCLET\xdoclet-1.2.3\ ../jboss compiere
xdoclet-generate:
[echo] XDoclet=D:\XDOCLET\xdoclet-1.2.3\
[echo] UpToDate=true

BUILD FAILED
D:\Compiere\compiere-all\utils_dev\build.xml:27: The following error occurred while executing this line:
D:\Compiere\compiere-all\serverRoot\build.xml:115: No source files and no packages have been specified.

Help me in resolving this error.
Back to top
View user's profile Send private message
new_soft



Joined: 21 Dec 2004
Posts: 28
Location: TUNISIA

PostPosted: Wed Oct 26, 2005 7:12 pm    Post subject: Reply with quote

Hi Chris,
Since i dont know what version you are using now, i cant tell you what the problem exatly. But what i want to say is that you can use the version 252e of compiere and try to compile and deploy the serverRoot using the build.xml found under serverRoot directory.
Also you will find the error "taskdef class xdoclet.ejb.EjbDocletTask cannot be found". In this cas you must comment this line :
<property name="xdoclet.home" value="${env.XDOCLET_HOME}" />
and replace it by this one :
<property name="xdoclet.home" value="../tools" />

Of corse, you must add the xdoclet.jar in your ANT classpath at first.

This is work for me nice,

Hope this help you.

Come back if necessary of corse Smile

Khaled.N
_________________
Best Regards,

Khaled Najeh.
Back to top
View user's profile Send private message Send e-mail AIM Address
chris



Joined: 05 Oct 2005
Posts: 15

PostPosted: Wed Oct 26, 2005 7:52 pm    Post subject: Reply with quote

Hi New Soft,
Thanks for your reply. I am using 2.5.1C version of compiere. I have changed the tag

<property name="xdoclet.home" value="${env.XDOCLET_HOME}" />
to
<property name="xdoclet.home" value="../tools" />

But still the problem exists.


xdoclet-generate:
[echo] XDoclet=../tools
[echo] UpToDate=true

BUILD FAILED
D:\Compiere\compiere-all\serverRoot\build.xml:116: No source files and no packages have been specified.

Thanks in advance,
Chris
Back to top
View user's profile Send private message
new_soft



Joined: 21 Dec 2004
Posts: 28
Location: TUNISIA

PostPosted: Wed Oct 26, 2005 8:16 pm    Post subject: Reply with quote

Hi,
Can u post the build file please?
_________________
Best Regards,

Khaled Najeh.
Back to top
View user's profile Send private message Send e-mail AIM Address
chris



Joined: 05 Oct 2005
Posts: 15

PostPosted: Wed Oct 26, 2005 10:36 pm    Post subject: Reply with quote

Hi New Soft
This is my build.xml file:


<?xml version="1.0"?>
<!-- ============================================= -->
<!-- Compiere Server Root -->
<!-- ============================================= -->
<!-- $Header: /cvsroot/compiere/serverRoot/build.xml,v 1.13 2004/02/18 05:40:35 jjanke Exp $-->

<project name="compiereRoot" default="main" basedir=".">

<property environment="env"/>
<property name="jboss.home" value="../jboss" />
<property name="jboss.configuration" value="compiere" />

<property name="jboss.lib" value="${jboss.home}/lib" />
<property name="jboss.client" value="${jboss.home}/client" />
<property name="servlet-lib.path" value="../tools/lib/servlet.jar" />

<!-- <property name="xdoclet.home" value="${env.XDOCLET_HOME}" /> -->
<property name="xdoclet.home" value="../tools" />
<property name="xdoclet.force" value="false" />
<property name="ejb.version" value="2.0" />
<property name="jboss.version" value="3.0" />
<property name="type.mapping" value="Oracle9" />
<property name="datasource.name" value="java:/OracleDS" />

<property name="src.dir" value="${basedir}/src"/>
<property name="src.main.dir" value="${src.dir}/main"/>
<property name="src.client.dir" value="${src.main.dir}/client"/>
<property name="src.ejb.dir" value="${src.main.dir}/ejb"/>
<property name="src.servlet.dir" value="${src.main.dir}/servlet"/>
<property name="src.server.dir" value="${src.main.dir}/server"/>
<property name="src.resources.dir" value="${src.dir}/resources"/>
<property name="src.web.dir" value="${src.dir}/web"/>
<property name="src.etc.dir" value="${src.dir}/etc"/>
<property name="src.ear.dir" value="${src.dir}/ear"/>

<property name="build.dir" value="${basedir}/build"/>
<property name="build.tmp.dir" value="${build.dir}/tmp"/>
<property name="build.deploy.dir" value="${build.dir}/deploy"/>
<property name="build.classes.dir" value="${build.dir}/classes"/>
<property name="build.war.dir" value="${build.dir}/war"/>
<property name="build.client.dir" value="${build.dir}/client"/>
<property name="build.ear.dir" value="${build.dir}/ear"/>
<property name="build.sar.dir" value="${build.dir}/sar"/>
<property name="build.bin.dir" value="${build.dir}/bin"/>
<property name="build.javadocs.dir" value="${build.dir}/docs/api"/>

<property name="interfaces.dir" value="../interfaces"/>
<property name="src.interfaces.dir" value="../interfaces/src"/>
<property name="build.interfaces.dir" value="../interfaces/classes"/>


<target name="init">
<echo message="=========== Build Server Root"/>
<echo message=" (${xdoclet.home} ${jboss.home} ${jboss.configuration}"/>

<uptodate property="interfaces.uptodate"
targetfile="${interfaces.dir}/Interfaces.jar">
<srcfiles dir="${src.ejb.dir}" includes="**/*.java"/>
<srcfiles dir="${src.interfaces.dir}" includes="**/*.java"/>
</uptodate>

<mkdir dir="${build.ear.dir}"/>
</target>


<path id="xdoclet.path">
<pathelement location="${xdoclet.home}/lib/ant.jar" />
<pathelement location="${xdoclet.home}/lib/xdoclet.jar" />
<pathelement location="${xdoclet.home}/lib/log4j.jar" />
</path>

<path id="base.path">
<path refid="xdoclet.path"/>
<pathelement location="../lib/CClient.jar" />
<pathelement location="../lib/CTools.jar" />
<pathelement location="../lib/CServer.jar" />

<pathelement location="${jboss.client}/jboss-j2ee.jar" />
<pathelement location="${jboss.client}/jnp-client.jar" />
<pathelement location="${jboss.client}/jbossmq-client.jar" />
<pathelement location="${jboss.client}/jbosssx-client.jar" />
<pathelement location="${jboss.client}/concurrent.jar" />
<pathelement location="${jboss.client}/jaas.jar" />

<pathelement location="${jboss.lib}/jboss-jmx.jar" />
<pathelement location="${jboss.lib}/jboss-system.jar" />

<pathelement location="${jboss.home}/server/${jboss.configuration}/lib/jbosssx.jar" />
<pathelement location="${jboss.home}/server/${jboss.configuration}/lib/mail.jar" />
<pathelement location="${jboss.home}/server/${jboss.configuration}/lib/javax.servlet.jar" />

<pathelement location="${build.classes.dir}" />
</path>


<!-- =================================================================== -->
<!-- Generates the necessary EJB classes and deployment descriptors -->
<!-- =================================================================== -->
<target name="xdoclet-generate" depends="init">
<echo message="XDoclet=${xdoclet.home}"/>
<echo message="UpToDate=${interfaces.uptodate}"/>

<taskdef
name="ejbdoclet"
classname="xdoclet.ejb.EjbDocletTask">
<classpath refid="xdoclet.path"/>
</taskdef>

<ejbdoclet
sourcepath="${src.ejb.dir}"
destdir="${src.interfaces.dir}"
classpathref="base.path"
excludedtags="@version,@author"
ejbspec="${ejb.version}"
mergedir="${src.resources.dir}/xdoclet"
force="${xdoclet.force}">
<fileset dir="${src.ejb.dir}">
<include name="**/*Bean.java"/>
</fileset>
<packageSubstitution packages="session,entity" substituteWith="interfaces"/>
<dataobject/>
<remoteinterface/>
<homeinterface/>
<entitypk/>
<entitybmp/>
<entitycmp/>
<deploymentdescriptor destdir="${build.dir}/META-INF"/>
<!-- AS 4/29/02 Do not validate XML files because JBoss 3.0 message driven will
report an wrong error because it uses the wrong jboss.dtd -->
<jboss version="${jboss.version}"
xmlencoding="UTF-8"
typemapping="${type.mapping}"
datasource="${datasource.name}"
destdir="${build.dir}/META-INF"
validateXml="false"/>
</ejbdoclet>
</target>


<!-- =========================================== -->
<!-- Compiles the source code -->
<!-- =========================================== -->
<target name="compile" depends="xdoclet-generate">
<mkdir dir="${build.classes.dir}"/>

<!-- Compile EJB -->
<javac
destdir="${build.classes.dir}"
debug="on"
deprecation="off"
optimize="on"
classpathref="base.path">
<src path="${src.ejb.dir}"/>
<src path="${src.interfaces.dir}"/>
</javac>

<!-- Compile Client -->
<javac
srcdir="${src.client.dir}"
destdir="${build.classes.dir}"
debug="on"
deprecation="off"
optimize="on"
includes="**/*.java"
classpathref="base.path">
</javac>
</target>


<!-- =========================================== -->
<!-- Creates the jar archives -->
<!-- =========================================== -->
<target name="jar" depends="compile">
<mkdir dir="${build.deploy.dir}"/>
<mkdir dir="${build.client.dir}"/>
<mkdir dir="${build.bin.dir}"/>

<!-- Jar EJB -->
<jar
jarfile="${build.deploy.dir}/compiereRoot.jar">
<fileset
dir="${build.classes.dir}"
includes="org/compiere/entity/**,org/compiere/session/**,org/compiere/message/**,org/compiere/interfaces/**">
</fileset>
<fileset
dir="${build.dir}"
includes="META-INF/**">
</fileset>
</jar>

<!-- Jar Client -->
<jar
jarfile="${build.client.dir}/compiereRoot-client.jar">
<fileset
dir="${build.classes.dir}"
includes="org/compiere/interfaces/**,org/compiere/client/**">
</fileset>
</jar>
</target>


<!-- =========================================== -->
<!-- Compiles the WEB source code -->
<!-- =========================================== -->
<target name="compile-web" depends="compile" if="servlet-lib.path">
<mkdir dir="${build.war.dir}"/>
<path id="web.path">
<path refid="base.path"/>
<pathelement location="${servlet-lib.path}"/>
</path>

<javac
destdir="${build.war.dir}"
debug="on"
deprecation="off"
optimize="on"
classpathref="web.path">
<src path="${src.servlet.dir}"/>
</javac>
</target>


<!-- =========================================== -->
<!-- Creates the war archives -->
<!-- =========================================== -->
<target name="war" depends="compile-web" if="servlet-lib.path">
<mkdir dir="${build.ear.dir}"/>
<war
warfile="${build.deploy.dir}/compiereRootBase.war"
webxml="${src.web.dir}/WEB-INF/web.xml">
<!-- copy from web -->
<fileset dir="${src.web.dir}" excludes="**/web.xml,**/lib/**,**/classes/**"/>
<!-- WEB-INF/classes -->
<classes dir="${build.war.dir}"/>
<classes dir="${build.classes.dir}" includes="org/compiere/interfaces/**"/>
<!-- WEB-INF/lib -->
<lib dir="${src.web.dir}/WEB-INF/lib"/>
</war>
</target>


<!-- =========================================== -->
<!-- Creates the sar archives -->
<!-- =========================================== -->
<target name="sar" depends="compile">
<mkdir dir="${build.sar.dir}"/>
<!-- Compile JMX Service -->
<javac
srcdir="${src.server.dir}"
destdir="${build.sar.dir}"
debug="on"
deprecation="on"
optimize="on"
includes="**/*.java"
classpathref="base.path">
</javac>

<mkdir dir="${build.sar.dir}/META-INF"/>
<copy file="${src.etc.dir}/jboss-service.xml" todir="${build.sar.dir}/META-INF"/>

<jar
jarfile="${build.deploy.dir}/compiereRoot.sar"
basedir="${build.sar.dir}"/>

<!-- Copy MBeans to interfaces -->
<copy todir="${src.interfaces.dir}">
<fileset dir="${src.server.dir}" includes="**/*MBean.java"/>
</copy>

<!-- Compile interfaces -->
<mkdir dir="${build.interfaces.dir}"/>
<javac
srcdir="${src.interfaces.dir}"
destdir="${build.interfaces.dir}"
debug="off"
deprecation="on"
optimize="on"
classpathref="base.path">
</javac>
<!-- Jar Interfaces -->
<jar
destfile="${interfaces.dir}/Interfaces.jar"
basedir="${build.interfaces.dir}" />
</target>


<!-- =========================================== -->
<!-- Deploy Server Files -->
<!-- =========================================== -->
<target name="deploy-server" depends="jar,war,sar">
<copy todir="../lib">
<fileset dir="${build.deploy.dir}"/>
</copy>
<copy file="${src.ear.dir}/compiereRoot/application.xml"
tofile="../lib/compiereRoot.xml"/>
</target>


<!-- =========================================== -->
<!-- Creates the client binary -->
<!-- =========================================== -->
<target name="create-client" depends="jar">
<!-- Convert the given paths to Windows -->
<pathconvert targetos="windows" property="jboss.home.on.windows" >
<path>
<pathelement location="${jboss.home}" />
</path>
</pathconvert>
<pathconvert targetos="windows" property="java.home.on.windows" >
<path>
<pathelement location="${java.home}" />
</path>
</pathconvert>
<!-- Convert the given paths to Unix -->
<pathconvert targetos="unix" property="jboss.home.on.unix" >
<path>
<pathelement location="${jboss.home}" />
</path>
</pathconvert>
<pathconvert targetos="unix" property="java.home.on.unix" >
<path>
<pathelement location="${java.home}" />
</path>
</pathconvert>

<filter token="jboss.home" value="${jboss.home.on.windows}"/>
<filter token="java.home" value="${java.home.on.windows}"/>
<copy todir="${build.bin.dir}" filtering="yes">
<fileset dir="${src.etc.dir}/bin" includes="*client.bat"/>
</copy>
<copy file="${src.etc.dir}/bin/lcp.bat" todir="${build.bin.dir}"/>
<filter token="jboss.home" value="${jboss.home.on.unix}"/>
<filter token="java.home" value="${java.home.on.unix}"/>
<copy todir="${build.bin.dir}" filtering="yes">
<fileset dir="${src.etc.dir}/bin" includes="*client.sh"/>
</copy>
<copy file="${src.etc.dir}/jndi.properties" todir="${build.bin.dir}"/>
</target>

<!-- =========================================== -->
<!-- Creates the binary structure -->
<!-- =========================================== -->
<target name="main" depends="deploy-server,create-client">
</target>



<!-- =========================================== -->
<!-- Cleans up the current build -->
<!-- =========================================== -->
<target name="clean">
<delete dir="${build.dir}" failonerror="false"/>
<delete>
<fileset dir="${src.interfaces.dir}" includes="**/*.java"/>
</delete>
</target>

</project>
Back to top
View user's profile Send private message
new_soft



Joined: 21 Dec 2004
Posts: 28
Location: TUNISIA

PostPosted: Thu Oct 27, 2005 5:26 pm    Post subject: Reply with quote

Chris,
i just have download the source code of compiere version 251c by entering this cvs command :
cvs -z3 -d:pserver:anonymous@cvs.sf.net:/cvsroot/compiere checkout -r release_251c compiere-all

After this i added the two files .classpath and .project in the compiere-all directory.
After this i have imported this in eclipse with File-->Import->Existing project in Workspace : and choose your recent downloaded directory compiere-all ( version 251c).

Warning : You must rename the source folder under package client from "Src" to "src" : it must be in lower letter.

After that i opened build.xml under the serverRoot and lauched the init, then deploy-server and that's all.

This is the log file generated :

Buildfile: D:\projects\Dev-Compiere\comp251c\compiere-all\serverRoot\build.xml
init:
[echo] =========== Build Server Root
[echo] (../tools ../jboss compiere
xdoclet-generate:
[echo] XDoclet=../tools
[echo] UpToDate=true
[ejbdoclet] Generating Javadoc
[ejbdoclet] Javadoc execution
[ejbdoclet] Loading source file D:\projects\Dev-Compiere\comp251\compiere-all\serverRoot\src\main\ejb\org\compiere\session\ServerBean.java...
[ejbdoclet] Loading source file D:\projects\Dev-Compiere\comp251\compiere-all\serverRoot\src\main\ejb\org\compiere\session\StatusBean.java...
[ejbdoclet] Constructing Javadoc information...
[ejbdoclet] Running <homeInterface/>
[ejbdoclet] Running <remoteInterface/>
[ejbdoclet] Running <entitypk/>
[ejbdoclet] Running <dataobject/>
[ejbdoclet] Running <entitybmp/>
[ejbdoclet] Running <entitycmp/>
[ejbdoclet] Running <deploymentDescriptor/>
[ejbdoclet] Running <jboss/>
compile:
jar:
compile-web:
war:
sar:
deploy-server:
BUILD SUCCESSFUL
Total time: 18 seconds


To be continued Wink
_________________
Best Regards,

Khaled Najeh.
Back to top
View user's profile Send private message Send e-mail AIM Address
new_soft



Joined: 21 Dec 2004
Posts: 28
Location: TUNISIA

PostPosted: Thu Oct 27, 2005 5:33 pm    Post subject: Reply with quote

Of corse try to change this :

FROM :

<property name="xdoclet.home" value="${env.XDOCLET_HOME}" />


TO :
<!--property name="xdoclet.home" value="${env.XDOCLET_HOME}" /-->
<property name="xdoclet.home" value="../tools" />

_________________
Best Regards,

Khaled Najeh.
Back to top
View user's profile Send private message Send e-mail AIM Address
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    red1.org Forum Index -> Strictly Technical All times are GMT + 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group