I have the anttask for creating the databasestructure in my build.xml file.
It looks like this:
<target name="createdatabase" depends="setenv, compile">
<taskdef name="schemaexport"
classname="net.sf.hibernate.tool.hbm2ddl.SchemaExportTask"
classpathref="classpath"/>
<schemaexport
properties="webapps/gridsphere/WEB-INF/persistence/hibernate.properties"
quiet="no"
text="no"
drop="no"
delimiter=";"
output="schema-export.sql">
<fileset dir="webapps/gridsphere/WEB-INF/persistence/">
<include name="**/*.hbm.xml"/>
</fileset>
</schemaexport>
</target>
My Hibernatemapping files are in 'webapps/gridsphere/WEB-INF/persistence' and my classes
in build/classes.
This anttask does not find my classes and therefore it does not generate the schema.
If I change my classpath before I call 'ant createdatabase' to:
setenv CLASSPATH ${CLASSPATH}:build/classes:lib/ext/mm.mysql-2.0.14-bin.jar
then it works. Is there any way to set the correct classpath in the anttask so that it finds my classes?
Is there a way to include
<classpath refid="classpath"/>
in the Task to tell schemaexport to tell where to look for the classes?
Oliver
------------------------------------------------------- This SF.net email is sponsored by Dice.com. Did you know that Dice has over 25,000 tech jobs available today? From careers in IT to Engineering to Tech Sales, Dice has tech jobs from the best hiring companies. http://www.dice.com/index.epl?rel_code=104 _______________________________________________ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel
