You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openjpa.apache.org by dw...@apache.org on 2009/05/15 17:38:22 UTC

svn commit: r775195 - in /openjpa/branches/1.3.x: openjpa-examples/src/main/java/README.txt openjpa-examples/src/main/java/build.xml openjpa-integration/examples/pom.xml

Author: dwoods
Date: Fri May 15 15:38:21 2009
New Revision: 775195

URL: http://svn.apache.org/viewvc?rev=775195&view=rev
Log:
OPENJPA-1088 Build updates for openjpa-examples and openjpa-integration/examples

Added:
    openjpa/branches/1.3.x/openjpa-examples/src/main/java/README.txt   (with props)
Modified:
    openjpa/branches/1.3.x/openjpa-examples/src/main/java/build.xml
    openjpa/branches/1.3.x/openjpa-integration/examples/pom.xml

Added: openjpa/branches/1.3.x/openjpa-examples/src/main/java/README.txt
URL: http://svn.apache.org/viewvc/openjpa/branches/1.3.x/openjpa-examples/src/main/java/README.txt?rev=775195&view=auto
==============================================================================
--- openjpa/branches/1.3.x/openjpa-examples/src/main/java/README.txt (added)
+++ openjpa/branches/1.3.x/openjpa-examples/src/main/java/README.txt Fri May 15 15:38:21 2009
@@ -0,0 +1,24 @@
+Apache OpenJPA Examples
+Copyright © 2005-2009, The Apache Software Foundation.
+Licensed under ASL 2.0 - http://www.apache.org/licenses/LICENSE-2.0
+--------------------------------------------------------------------------------
+
+Prerequisites:
+  The following must be on the user's path:
+         - Java SE 5
+         - Apache ANT v1.6.5 or later
+
+Building and Running Individual Examples:
+  1) Open a command prompt to the directory where this README is located
+  2) Change to the subdirectory of the example to build and run, like:
+         cd hellojpa
+  3) Run ANT
+         ant
+     For the hellojpa exmaple, at the end of the build you should see the text:
+         "Hello Persistence!"
+
+Building and Running All Examples:
+  1) Open a command prompt to the directory where this README is located
+  2) Run ANT with the "all" project
+         ant all
+

Propchange: openjpa/branches/1.3.x/openjpa-examples/src/main/java/README.txt
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: openjpa/branches/1.3.x/openjpa-examples/src/main/java/build.xml
URL: http://svn.apache.org/viewvc/openjpa/branches/1.3.x/openjpa-examples/src/main/java/build.xml?rev=775195&r1=775194&r2=775195&view=diff
==============================================================================
--- openjpa/branches/1.3.x/openjpa-examples/src/main/java/build.xml (original)
+++ openjpa/branches/1.3.x/openjpa-examples/src/main/java/build.xml Fri May 15 15:38:21 2009
@@ -32,21 +32,36 @@
 
     <target name="usagewarning">
         <fail>
-Please traverse to a sub-directory and run "ant" from there.
+Please traverse to a sub-directory, like hellojpa, and run "ant" from there.
         </fail>
     </target>
 
+    <target name="all">
+        <exec dir="${basedir}/hellojpa" executable="ant" />
+        <exec dir="${basedir}/relations" executable="ant" />
+        <exec dir="${basedir}/reversemapping" executable="ant" />
+    </target>
+
     <path id="classpath"
         description="The classpath to use for compiling and running">
         <pathelement path="${parent}"/>
+        <!-- we could include the individual jars as below, but lets use the
+             openjpa-all.jar with Derby instead
         <fileset dir="${root}">
             <include name="**/*.jar"/>
+            <exclude name="openjpa-all-*.jar"/>
+        </fileset>
+        -->
+        <fileset dir="${root}">
+            <include name="openjpa-all-*.jar"/>
+            <include name="lib/derby*.jar"/>
         </fileset>
     </path>
 
     <path id="javaagent">
         <fileset dir="${root}">
             <include name="openjpa-*.jar"/>
+            <exclude name="openjpa-all-*.jar"/>
         </fileset>
     </path>
     <pathconvert property="javaagent" refid="javaagent"/>

Modified: openjpa/branches/1.3.x/openjpa-integration/examples/pom.xml
URL: http://svn.apache.org/viewvc/openjpa/branches/1.3.x/openjpa-integration/examples/pom.xml?rev=775195&r1=775194&r2=775195&view=diff
==============================================================================
--- openjpa/branches/1.3.x/openjpa-integration/examples/pom.xml (original)
+++ openjpa/branches/1.3.x/openjpa-integration/examples/pom.xml Fri May 15 15:38:21 2009
@@ -58,13 +58,14 @@
                         <echo>Running OpenJPA Examples</echo>
 
                         <property name="examples.base" value="${basedir}/target/examples" />
+                        <delete dir="${examples.base}" quiet="true"/>
                         <mkdir dir="${examples.base}" />
 
-                        <unzip overwrite="false" dest="${examples.base}" src="../../target/site/downloads/apache-openjpa-${pom.version}-binary.zip" />
+                        <unzip overwrite="false" dest="${examples.base}" src="../../openjpa-project/target/site/downloads/apache-openjpa-${pom.version}-binary.zip" />
 
                         <path id="assembly.classpath"> 
                             <fileset dir="${examples.base}">
-                                <include name="**/*.jar" />
+                                <include name="**/openjpa-all-${pom.version}.jar" />
                             </fileset>
                         </path>
                         <available classname="org.apache.openjpa.conf.OpenJPAVersion" classpathref="assembly.classpath" property="unzip.success" />
@@ -92,7 +93,7 @@
     <dependencies>
         <dependency>
             <groupId>org.apache.openjpa</groupId>
-            <artifactId>openjpa</artifactId>
+            <artifactId>openjpa-all</artifactId>
             <version>${pom.version}</version>
         </dependency>
     </dependencies>