You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@etch.apache.org by fi...@apache.org on 2012/01/12 17:10:54 UTC
svn commit: r1230611 - in /incubator/etch/trunk: ./ binding-c/runtime/
binding-c/runtime/c/ examples/chat/ examples/helloworld/
Author: fitzner
Date: Thu Jan 12 16:10:54 2012
New Revision: 1230611
URL: http://svn.apache.org/viewvc?rev=1230611&view=rev
Log:
ETCH-204
correct some line endings
Modified:
incubator/etch/trunk/binding-c/runtime/build.xml
incubator/etch/trunk/binding-c/runtime/c/README.txt
incubator/etch/trunk/build.dependencies
incubator/etch/trunk/examples/chat/build.xml
incubator/etch/trunk/examples/chat/dist-build.xml
incubator/etch/trunk/examples/helloworld/CMakeLists.txt
incubator/etch/trunk/examples/helloworld/README.txt
incubator/etch/trunk/examples/helloworld/build.xml
incubator/etch/trunk/examples/helloworld/dist-build.xml
Modified: incubator/etch/trunk/binding-c/runtime/build.xml
URL: http://svn.apache.org/viewvc/incubator/etch/trunk/binding-c/runtime/build.xml?rev=1230611&r1=1230610&r2=1230611&view=diff
==============================================================================
--- incubator/etch/trunk/binding-c/runtime/build.xml (original)
+++ incubator/etch/trunk/binding-c/runtime/build.xml Thu Jan 12 16:10:54 2012
@@ -1,110 +1,110 @@
-<?xml version="1.0" encoding="utf-8" ?>
-<!--
- * Licensed to the Apache Software Foundation (ASF) under one *
- * or more contributor license agreements. See the NOTICE file *
- * distributed with this work for additional information *
- * regarding copyright ownership. The ASF licenses this file *
- * to you under the Apache License, Version 2.0 (the *
- * "License"); you may not use this file except in compliance *
- * with the License. You may obtain a copy of the License at *
- * *
- * http://www.apache.org/licenses/LICENSE-2.0 *
- * *
- * Unless required by applicable law or agreed to in writing, *
- * software distributed under the License is distributed on an *
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY *
- * KIND, either express or implied. See the License for the *
- * specific language governing permissions and limitations *
- * under the License. *
--->
-<project name="etch-c-runtime" basedir="." default="help">
- <description>Etch-to-C runtime binding implementation</description>
- <property name="Etch.basedir" location="${basedir}/../.." />
- <import file="${Etch.basedir}/build-support/etch.includes.xml" />
-
- <!-- Static properties of the sub-project -->
- <property name="proj" location="${Etch.basedir}/binding-c/runtime/c" />
- <property name="target" location="${proj}/target" />
- <property name="testResultsDirectory" location="${target}/test-results" />
-
- <!-- INIT TARGET -->
- <!-- Modify this target to define project specific properties that can only be set at runtime -->
- <target name="do-init" >
- <mkdir dir="${target}" />
- <mkdir dir="${testResultsDirectory}" />
- </target>
-
- <!-- CLEAN TARGET -->
- <target name="do-clean">
- <delete dir="${target}" />
- </target>
-
- <!-- BUILD TARGET -->
- <target name="do-build-info" unless="USE.cmake">
- <echo message="**********************************" />
- <echo message="binding-c build will not be done." />
- <echo message="**********************************" />
- </target>
-
- <target name="do-build-generate-sources" if="USE.cmake">
- <mkdir dir="${Etch.dist}/binding-c" />
- <!-- package up etch-java-runtime src -->
- <zip destfile="${Etch.dist}/binding-c/${etch-c-runtime-src.zip}">
- <fileset dir="${proj}">
- <exclude name="target/" />
- <exclude name="doc/" />
- <exclude name="**/.svn" />
- </fileset>
- </zip>
- </target>
-
- <target name="do-build-main" if="USE.cmake">
- <cmake srcdir="${basedir}/c" bindir="${basedir}/c/target" buildtype="Debug" >
- <variable name="ETCH_EXTERNAL_DEPENDS" type="PATH" value="${env.ETCH_EXTERNAL_DEPENDS}" />
- </cmake>
- </target>
-
- <target name="do-build" depends="do-build-info,do-build-generate-sources,do-build-main" if="USE.cmake">
-
- <mkdir dir="${Etch.dist}/binding-c/bin" />
- <mkdir dir="${Etch.dist}/binding-c/include" />
- <mkdir dir="${Etch.dist}/binding-c/lib" />
-
- <!-- copy etch library to dist folder -->
- <copy todir="${Etch.dist}/binding-c/include">
- <fileset dir="${proj}/include">
- <exclude name="**/.svn" />
- </fileset>
- </copy>
-
- <copy todir="${Etch.dist}/binding-c/lib" flatten="true">
- <fileset dir="${target}/src/main">
- <include name="debug/etch.lib" />
- <include name="debug/etch.pdb" />
- <include name="Debug/etch.lib" />
- <include name="Debug/etch.pdb" />
- <include name="libetch.a" />
- </fileset>
- </copy>
-
- <!-- copy apr library to dist folder -->
- <copy todir="${Etch.dist}/binding-c/extern/apr">
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ * Licensed to the Apache Software Foundation (ASF) under one *
+ * or more contributor license agreements. See the NOTICE file *
+ * distributed with this work for additional information *
+ * regarding copyright ownership. The ASF licenses this file *
+ * to you under the Apache License, Version 2.0 (the *
+ * "License"); you may not use this file except in compliance *
+ * with the License. You may obtain a copy of the License at *
+ * *
+ * http://www.apache.org/licenses/LICENSE-2.0 *
+ * *
+ * Unless required by applicable law or agreed to in writing, *
+ * software distributed under the License is distributed on an *
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY *
+ * KIND, either express or implied. See the License for the *
+ * specific language governing permissions and limitations *
+ * under the License. *
+-->
+<project name="etch-c-runtime" basedir="." default="help">
+ <description>Etch-to-C runtime binding implementation</description>
+ <property name="Etch.basedir" location="${basedir}/../.." />
+ <import file="${Etch.basedir}/build-support/etch.includes.xml" />
+
+ <!-- Static properties of the sub-project -->
+ <property name="proj" location="${Etch.basedir}/binding-c/runtime/c" />
+ <property name="target" location="${proj}/target" />
+ <property name="testResultsDirectory" location="${target}/test-results" />
+
+ <!-- INIT TARGET -->
+ <!-- Modify this target to define project specific properties that can only be set at runtime -->
+ <target name="do-init" >
+ <mkdir dir="${target}" />
+ <mkdir dir="${testResultsDirectory}" />
+ </target>
+
+ <!-- CLEAN TARGET -->
+ <target name="do-clean">
+ <delete dir="${target}" />
+ </target>
+
+ <!-- BUILD TARGET -->
+ <target name="do-build-info" unless="USE.cmake">
+ <echo message="**********************************" />
+ <echo message="binding-c build will not be done." />
+ <echo message="**********************************" />
+ </target>
+
+ <target name="do-build-generate-sources" if="USE.cmake">
+ <mkdir dir="${Etch.dist}/binding-c" />
+ <!-- package up etch-java-runtime src -->
+ <zip destfile="${Etch.dist}/binding-c/${etch-c-runtime-src.zip}">
+ <fileset dir="${proj}">
+ <exclude name="target/" />
+ <exclude name="doc/" />
+ <exclude name="**/.svn" />
+ </fileset>
+ </zip>
+ </target>
+
+ <target name="do-build-main" if="USE.cmake">
+ <cmake srcdir="${basedir}/c" bindir="${basedir}/c/target" buildtype="Debug" >
+ <variable name="ETCH_EXTERNAL_DEPENDS" type="PATH" value="${env.ETCH_EXTERNAL_DEPENDS}" />
+ </cmake>
+ </target>
+
+ <target name="do-build" depends="do-build-info,do-build-generate-sources,do-build-main" if="USE.cmake">
+
+ <mkdir dir="${Etch.dist}/binding-c/bin" />
+ <mkdir dir="${Etch.dist}/binding-c/include" />
+ <mkdir dir="${Etch.dist}/binding-c/lib" />
+
+ <!-- copy etch library to dist folder -->
+ <copy todir="${Etch.dist}/binding-c/include">
+ <fileset dir="${proj}/include">
+ <exclude name="**/.svn" />
+ </fileset>
+ </copy>
+
+ <copy todir="${Etch.dist}/binding-c/lib" flatten="true">
+ <fileset dir="${target}/src/main">
+ <include name="debug/etch.lib" />
+ <include name="debug/etch.pdb" />
+ <include name="Debug/etch.lib" />
+ <include name="Debug/etch.pdb" />
+ <include name="libetch.a" />
+ </fileset>
+ </copy>
+
+ <!-- copy apr library to dist folder -->
+ <copy todir="${Etch.dist}/binding-c/extern/apr">
<fileset dir="${env.ETCH_EXTERNAL_DEPENDS}/apr/1.4.5">
- </fileset>
- </copy>
- </target>
-
- <!-- TEST TARGET -->
- <target name="do-test">
- </target>
-
- <!-- POSTBUILD TARGET -->
- <target name="do-postbuild">
- </target>
-
- <target name="do-publish" if="build.tests.fail">
- <!-- Set flag file if any tests failed -->
- <touch file="${Etch.runtime.tests.fail}"/>
- </target>
-
-</project>
+ </fileset>
+ </copy>
+ </target>
+
+ <!-- TEST TARGET -->
+ <target name="do-test">
+ </target>
+
+ <!-- POSTBUILD TARGET -->
+ <target name="do-postbuild">
+ </target>
+
+ <target name="do-publish" if="build.tests.fail">
+ <!-- Set flag file if any tests failed -->
+ <touch file="${Etch.runtime.tests.fail}"/>
+ </target>
+
+</project>
Modified: incubator/etch/trunk/binding-c/runtime/c/README.txt
URL: http://svn.apache.org/viewvc/incubator/etch/trunk/binding-c/runtime/c/README.txt?rev=1230611&r1=1230610&r2=1230611&view=diff
==============================================================================
--- incubator/etch/trunk/binding-c/runtime/c/README.txt (original)
+++ incubator/etch/trunk/binding-c/runtime/c/README.txt Thu Jan 12 16:10:54 2012
@@ -1,30 +1,30 @@
-==================================================
-Introduction to binding-c
-==================================================
-To build the binding-c components, the following dependencies
-are needed.
+==================================================
+Introduction to binding-c
+==================================================
+To build the binding-c components, the following dependencies
+are needed.
- Apache APR Source Version 1.4.5
http://apr.apache.org/download.cgi
- Apache APR Util Sources Version 1.3.12
http://apr.apache.org/download.cgi
-- Apache APR Iconv Sources Version 1.2.1
+- Apache APR Iconv Sources Version 1.2.1
http://apr.apache.org/download.cgi
-- CUnit 2.1
- http://sourceforge.net/projects/cunit/
+- CUnit 2.1
+ http://sourceforge.net/projects/cunit/
- CMake 2.8 or higher
http://www.cmake.org/
-
-==================================================
-Build for windows
-==================================================
-The following instructions were tested using MS Visual Studio 2005 SP1
-on Windows 7. It should work with newer Visual Studio versions too, but
-was not tested.
-
-You should have the following folder and file structure inside your external
-etch directory "ETCH_EXTERNAL_DEPENDS".
-
-APR and APR-ICONV libraries
+
+==================================================
+Build for windows
+==================================================
+The following instructions were tested using MS Visual Studio 2005 SP1
+on Windows 7. It should work with newer Visual Studio versions too, but
+was not tested.
+
+You should have the following folder and file structure inside your external
+etch directory "ETCH_EXTERNAL_DEPENDS".
+
+APR and APR-ICONV libraries
- <ETCH_EXTERNAL_DEPENDS>/apr/1.4.5/bin
- <ETCH_EXTERNAL_DEPENDS>/apr/1.4.5/bin/libapr-1.dll
- <ETCH_EXTERNAL_DEPENDS>/apr/1.4.5/bin/libapr-1.pdb
@@ -38,71 +38,71 @@ APR and APR-ICONV libraries
- <ETCH_EXTERNAL_DEPENDS>/apr/1.4.5/lib
- <ETCH_EXTERNAL_DEPENDS>/apr/1.4.5/lib/libapr-1.lib
- <ETCH_EXTERNAL_DEPENDS>/apr/1.4.5/lib/libapriconv-1.lib
-
-APR and APR-ICONV can be build via MS Visual Studio GUI. After that, all needed
-artifacts have to be copied to above folder and file structure. If you do so, please
-follow the instructions on http://apr.apache.org/compiling_win32.html. The installation
-to <ETCH_EXTERNAL_DEPENDS> have to be done by hand. Nedded projects are: apr,
-apriconv, libapr, libapriconv, libapriconv_ccs_modules and libapriconv_ces_modules.
-
-A much more easy way is to use our apr-install.bat script (../trunk/scrips/). To run the
-script a cygwin installation with wget, unzip, rm, mv is required. Please check also if
-cygwin/bin is in your environment path. For build apr libraries, follow the next steps:
-1. create a new folder beside your <ETCH_EXTERNAL_DEPENDS> etc. c:/projects/etch/external_sources
-2. edit apr-install.bat script and set INSTALL_PREFIX to your <ETCH_EXTERNAL_DEPENDS> folder and
- VC_HOME to your MS Visual Studio VS folder. You can also set this variables as environment
- variables.
-3. enter your created folder (see 1.) and execute the following commands:
- - apr-install.bat download (downloading apr sources)
- - apr-install.bat convert (converting VS 6.0. dsw files to newer sln format)
- - apr-install.bat build (build all needed libraries)
- - apr-install.bat install (install all needed files to the <ETCH_EXTERNAL_DEPENDS> folder)
-
-CUnit
-- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/bin
-- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/include
-- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/include/*.h (header files)
-- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/lib
-- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/lib/libcunit.lib
-- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/lib/vc80_libcunit.pdb
-- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/res
-- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/res/*dtd + *.xsl (shared files, nedded to show cunit results)
-
-Open the CUNIT solution in VS ([external_source]/cunit/VS8/CUnit.sln) and build
-libcunit project. After build, copy nedded artificts to <ETCH_EXTERNAL_DEPENDS>
-see above.
-
-Etch
-For building Etch you need cmake on your system to generate the build templates
-for MS Visual Studio, Make. Use the cmake-gui or command line version to configure
-and generate the project artifacts. In both cases you have to set the source and
-binaries folders via CMake.
-- source to ../trunk/binding-c/runtime/c
-- binary to ../trunk/binding-c/runtime/c/target
-To tell CMake how to find all the depending libraries, you have to set a CMake
-variable called ETCH_EXTERNAL_DEPENDS, that points to your <ETCH_EXTERNAL_DEPENDS>
-path.
-
-After CMake has generated all project artifacts you can build the binding-c runtime
-etc. via. MS Visual Studio (../trunk/binding-c/runtime/c/target/etch-c.sln). The Etch
-libary and unit tests can be found under ../trunk/binding-c/runtime/c/target/src/main
-and ../trunk/binding-c/runtime/c/target/src/test.
-
-Please note that tests need libapr-1.dll and libapriconv-1.dll either in your path environment
-variable or in case of MS Visual Studio under the ..\binding-c\runtime\c\target\src\test\ folder.
+
+APR and APR-ICONV can be build via MS Visual Studio GUI. After that, all needed
+artifacts have to be copied to above folder and file structure. If you do so, please
+follow the instructions on http://apr.apache.org/compiling_win32.html. The installation
+to <ETCH_EXTERNAL_DEPENDS> have to be done by hand. Nedded projects are: apr,
+apriconv, libapr, libapriconv, libapriconv_ccs_modules and libapriconv_ces_modules.
+
+A much more easy way is to use our apr-install.bat script (../trunk/scrips/). To run the
+script a cygwin installation with wget, unzip, rm, mv is required. Please check also if
+cygwin/bin is in your environment path. For build apr libraries, follow the next steps:
+1. create a new folder beside your <ETCH_EXTERNAL_DEPENDS> etc. c:/projects/etch/external_sources
+2. edit apr-install.bat script and set INSTALL_PREFIX to your <ETCH_EXTERNAL_DEPENDS> folder and
+ VC_HOME to your MS Visual Studio VS folder. You can also set this variables as environment
+ variables.
+3. enter your created folder (see 1.) and execute the following commands:
+ - apr-install.bat download (downloading apr sources)
+ - apr-install.bat convert (converting VS 6.0. dsw files to newer sln format)
+ - apr-install.bat build (build all needed libraries)
+ - apr-install.bat install (install all needed files to the <ETCH_EXTERNAL_DEPENDS> folder)
+
+CUnit
+- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/bin
+- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/include
+- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/include/*.h (header files)
+- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/lib
+- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/lib/libcunit.lib
+- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/lib/vc80_libcunit.pdb
+- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/res
+- <ETCH_EXTERNAL_DEPENDS>/cunit/2.1/res/*dtd + *.xsl (shared files, nedded to show cunit results)
+
+Open the CUNIT solution in VS ([external_source]/cunit/VS8/CUnit.sln) and build
+libcunit project. After build, copy nedded artificts to <ETCH_EXTERNAL_DEPENDS>
+see above.
+
+Etch
+For building Etch you need cmake on your system to generate the build templates
+for MS Visual Studio, Make. Use the cmake-gui or command line version to configure
+and generate the project artifacts. In both cases you have to set the source and
+binaries folders via CMake.
+- source to ../trunk/binding-c/runtime/c
+- binary to ../trunk/binding-c/runtime/c/target
+To tell CMake how to find all the depending libraries, you have to set a CMake
+variable called ETCH_EXTERNAL_DEPENDS, that points to your <ETCH_EXTERNAL_DEPENDS>
+path.
+
+After CMake has generated all project artifacts you can build the binding-c runtime
+etc. via. MS Visual Studio (../trunk/binding-c/runtime/c/target/etch-c.sln). The Etch
+libary and unit tests can be found under ../trunk/binding-c/runtime/c/target/src/main
+and ../trunk/binding-c/runtime/c/target/src/test.
+
+Please note that tests need libapr-1.dll and libapriconv-1.dll either in your path environment
+variable or in case of MS Visual Studio under the ..\binding-c\runtime\c\target\src\test\ folder.
Additionally, you have to set APR_ICONV_PATH to <ETCH_EXTERNAL_DEPENDS>\apr\1.4.5\iconv\ to make
-character conversion run.
-
-==================================================
-Build for linux
-==================================================
-The following instructions were tested using gcc 4.3.x on Ubuntu Linux 10. It should work
-with other Linux distributions as well.
-
-You should have the following folder and file structure inside your external
-etch directory "ETCH_EXTERNAL_DEPENDS".
-
-APR and APR-ICONV libraries
+character conversion run.
+
+==================================================
+Build for linux
+==================================================
+The following instructions were tested using gcc 4.3.x on Ubuntu Linux 10. It should work
+with other Linux distributions as well.
+
+You should have the following folder and file structure inside your external
+etch directory "ETCH_EXTERNAL_DEPENDS".
+
+APR and APR-ICONV libraries
- <ETCH_EXTERNAL_DEPENDS>/apr/1.4.5/bin
- <ETCH_EXTERNAL_DEPENDS>/apr/1.4.5/include
- <ETCH_EXTERNAL_DEPENDS>/apr/1.4.5/include/apr-1
@@ -111,37 +111,37 @@ APR and APR-ICONV libraries
- <ETCH_EXTERNAL_DEPENDS>/apr/1.4.5/lib/libapr-1.so
- <ETCH_EXTERNAL_DEPENDS>/apr/1.4.5/lib/libapriconv-1.so
- <ETCH_EXTERNAL_DEPENDS>/apr/1.4.5/lib/iconv/*.so (coding tables)
-
-APR and APR-ICONV can be build via "configure" and make. Please set correct install
+
+APR and APR-ICONV can be build via "configure" and make. Please set correct install
location to configure script configure --prefix=$INSTALL_PREFIX/apr/1.4.5/ for apr
and configure --prefix=$INSTALL_PREFIX/apr/1.4.5/ --with-apr=$INSTALL_PREFIX/apr/1.4.5/
-for apr-iconv.
-
-A much more easy way to build apr is to use our apr-install.sh script (). For build the apr libraries,
-follow the next steps:
+for apr-iconv.
+
+A much more easy way to build apr is to use our apr-install.sh script (). For build the apr libraries,
+follow the next steps:
1. create a new folder beside your <ETCH_EXTERNAL_DEPENDS> e.g. home/user/projects/etch/external_sources
-2. edit apr-install.sh script and set INSTALL_PREFIX to your <ETCH_EXTERNAL_DEPENDS> folde. You can also
- set this variables as environment variable.
+2. edit apr-install.sh script and set INSTALL_PREFIX to your <ETCH_EXTERNAL_DEPENDS> folde. You can also
+ set this variables as environment variable.
3. enter to build folder (e.g., ../etch/external_sources, see 1.) and execute the following
- commands:
- - apr-install.sh (downloading apr sources, build apr libraries, install libraries)
-
-The CUnit framework can be install via the packet installer.
-- sudo apt-get install libcunit1
-- sudo apt-get install libcunit1-dev
-
-Etch
-For building Etch you need cmake on your system to generate the build templates
-for Make. Use the cmake-gui or command line version to configure and generate the
-project artifacts. In both cases you have to set the source and binaries folders
-via CMake.
-- source to ../trunk/binding-c/runtime/c
-- binary to ../trunk/binding-c/runtime/c/target
-To tell CMake how to find all the depending libraries, you have to set a CMake
-variable called ETCH_EXTERNAL_DEPENDS, that points to your <ETCH_EXTERNAL_DEPENDS>
-path.
-
-After CMake has generated all project artifacts you can build the binding-c runtime
-etc. via. Make (../trunk/binding-c/runtime/c/target/Makefile). The Etch libary and
-unit tests can be found under ../trunk/binding-c/runtime/c/target/src/main and
-../trunk/binding-c/runtime/c/target/src/test.
+ commands:
+ - apr-install.sh (downloading apr sources, build apr libraries, install libraries)
+
+The CUnit framework can be install via the packet installer.
+- sudo apt-get install libcunit1
+- sudo apt-get install libcunit1-dev
+
+Etch
+For building Etch you need cmake on your system to generate the build templates
+for Make. Use the cmake-gui or command line version to configure and generate the
+project artifacts. In both cases you have to set the source and binaries folders
+via CMake.
+- source to ../trunk/binding-c/runtime/c
+- binary to ../trunk/binding-c/runtime/c/target
+To tell CMake how to find all the depending libraries, you have to set a CMake
+variable called ETCH_EXTERNAL_DEPENDS, that points to your <ETCH_EXTERNAL_DEPENDS>
+path.
+
+After CMake has generated all project artifacts you can build the binding-c runtime
+etc. via. Make (../trunk/binding-c/runtime/c/target/Makefile). The Etch libary and
+unit tests can be found under ../trunk/binding-c/runtime/c/target/src/main and
+../trunk/binding-c/runtime/c/target/src/test.
Modified: incubator/etch/trunk/build.dependencies
URL: http://svn.apache.org/viewvc/incubator/etch/trunk/build.dependencies?rev=1230611&r1=1230610&r2=1230611&view=diff
==============================================================================
--- incubator/etch/trunk/build.dependencies (original)
+++ incubator/etch/trunk/build.dependencies Thu Jan 12 16:10:54 2012
@@ -1,50 +1,50 @@
-# Licensed to the Apache Software Foundation (ASF) under one *
-# or more contributor license agreements. See the NOTICE file *
-# distributed with this work for additional information *
-# regarding copyright ownership. The ASF licenses this file *
-# to you under the Apache License, Version 2.0 (the *
-# "License"); you may not use this file except in compliance *
-# with the License. You may obtain a copy of the License at *
-# *
-# http://www.apache.org/licenses/LICENSE-2.0 *
-# *
-# Unless required by applicable law or agreed to in writing, *
-# software distributed under the License is distributed on an *
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY *
-# KIND, either express or implied. See the License for the *
-# specific language governing permissions and limitations *
-# under the License. *
-
-##
-## Core Dependencies .. these must be set
-##
-
+# Licensed to the Apache Software Foundation (ASF) under one *
+# or more contributor license agreements. See the NOTICE file *
+# distributed with this work for additional information *
+# regarding copyright ownership. The ASF licenses this file *
+# to you under the Apache License, Version 2.0 (the *
+# "License"); you may not use this file except in compliance *
+# with the License. You may obtain a copy of the License at *
+# *
+# http://www.apache.org/licenses/LICENSE-2.0 *
+# *
+# Unless required by applicable law or agreed to in writing, *
+# software distributed under the License is distributed on an *
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY *
+# KIND, either express or implied. See the License for the *
+# specific language governing permissions and limitations *
+# under the License. *
+
+##
+## Core Dependencies .. these must be set
+##
+
javacc.home=${env.ETCH_EXTERNAL_DEPENDS}/javacc/5.0
-junit.lib=${env.ETCH_EXTERNAL_DEPENDS}/junit/4.3.1
+junit.lib=${env.ETCH_EXTERNAL_DEPENDS}/junit/4.3.1
velocity.lib=${env.ETCH_EXTERNAL_DEPENDS}/velocity/1.7
-
-##
-## Optional Dependencies
-##
-
-## NSIS
+
+##
+## Optional Dependencies
+##
+
+## NSIS
nsis.home=${env.ETCH_EXTERNAL_DEPENDS}/nsis/2.46
-
-## Clover
-clover.home=${env.ETCH_EXTERNAL_DEPENDS}/clover-ant/2.3.2
-
-## Csharp ANT support
+
+## Clover
+clover.home=${env.ETCH_EXTERNAL_DEPENDS}/clover-ant/2.3.2
+
+## Csharp ANT support
ant-dotnet.lib=${env.ETCH_EXTERNAL_DEPENDS}/apache-ant-dotnet/1.1
-
-## CMake ANT support
-ant-cmake.lib=${env.ETCH_EXTERNAL_DEPENDS}/apache-ant-cmake/1.0
-
-##
-## Settings
-##
-
-## skip tests build? (comment this to exclude)
-#skip.tests=true
-
-## skip example build? (comment this to exclude)
+
+## CMake ANT support
+ant-cmake.lib=${env.ETCH_EXTERNAL_DEPENDS}/apache-ant-cmake/1.0
+
+##
+## Settings
+##
+
+## skip tests build? (comment this to exclude)
+#skip.tests=true
+
+## skip example build? (comment this to exclude)
#skip.examples=true
\ No newline at end of file
Modified: incubator/etch/trunk/examples/chat/build.xml
URL: http://svn.apache.org/viewvc/incubator/etch/trunk/examples/chat/build.xml?rev=1230611&r1=1230610&r2=1230611&view=diff
==============================================================================
--- incubator/etch/trunk/examples/chat/build.xml (original)
+++ incubator/etch/trunk/examples/chat/build.xml Thu Jan 12 16:10:54 2012
@@ -257,7 +257,9 @@ To run java chat, open a cmd window and
> cd target\bin
> start java -cp chat.jar org.apache.etch.examples.chat.MainChatListener
+Start client 1
> start java -cp chat.jar org.apache.etch.examples.chat.MainChatClient
+Start client 2
> start java -cp chat.jar org.apache.etch.examples.chat.MainChatClient
Two chat clients will be started; there is a help command;
@@ -268,7 +270,9 @@ To run csharp chat:
> cd target\bin
> start ChatListener.exe
+Start client 1
> start ChatClient.exe
+Start client 2
> start ChatClient.exe
You can mix and match the various clients and listeners.
Modified: incubator/etch/trunk/examples/chat/dist-build.xml
URL: http://svn.apache.org/viewvc/incubator/etch/trunk/examples/chat/dist-build.xml?rev=1230611&r1=1230610&r2=1230611&view=diff
==============================================================================
--- incubator/etch/trunk/examples/chat/dist-build.xml (original)
+++ incubator/etch/trunk/examples/chat/dist-build.xml Thu Jan 12 16:10:54 2012
@@ -78,7 +78,9 @@ To run java chat, open a cmd window and
> cd target\bin
> start java -cp chat.jar org.apache.etch.examples.chat.MainChatListener
+Start client 1
> start java -cp chat.jar org.apache.etch.examples.chat.MainChatClient
+Start client 2
> start java -cp chat.jar org.apache.etch.examples.chat.MainChatClient
Two chat clients will be started; there is a help command;
@@ -89,7 +91,9 @@ To run csharp chat, open a cmd window an
> cd target\bin
> start ChatListener.exe
+Start client 1
> start ChatClient.exe
+Start client 2
> start ChatClient.exe
You can mix and match the various clients and listeners.
Modified: incubator/etch/trunk/examples/helloworld/CMakeLists.txt
URL: http://svn.apache.org/viewvc/incubator/etch/trunk/examples/helloworld/CMakeLists.txt?rev=1230611&r1=1230610&r2=1230611&view=diff
==============================================================================
--- incubator/etch/trunk/examples/helloworld/CMakeLists.txt (original)
+++ incubator/etch/trunk/examples/helloworld/CMakeLists.txt Thu Jan 12 16:10:54 2012
@@ -1,124 +1,124 @@
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to you under the Apache License, Version
-# 2.0 (the "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-cmake_minimum_required (VERSION 2.6)
-project (etch-c-helloworld)
-
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to you under the Apache License, Version
+# 2.0 (the "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+cmake_minimum_required (VERSION 2.6)
+project (etch-c-helloworld)
+
#if ETCH_HOME has not been set by Ant it is set to the OS environment variable
IF (NOT ETCH_HOME)
SET(ETCH_HOME $ENV{ETCH_HOME})
ENDIF (NOT ETCH_HOME)
-message(STATUS "using etch home ${ETCH_HOME}")
-
-#Etch Home
-IF (NOT ETCH_HOME)
- MESSAGE(FATAL_ERROR "ETCH_HOME not set")
-ENDIF (NOT ETCH_HOME)
-
-# Set definitions
-IF (UNIX)
- add_definitions(-D_GNU_SOURCE -D_REENTRANT -DLINUX=2 -D__LINUX__)
-ENDIF (UNIX)
-add_definitions(-D_UNICODE -DUNICODE)
-
-# ETCH library
-SET(ETCH ${ETCH_HOME}/binding-c)
-FIND_PATH(ETCH_INCLUDE_DIR etch.h ${ETCH}/include)
-FIND_LIBRARY(ETCH_LIBRARY NAMES etch.lib libetch.a PATHS ${ETCH}/lib)
-IF (ETCH_INCLUDE_DIR AND ETCH_LIBRARY)
- SET(ETCH_FOUND TRUE)
-ENDIF (ETCH_INCLUDE_DIR AND ETCH_LIBRARY)
-IF (NOT ETCH_FOUND)
- MESSAGE(FATAL_ERROR "Could not find libetch")
-ENDIF (NOT ETCH_FOUND)
-
-# APR library
-SET(APR ${ETCH_HOME}/binding-c/extern/apr)
-FIND_PATH(APR_INCLUDE_DIR apr.h ${APR}/include ${APR}/include/apr-1)
-FIND_LIBRARY(APR_LIBRARY NAMES libapr-1.lib libapr-1.so PATHS ${APR}/lib)
-IF (APR_INCLUDE_DIR AND APR_LIBRARY)
- SET(APR_FOUND TRUE)
-ENDIF (APR_INCLUDE_DIR AND APR_LIBRARY)
-IF (NOT APR_FOUND)
- MESSAGE(FATAL_ERROR "Could not find libapr")
-ENDIF (NOT APR_FOUND)
-
-# APR-ICONV library
-SET(APR ${ETCH_HOME}/binding-c/extern/apr)
-FIND_PATH(APR-ICONV_INCLUDE_DIR apr_iconv.h ${APR}/include ${APR}/include/apr-1)
-FIND_LIBRARY(APR-ICONV_LIBRARY NAMES libapriconv-1.lib libapriconv-1.so PATHS ${APR}/lib)
-IF (APR-ICONV_INCLUDE_DIR AND APR-ICONV_LIBRARY)
- SET(APR-ICONV_FOUND TRUE)
-ENDIF (APR-ICONV_INCLUDE_DIR AND APR-ICONV_LIBRARY)
-IF (NOT APR-ICONV_FOUND)
- MESSAGE(FATAL_ERROR "Could not find libapriconv")
-ENDIF (NOT APR-ICONV_FOUND)
-
-# set include dirs
-include_directories (${APR_INCLUDE_DIR})
-include_directories (${APR-ICONV_INCLUDE_DIR})
-include_directories (${ETCH_INCLUDE_DIR})
-include_directories (${PROJECT_SOURCE_DIR}/src/main/c)
-include_directories (${PROJECT_SOURCE_DIR}/target/generated-sources/main/etch/c)
-
-add_executable(etch-c-helloworld-server
- src/main/c/helloworld_server_implx.c
- src/main/c/helloworld_server_impl.c
- src/main/c/helloworld_listener_main.c
- target/generated-sources/main/etch/c/helloworld_interface.c
- target/generated-sources/main/etch/c/helloworld_client.c
- target/generated-sources/main/etch/c/helloworld_server_stub.c
- target/generated-sources/main/etch/c/helloworld_helper.c
- target/generated-sources/main/etch/c/helloworld_client_stub.c
- target/generated-sources/main/etch/c/helloworld_remote_client.c
- target/generated-sources/main/etch/c/helloworld_remote_server.c
- target/generated-sources/main/etch/c/helloworld_server.c
- target/generated-sources/main/etch/c/helloworld_valufact.c
- target/generated-sources/main/etch/c/helloworld_remote.c
-)
-
-add_executable(etch-c-helloworld-client
- src/main/c/helloworld_client_impl.c
- src/main/c/helloworld_client_implx.c
- src/main/c/helloworld_client_main.c
- target/generated-sources/main/etch/c/helloworld_interface.c
- target/generated-sources/main/etch/c/helloworld_client.c
- target/generated-sources/main/etch/c/helloworld_server_stub.c
- target/generated-sources/main/etch/c/helloworld_helper.c
- target/generated-sources/main/etch/c/helloworld_client_stub.c
- target/generated-sources/main/etch/c/helloworld_remote_client.c
- target/generated-sources/main/etch/c/helloworld_remote_server.c
- target/generated-sources/main/etch/c/helloworld_server.c
- target/generated-sources/main/etch/c/helloworld_valufact.c
- target/generated-sources/main/etch/c/helloworld_remote.c
-)
-
-target_link_libraries(etch-c-helloworld-server "${APR_LIBRARY}")
-target_link_libraries(etch-c-helloworld-server "${APR-ICONV_LIBRARY}")
-target_link_libraries(etch-c-helloworld-server "${ETCH_LIBRARY}")
-IF (UNIX)
-set_target_properties(etch-c-helloworld-server PROPERTIES COMPILE_FLAGS "-m32" LINK_FLAGS "-m32")
-ENDIF (UNIX)
-set_target_properties(etch-c-helloworld-server PROPERTIES OUTPUT_NAME "helloworld-server")
-
-target_link_libraries(etch-c-helloworld-client "${APR_LIBRARY}")
-target_link_libraries(etch-c-helloworld-client "${APR-ICONV_LIBRARY}")
-target_link_libraries(etch-c-helloworld-client "${ETCH_LIBRARY}")
-IF (UNIX)
-set_target_properties(etch-c-helloworld-client PROPERTIES COMPILE_FLAGS "-m32" LINK_FLAGS "-m32")
-ENDIF (UNIX)
-set_target_properties(etch-c-helloworld-client PROPERTIES OUTPUT_NAME "helloworld-client")
+message(STATUS "using etch home ${ETCH_HOME}")
+
+#Etch Home
+IF (NOT ETCH_HOME)
+ MESSAGE(FATAL_ERROR "ETCH_HOME not set")
+ENDIF (NOT ETCH_HOME)
+
+# Set definitions
+IF (UNIX)
+ add_definitions(-D_GNU_SOURCE -D_REENTRANT -DLINUX=2 -D__LINUX__)
+ENDIF (UNIX)
+add_definitions(-D_UNICODE -DUNICODE)
+
+# ETCH library
+SET(ETCH ${ETCH_HOME}/binding-c)
+FIND_PATH(ETCH_INCLUDE_DIR etch.h ${ETCH}/include)
+FIND_LIBRARY(ETCH_LIBRARY NAMES etch.lib libetch.a PATHS ${ETCH}/lib)
+IF (ETCH_INCLUDE_DIR AND ETCH_LIBRARY)
+ SET(ETCH_FOUND TRUE)
+ENDIF (ETCH_INCLUDE_DIR AND ETCH_LIBRARY)
+IF (NOT ETCH_FOUND)
+ MESSAGE(FATAL_ERROR "Could not find libetch")
+ENDIF (NOT ETCH_FOUND)
+
+# APR library
+SET(APR ${ETCH_HOME}/binding-c/extern/apr)
+FIND_PATH(APR_INCLUDE_DIR apr.h ${APR}/include ${APR}/include/apr-1)
+FIND_LIBRARY(APR_LIBRARY NAMES libapr-1.lib libapr-1.so PATHS ${APR}/lib)
+IF (APR_INCLUDE_DIR AND APR_LIBRARY)
+ SET(APR_FOUND TRUE)
+ENDIF (APR_INCLUDE_DIR AND APR_LIBRARY)
+IF (NOT APR_FOUND)
+ MESSAGE(FATAL_ERROR "Could not find libapr")
+ENDIF (NOT APR_FOUND)
+
+# APR-ICONV library
+SET(APR ${ETCH_HOME}/binding-c/extern/apr)
+FIND_PATH(APR-ICONV_INCLUDE_DIR apr_iconv.h ${APR}/include ${APR}/include/apr-1)
+FIND_LIBRARY(APR-ICONV_LIBRARY NAMES libapriconv-1.lib libapriconv-1.so PATHS ${APR}/lib)
+IF (APR-ICONV_INCLUDE_DIR AND APR-ICONV_LIBRARY)
+ SET(APR-ICONV_FOUND TRUE)
+ENDIF (APR-ICONV_INCLUDE_DIR AND APR-ICONV_LIBRARY)
+IF (NOT APR-ICONV_FOUND)
+ MESSAGE(FATAL_ERROR "Could not find libapriconv")
+ENDIF (NOT APR-ICONV_FOUND)
+
+# set include dirs
+include_directories (${APR_INCLUDE_DIR})
+include_directories (${APR-ICONV_INCLUDE_DIR})
+include_directories (${ETCH_INCLUDE_DIR})
+include_directories (${PROJECT_SOURCE_DIR}/src/main/c)
+include_directories (${PROJECT_SOURCE_DIR}/target/generated-sources/main/etch/c)
+
+add_executable(etch-c-helloworld-server
+ src/main/c/helloworld_server_implx.c
+ src/main/c/helloworld_server_impl.c
+ src/main/c/helloworld_listener_main.c
+ target/generated-sources/main/etch/c/helloworld_interface.c
+ target/generated-sources/main/etch/c/helloworld_client.c
+ target/generated-sources/main/etch/c/helloworld_server_stub.c
+ target/generated-sources/main/etch/c/helloworld_helper.c
+ target/generated-sources/main/etch/c/helloworld_client_stub.c
+ target/generated-sources/main/etch/c/helloworld_remote_client.c
+ target/generated-sources/main/etch/c/helloworld_remote_server.c
+ target/generated-sources/main/etch/c/helloworld_server.c
+ target/generated-sources/main/etch/c/helloworld_valufact.c
+ target/generated-sources/main/etch/c/helloworld_remote.c
+)
+
+add_executable(etch-c-helloworld-client
+ src/main/c/helloworld_client_impl.c
+ src/main/c/helloworld_client_implx.c
+ src/main/c/helloworld_client_main.c
+ target/generated-sources/main/etch/c/helloworld_interface.c
+ target/generated-sources/main/etch/c/helloworld_client.c
+ target/generated-sources/main/etch/c/helloworld_server_stub.c
+ target/generated-sources/main/etch/c/helloworld_helper.c
+ target/generated-sources/main/etch/c/helloworld_client_stub.c
+ target/generated-sources/main/etch/c/helloworld_remote_client.c
+ target/generated-sources/main/etch/c/helloworld_remote_server.c
+ target/generated-sources/main/etch/c/helloworld_server.c
+ target/generated-sources/main/etch/c/helloworld_valufact.c
+ target/generated-sources/main/etch/c/helloworld_remote.c
+)
+
+target_link_libraries(etch-c-helloworld-server "${APR_LIBRARY}")
+target_link_libraries(etch-c-helloworld-server "${APR-ICONV_LIBRARY}")
+target_link_libraries(etch-c-helloworld-server "${ETCH_LIBRARY}")
+IF (UNIX)
+set_target_properties(etch-c-helloworld-server PROPERTIES COMPILE_FLAGS "-m32" LINK_FLAGS "-m32")
+ENDIF (UNIX)
+set_target_properties(etch-c-helloworld-server PROPERTIES OUTPUT_NAME "helloworld-server")
+
+target_link_libraries(etch-c-helloworld-client "${APR_LIBRARY}")
+target_link_libraries(etch-c-helloworld-client "${APR-ICONV_LIBRARY}")
+target_link_libraries(etch-c-helloworld-client "${ETCH_LIBRARY}")
+IF (UNIX)
+set_target_properties(etch-c-helloworld-client PROPERTIES COMPILE_FLAGS "-m32" LINK_FLAGS "-m32")
+ENDIF (UNIX)
+set_target_properties(etch-c-helloworld-client PROPERTIES OUTPUT_NAME "helloworld-client")
Modified: incubator/etch/trunk/examples/helloworld/README.txt
URL: http://svn.apache.org/viewvc/incubator/etch/trunk/examples/helloworld/README.txt?rev=1230611&r1=1230610&r2=1230611&view=diff
==============================================================================
--- incubator/etch/trunk/examples/helloworld/README.txt (original)
+++ incubator/etch/trunk/examples/helloworld/README.txt Thu Jan 12 16:10:54 2012
@@ -1,7 +1,7 @@
-Helloworld is the classic example and shows basic usage of etch and the interoperability of the bindings.
-
+Helloworld is the classic example and shows basic usage of etch and the interoperability of the bindings.
+
Call
-ant Debug
+ant Debug
to generate sources, build and run tests.
-
+
Further information on how to run the generated executables of different bindings can be found in the dist-README.txt file.
Modified: incubator/etch/trunk/examples/helloworld/build.xml
URL: http://svn.apache.org/viewvc/incubator/etch/trunk/examples/helloworld/build.xml?rev=1230611&r1=1230610&r2=1230611&view=diff
==============================================================================
--- incubator/etch/trunk/examples/helloworld/build.xml (original)
+++ incubator/etch/trunk/examples/helloworld/build.xml Thu Jan 12 16:10:54 2012
@@ -1,367 +1,367 @@
-<?xml version="1.0" encoding="utf-8" ?>
- <!--
- * Licensed to the Apache Software Foundation (ASF) under one *
- * or more contributor license agreements. See the NOTICE file *
- * distributed with this work for additional information *
- * regarding copyright ownership. The ASF licenses this file *
- * to you under the Apache License, Version 2.0 (the *
- * "License"); you may not use this file except in compliance *
- * with the License. You may obtain a copy of the License at *
- * *
- * http://www.apache.org/licenses/LICENSE-2.0 *
- * *
- * Unless required by applicable law or agreed to in writing, *
- * software distributed under the License is distributed on an *
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY *
- * KIND, either express or implied. See the License for the *
- * specific language governing permissions and limitations *
- * under the License. *
- -->
-<project name="etch-HelloWorld-example" basedir="." default="help" >
- <description>HelloWorld Example</description>
- <property name="Etch.basedir" location="${basedir}/../.." />
- <import file="${Etch.basedir}/build-support/etch.includes.xml" />
-
- <!-- TODO better computation of etch.home, etch.version -->
- <property environment="env" />
-
- <!-- compute ETCH_HOME -->
- <property name="build.ETCH_HOME" location="${basedir}/../../target/Installers/dist" />
- <condition property="etch.home" value="${env.ETCH_HOME}" >
- <isset property="${env.ETCH_HOME}" />
- </condition>
- <condition property="etch.home" value="${build.ETCH_HOME}" >
- <not><isset property="etch.home" /></not>
- </condition>
-
- <property name="Etch.dependency.junit.jar"
- location="${default.junit.lib}/junit-4.3.1.jar" />
-
- <property name="Etch.buildSupportDirectory" location="../../build-support" />
-
- <!-- compute etch.version -->
- <condition property="etch.version" value="${Etch.version}" >
- <not><isset property="etch.version" /></not>
- </condition>
-
- <condition property="etch.longversion" value="${Etch.longversion}" >
- <not><isset property="etch.longversion" /></not>
- </condition>
-
- <!-- Csharp Support -->
- <condition property="USE.dotnet" >
- <and>
- <os family="windows" />
- <available file="${env.DOTNET_HOME}/msbuild.exe" />
+<?xml version="1.0" encoding="utf-8" ?>
+ <!--
+ * Licensed to the Apache Software Foundation (ASF) under one *
+ * or more contributor license agreements. See the NOTICE file *
+ * distributed with this work for additional information *
+ * regarding copyright ownership. The ASF licenses this file *
+ * to you under the Apache License, Version 2.0 (the *
+ * "License"); you may not use this file except in compliance *
+ * with the License. You may obtain a copy of the License at *
+ * *
+ * http://www.apache.org/licenses/LICENSE-2.0 *
+ * *
+ * Unless required by applicable law or agreed to in writing, *
+ * software distributed under the License is distributed on an *
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY *
+ * KIND, either express or implied. See the License for the *
+ * specific language governing permissions and limitations *
+ * under the License. *
+ -->
+<project name="etch-HelloWorld-example" basedir="." default="help" >
+ <description>HelloWorld Example</description>
+ <property name="Etch.basedir" location="${basedir}/../.." />
+ <import file="${Etch.basedir}/build-support/etch.includes.xml" />
+
+ <!-- TODO better computation of etch.home, etch.version -->
+ <property environment="env" />
+
+ <!-- compute ETCH_HOME -->
+ <property name="build.ETCH_HOME" location="${basedir}/../../target/Installers/dist" />
+ <condition property="etch.home" value="${env.ETCH_HOME}" >
+ <isset property="${env.ETCH_HOME}" />
+ </condition>
+ <condition property="etch.home" value="${build.ETCH_HOME}" >
+ <not><isset property="etch.home" /></not>
+ </condition>
+
+ <property name="Etch.dependency.junit.jar"
+ location="${default.junit.lib}/junit-4.3.1.jar" />
+
+ <property name="Etch.buildSupportDirectory" location="../../build-support" />
+
+ <!-- compute etch.version -->
+ <condition property="etch.version" value="${Etch.version}" >
+ <not><isset property="etch.version" /></not>
+ </condition>
+
+ <condition property="etch.longversion" value="${Etch.longversion}" >
+ <not><isset property="etch.longversion" /></not>
+ </condition>
+
+ <!-- Csharp Support -->
+ <condition property="USE.dotnet" >
+ <and>
+ <os family="windows" />
+ <available file="${env.DOTNET_HOME}/msbuild.exe" />
<available file="${build.ant-dotnet.lib}/ant-dotnet-1.1.jar" />
<available file="${env.NUNIT_HOME}/bin/net-2.0/nunit.exe" />
- </and>
- </condition>
- <condition property="USE.mono" >
- <and>
- <not><os family="windows" /></not>
- <!-- TODO mono support is not fully baked, use -DUSE.mono to test -->
- <!-- <available file="${env.MONO_HOME}/bin/mdtool" /> -->
- <isset property="USE.mono" />
- </and>
- </condition>
- <condition property="BUILD.csharp" >
- <or>
- <isset property="USE.dotnet" />
- <isset property="USE.mono" />
- </or>
- </condition>
-
- <!-- import etch task -->
- <taskdef onerror="report" resource="org/apache/etch/tools/ant/etch.xml" classpath="${etch.home}/lib/apache-etch-ant-plugin-${etch.longversion}.jar" />
-
- <!-- import dotnet task -->
+ </and>
+ </condition>
+ <condition property="USE.mono" >
+ <and>
+ <not><os family="windows" /></not>
+ <!-- TODO mono support is not fully baked, use -DUSE.mono to test -->
+ <!-- <available file="${env.MONO_HOME}/bin/mdtool" /> -->
+ <isset property="USE.mono" />
+ </and>
+ </condition>
+ <condition property="BUILD.csharp" >
+ <or>
+ <isset property="USE.dotnet" />
+ <isset property="USE.mono" />
+ </or>
+ </condition>
+
+ <!-- import etch task -->
+ <taskdef onerror="report" resource="org/apache/etch/tools/ant/etch.xml" classpath="${etch.home}/lib/apache-etch-ant-plugin-${etch.longversion}.jar" />
+
+ <!-- import dotnet task -->
<condition property="ant.dotnet.jar" value="ant-dotnet-1.1.jar" >
- <not><isset property="ant.dotnet.jar" /></not>
- </condition>
-
- <taskdef
- onerror="report"
- resource="org/apache/ant/dotnet/antlib.xml"
- classpath="${ant.dotnet.jar}" />
-
- <macrodef name="mdtool" >
- <attribute name="dir" default="." />
- <attribute name="failonerror" default="false" />
- <attribute name="project" default="project.csproj" />
- <attribute name="target" default="${build.target}" />
- <sequential>
- <exec executable="${env.MONO_HOME}/bin/mdtool" dir="@{dir}" failonerror="@{failonerror}" >
- <arg value="build" />
- <arg value="--buildfile:@{project}" />
- </exec>
- </sequential>
- </macrodef>
-
- <!-- set properties -->
- <property name="src" location="${basedir}/src" />
- <property name="main-src-java" location="${src}/main/java" />
- <property name="test-src-java" location="${src}/test/java" />
- <property name="target" location="${basedir}/target" />
- <property name="dist-src" location="${target}/dist-src" />
- <property name="generated-sources" location="${target}/generated-sources" />
- <property name="gen-src-java" location="${generated-sources}/main/etch/java" />
- <property name="gen-src-csharp" location="${generated-sources}/main/etch/csharp" />
- <property name="gen-src-c" location="${generated-sources}/main/etch/c" />
- <property name="bin" location="${target}/bin" />
- <property name="classes" location="${target}/classes" />
- <property name="classes-test" location="${target}/classes-test" />
- <property name="test-results" location="${target}/test-results" />
- <property name="nunit-results" location="${target}/nunit-results" />
- <property name="dist" location="${basedir}/../../target/Installers/dist" />
-
- <!-- initialize -->
- <target name="init" >
- <mkdir dir="${target}" />
- <mkdir dir="${dist-src}" />
- <mkdir dir="${generated-sources}" />
- <mkdir dir="${gen-src-java}" />
- <mkdir dir="${gen-src-csharp}" />
- <mkdir dir="${bin}" />
- <mkdir dir="${classes}" />
- <mkdir dir="${classes-test}" />
- <mkdir dir="${test-results}" />
- <mkdir dir="${nunit-results}" />
- </target>
-
- <!-- build the server -->
- <target name="generate-sources" depends="init" >
- <!-- generate sources -->
-
- <etch home="${etch.home}"
- file="${src}/main/etch/HelloWorld.etch"
- binding="java"
- outputDir="${gen-src-java}" />
-
- <etch home="${etch.home}"
- file="${src}/main/etch/HelloWorld.etch"
- binding="csharp"
- outputDir="${gen-src-csharp}" />
-
- <etch home="${etch.home}"
- file="${src}/main/etch/HelloWorld.etch"
- binding="c"
- outputDir="${gen-src-c}" />
- </target>
-
- <property name="etch-java-runtime-name" value="apache-etch-java-runtime-${etch.longversion}.jar" />
- <property name="Etch.dependency.java.runtime" location="${etch.home}/binding-java/lib/${etch-java-runtime-name}" />
-
- <target name="build-java" depends="generate-sources" >
- <!-- compile sources -->
-
- <javac target="1.5" destdir="${classes}" >
- <src path="${gen-src-java}" />
- <src path="${main-src-java}" />
- <classpath>
- <pathelement location="${Etch.dependency.java.runtime}" />
- </classpath>
- </javac>
-
- <javac target="1.5" destdir="${classes-test}" >
- <src path="${gen-src-java}" />
- <src path="${main-src-java}" />
- <src path="${test-src-java}" />
- <classpath>
- <pathelement location="${Etch.dependency.java.runtime}" />
- <pathelement location="${Etch.dependency.junit.jar}" />
- </classpath>
- </javac>
-
- <!-- Create Jar -->
- <jar jarfile="${bin}/helloworld.jar" >
- <manifest>
- <attribute name="Class-Path" value="${etch-java-runtime-name}" />
- </manifest>
- <fileset dir="${classes}" >
- <include name="**/*" />
- </fileset>
- </jar>
-
- <!-- copy in dependencies -->
- <copy todir="${bin}" file="${Etch.dependency.java.runtime}" />
- </target>
-
- <target name="build-csharp-with-mono" depends="generate-sources" if="USE.mono" >
- <mdtool dir="${src}/main/csharp/HelloWorldClientProj" project="HelloWorldClientProj.csproj" />
- <mdtool dir="${src}/main/csharp/HelloWorldListenerProj" project="HelloWorldListenerProj.csproj" />
- </target>
-
- <target name="build-csharp-with-dotnet" depends="generate-sources" if="USE.dotnet" >
- <msbuild buildfile="${src}/main/csharp/HelloWorldListenerProj/HelloWorldListenerProj.csproj" >
- <property name="Configuration" value="${build.target}" />
- </msbuild>
- <msbuild buildfile="${src}/main/csharp/HelloWorldClientProj/HelloWorldClientProj.csproj" >
- <property name="Configuration" value="${build.target}" />
- </msbuild>
- <msbuild buildfile="${src}/test/csharp/HelloWorldTestProj/HelloWorldTestProj.csproj" >
- <property name="Configuration" value="${build.target}" />
- </msbuild>
- <copy todir="${bin}" >
- <fileset dir="${src}/main/csharp/HelloWorldListenerProj/bin/${build.target}" >
- <include name="*" />
- </fileset>
- <fileset dir="${src}/main/csharp/HelloWorldClientProj/bin/${build.target}" >
- <include name="*" />
- </fileset>
- </copy>
- </target>
-
- <target name="build-csharp" depends="build-csharp-with-mono,build-csharp-with-dotnet" />
-
- <target name="build-c" depends="generate-sources" if="USE.cmake">
- <cmake srcdir="${basedir}" bindir="${basedir}/target" buildtype="Debug" >
- <variable name="ETCH_HOME" type="PATH" value="${etch.home}" />
- </cmake>
- <copy todir="${bin}" flatten="true">
- <fileset dir="${basedir}/target/" >
- <include name="helloworld-client" />
- <include name="helloworld-server" />
- <include name="debug/helloworld-client.exe" />
- <include name="debug/helloworld-server.exe" />
- </fileset>
- </copy>
- <copy todir="${bin}" flatten="true">
- <fileset dir="${etch.home}/binding-c/extern/apr/bin" >
- <include name="libapr-1.dll" />
- <include name="libapriconv-1.dll" />
- </fileset>
- </copy>
-
- </target>
-
- <target name="build" depends="build-java,build-csharp,build-c" />
-
- <!-- run unit tests -->
-
- <target name="test-java" depends="build-java" unless="build.skip.tests">
- <!-- Run Unit Tests -->
- <junit printsummary="yes" haltonfailure="no" dir="${classes-test}"
- errorProperty="build.tests.fail" failureProperty="build.tests.fail" >
- <classpath>
- <pathelement location="${classes-test}" />
- <pathelement location="${Etch.dependency.java.runtime}" />
- <pathelement location="${Etch.dependency.junit.jar}" />
- </classpath>
- <formatter type="xml" />
- <batchtest fork="true" todir="${test-results}" >
- <fileset dir="${test-src-java}" >
- <include name="**/Test*.java" />
- </fileset>
- </batchtest>
- </junit>
- </target>
-
- <target name="test-csharp" depends="build-csharp" if="BUILD.csharp" unless="build.skip.tests">
- <nunit xmlout="${nunit-results}/NUnitResults.xml">
- <testassembly name="${src}/test/csharp/HelloWorldTestProj/bin/${build.target}/HelloWorldTestProj.dll" />
- </nunit>
-
- <xslt style="${Etch.buildSupportDirectory}/NUnitToJUnit.xsl"
- in="${nunit-results}/NUnitResults.xml" out="${test-results}/TEST-NUnitResults.xml" />
- </target>
-
- <target name="test" depends="build,test-java,test-csharp,done" >
- </target>
-
- <target name="done" depends="build" >
- <echo>
-
-Build Complete!
-
-To run java HelloWorld example, open a cmd window and run these
-commands:
-
-> cd target\bin
-> start java -cp helloworld.jar org.apache.etch.examples.helloworld.MainHelloWorldListener
-> start java -cp helloworld.jar org.apache.etch.examples.helloworld.MainHelloWorldClient
-
-To run csharp example:
-
-> cd target\bin
-> start HelloWorldListener.exe
-> start HelloWorldClient.exe
-
-To run the c example:
-
-> build using cmake (see README.txt) (if you are not building from trunk,
- e.g. if you have an official release)
-> cd target\debug
-> start helloworld-server.exe
-> start helloworld-client.exe
-
-You can mix and match the various clients and listeners.
-
- </echo>
- </target>
-
- <!-- build everything -->
- <target name="init-debug" >
- <property name="build.target" value="Debug" />
- </target>
-
- <target name="init-release" >
- <property name="build.target" value="Release" />
- </target>
-
- <target name="dist-src" >
- <copy file="dist-build.xml" tofile="${dist-src}/build.xml" overwrite="true" >
- <filterset refid="Etch.buildTokens" />
- </copy>
- <copy file="CMakeLists.txt" tofile="${dist-src}/CMakeLists.txt" overwrite="true" />
+ <not><isset property="ant.dotnet.jar" /></not>
+ </condition>
+
+ <taskdef
+ onerror="report"
+ resource="org/apache/ant/dotnet/antlib.xml"
+ classpath="${ant.dotnet.jar}" />
+
+ <macrodef name="mdtool" >
+ <attribute name="dir" default="." />
+ <attribute name="failonerror" default="false" />
+ <attribute name="project" default="project.csproj" />
+ <attribute name="target" default="${build.target}" />
+ <sequential>
+ <exec executable="${env.MONO_HOME}/bin/mdtool" dir="@{dir}" failonerror="@{failonerror}" >
+ <arg value="build" />
+ <arg value="--buildfile:@{project}" />
+ </exec>
+ </sequential>
+ </macrodef>
+
+ <!-- set properties -->
+ <property name="src" location="${basedir}/src" />
+ <property name="main-src-java" location="${src}/main/java" />
+ <property name="test-src-java" location="${src}/test/java" />
+ <property name="target" location="${basedir}/target" />
+ <property name="dist-src" location="${target}/dist-src" />
+ <property name="generated-sources" location="${target}/generated-sources" />
+ <property name="gen-src-java" location="${generated-sources}/main/etch/java" />
+ <property name="gen-src-csharp" location="${generated-sources}/main/etch/csharp" />
+ <property name="gen-src-c" location="${generated-sources}/main/etch/c" />
+ <property name="bin" location="${target}/bin" />
+ <property name="classes" location="${target}/classes" />
+ <property name="classes-test" location="${target}/classes-test" />
+ <property name="test-results" location="${target}/test-results" />
+ <property name="nunit-results" location="${target}/nunit-results" />
+ <property name="dist" location="${basedir}/../../target/Installers/dist" />
+
+ <!-- initialize -->
+ <target name="init" >
+ <mkdir dir="${target}" />
+ <mkdir dir="${dist-src}" />
+ <mkdir dir="${generated-sources}" />
+ <mkdir dir="${gen-src-java}" />
+ <mkdir dir="${gen-src-csharp}" />
+ <mkdir dir="${bin}" />
+ <mkdir dir="${classes}" />
+ <mkdir dir="${classes-test}" />
+ <mkdir dir="${test-results}" />
+ <mkdir dir="${nunit-results}" />
+ </target>
+
+ <!-- build the server -->
+ <target name="generate-sources" depends="init" >
+ <!-- generate sources -->
+
+ <etch home="${etch.home}"
+ file="${src}/main/etch/HelloWorld.etch"
+ binding="java"
+ outputDir="${gen-src-java}" />
+
+ <etch home="${etch.home}"
+ file="${src}/main/etch/HelloWorld.etch"
+ binding="csharp"
+ outputDir="${gen-src-csharp}" />
+
+ <etch home="${etch.home}"
+ file="${src}/main/etch/HelloWorld.etch"
+ binding="c"
+ outputDir="${gen-src-c}" />
+ </target>
+
+ <property name="etch-java-runtime-name" value="apache-etch-java-runtime-${etch.longversion}.jar" />
+ <property name="Etch.dependency.java.runtime" location="${etch.home}/binding-java/lib/${etch-java-runtime-name}" />
+
+ <target name="build-java" depends="generate-sources" >
+ <!-- compile sources -->
+
+ <javac target="1.5" destdir="${classes}" >
+ <src path="${gen-src-java}" />
+ <src path="${main-src-java}" />
+ <classpath>
+ <pathelement location="${Etch.dependency.java.runtime}" />
+ </classpath>
+ </javac>
+
+ <javac target="1.5" destdir="${classes-test}" >
+ <src path="${gen-src-java}" />
+ <src path="${main-src-java}" />
+ <src path="${test-src-java}" />
+ <classpath>
+ <pathelement location="${Etch.dependency.java.runtime}" />
+ <pathelement location="${Etch.dependency.junit.jar}" />
+ </classpath>
+ </javac>
+
+ <!-- Create Jar -->
+ <jar jarfile="${bin}/helloworld.jar" >
+ <manifest>
+ <attribute name="Class-Path" value="${etch-java-runtime-name}" />
+ </manifest>
+ <fileset dir="${classes}" >
+ <include name="**/*" />
+ </fileset>
+ </jar>
+
+ <!-- copy in dependencies -->
+ <copy todir="${bin}" file="${Etch.dependency.java.runtime}" />
+ </target>
+
+ <target name="build-csharp-with-mono" depends="generate-sources" if="USE.mono" >
+ <mdtool dir="${src}/main/csharp/HelloWorldClientProj" project="HelloWorldClientProj.csproj" />
+ <mdtool dir="${src}/main/csharp/HelloWorldListenerProj" project="HelloWorldListenerProj.csproj" />
+ </target>
+
+ <target name="build-csharp-with-dotnet" depends="generate-sources" if="USE.dotnet" >
+ <msbuild buildfile="${src}/main/csharp/HelloWorldListenerProj/HelloWorldListenerProj.csproj" >
+ <property name="Configuration" value="${build.target}" />
+ </msbuild>
+ <msbuild buildfile="${src}/main/csharp/HelloWorldClientProj/HelloWorldClientProj.csproj" >
+ <property name="Configuration" value="${build.target}" />
+ </msbuild>
+ <msbuild buildfile="${src}/test/csharp/HelloWorldTestProj/HelloWorldTestProj.csproj" >
+ <property name="Configuration" value="${build.target}" />
+ </msbuild>
+ <copy todir="${bin}" >
+ <fileset dir="${src}/main/csharp/HelloWorldListenerProj/bin/${build.target}" >
+ <include name="*" />
+ </fileset>
+ <fileset dir="${src}/main/csharp/HelloWorldClientProj/bin/${build.target}" >
+ <include name="*" />
+ </fileset>
+ </copy>
+ </target>
+
+ <target name="build-csharp" depends="build-csharp-with-mono,build-csharp-with-dotnet" />
+
+ <target name="build-c" depends="generate-sources" if="USE.cmake">
+ <cmake srcdir="${basedir}" bindir="${basedir}/target" buildtype="Debug" >
+ <variable name="ETCH_HOME" type="PATH" value="${etch.home}" />
+ </cmake>
+ <copy todir="${bin}" flatten="true">
+ <fileset dir="${basedir}/target/" >
+ <include name="helloworld-client" />
+ <include name="helloworld-server" />
+ <include name="debug/helloworld-client.exe" />
+ <include name="debug/helloworld-server.exe" />
+ </fileset>
+ </copy>
+ <copy todir="${bin}" flatten="true">
+ <fileset dir="${etch.home}/binding-c/extern/apr/bin" >
+ <include name="libapr-1.dll" />
+ <include name="libapriconv-1.dll" />
+ </fileset>
+ </copy>
+
+ </target>
+
+ <target name="build" depends="build-java,build-csharp,build-c" />
+
+ <!-- run unit tests -->
+
+ <target name="test-java" depends="build-java" unless="build.skip.tests">
+ <!-- Run Unit Tests -->
+ <junit printsummary="yes" haltonfailure="no" dir="${classes-test}"
+ errorProperty="build.tests.fail" failureProperty="build.tests.fail" >
+ <classpath>
+ <pathelement location="${classes-test}" />
+ <pathelement location="${Etch.dependency.java.runtime}" />
+ <pathelement location="${Etch.dependency.junit.jar}" />
+ </classpath>
+ <formatter type="xml" />
+ <batchtest fork="true" todir="${test-results}" >
+ <fileset dir="${test-src-java}" >
+ <include name="**/Test*.java" />
+ </fileset>
+ </batchtest>
+ </junit>
+ </target>
+
+ <target name="test-csharp" depends="build-csharp" if="BUILD.csharp" unless="build.skip.tests">
+ <nunit xmlout="${nunit-results}/NUnitResults.xml">
+ <testassembly name="${src}/test/csharp/HelloWorldTestProj/bin/${build.target}/HelloWorldTestProj.dll" />
+ </nunit>
+
+ <xslt style="${Etch.buildSupportDirectory}/NUnitToJUnit.xsl"
+ in="${nunit-results}/NUnitResults.xml" out="${test-results}/TEST-NUnitResults.xml" />
+ </target>
+
+ <target name="test" depends="build,test-java,test-csharp,done" >
+ </target>
+
+ <target name="done" depends="build" >
+ <echo>
+
+Build Complete!
+
+To run java HelloWorld example, open a cmd window and run these
+commands:
+
+> cd target\bin
+> start java -cp helloworld.jar org.apache.etch.examples.helloworld.MainHelloWorldListener
+> start java -cp helloworld.jar org.apache.etch.examples.helloworld.MainHelloWorldClient
+
+To run csharp example:
+
+> cd target\bin
+> start HelloWorldListener.exe
+> start HelloWorldClient.exe
+
+To run the c example:
+
+> build using cmake (see README.txt) (if you are not building from trunk,
+ e.g. if you have an official release)
+> cd target\debug
+> start helloworld-server.exe
+> start helloworld-client.exe
+
+You can mix and match the various clients and listeners.
+
+ </echo>
+ </target>
+
+ <!-- build everything -->
+ <target name="init-debug" >
+ <property name="build.target" value="Debug" />
+ </target>
+
+ <target name="init-release" >
+ <property name="build.target" value="Release" />
+ </target>
+
+ <target name="dist-src" >
+ <copy file="dist-build.xml" tofile="${dist-src}/build.xml" overwrite="true" >
+ <filterset refid="Etch.buildTokens" />
+ </copy>
+ <copy file="CMakeLists.txt" tofile="${dist-src}/CMakeLists.txt" overwrite="true" />
<copy file="dist-README.txt" tofile="${dist-src}/README.txt" overwrite="true" />
-
- <copy todir="${dist-src}/src/main/etch" overwrite="true" >
- <fileset dir="${src}/main/etch" >
- <exclude name="**/.svn/**" />
- <include name="**/*.etch" />
- </fileset>
- </copy>
-
- <copy todir="${dist-src}/src/main/java" overwrite="true" >
- <fileset dir="${src}/main/java" >
- <exclude name="**/.svn/**" />
- <include name="**/*.java" />
- </fileset>
- </copy>
-
- <copy todir="${dist-src}/src/main/csharp" overwrite="true" >
- <fileset dir="${src}/main/csharp" >
- <exclude name="**/.svn/**" />
- <include name="**/*.cs" />
- </fileset>
- </copy>
-
- <copy todir="${dist-src}/src/main/c" overwrite="true" >
- <fileset dir="${src}/main/c" >
- <exclude name="**/.svn/**" />
- <include name="**/*.c" />
- <include name="**/*.h" />
- <include name="**/CMakeLists.txt" />
- </fileset>
- </copy>
-
- <copy todir="${dist}/examples/helloworld" overwrite="true" >
- <fileset dir="${dist-src}" />
- </copy>
- </target>
-
- <target name="debug" depends="dist-src,init-debug,test" />
- <target name="release" depends="dist-src,init-release,test" />
-
- <!-- clean -->
- <target name="clean" >
- <delete dir="${target}" quiet="true" />
- <delete dir="${src}/main/csharp/HelloWorldClientProj/bin" quiet="true" />
- <delete dir="${src}/main/csharp/HelloWorldClientProj/obj" quiet="true" />
- <delete dir="${src}/main/csharp/HelloWorldListenerProj/bin" quiet="true" />
- <delete dir="${src}/main/csharp/HelloWorldListenerProj/obj" quiet="true" />
- <delete dir="${src}/test/csharp/HelloWorldTestProj/bin" quiet="true" />
- <delete dir="${src}/test/csharp/HelloWorldTestProj/obj" quiet="true" />
- </target>
-</project>
+
+ <copy todir="${dist-src}/src/main/etch" overwrite="true" >
+ <fileset dir="${src}/main/etch" >
+ <exclude name="**/.svn/**" />
+ <include name="**/*.etch" />
+ </fileset>
+ </copy>
+
+ <copy todir="${dist-src}/src/main/java" overwrite="true" >
+ <fileset dir="${src}/main/java" >
+ <exclude name="**/.svn/**" />
+ <include name="**/*.java" />
+ </fileset>
+ </copy>
+
+ <copy todir="${dist-src}/src/main/csharp" overwrite="true" >
+ <fileset dir="${src}/main/csharp" >
+ <exclude name="**/.svn/**" />
+ <include name="**/*.cs" />
+ </fileset>
+ </copy>
+
+ <copy todir="${dist-src}/src/main/c" overwrite="true" >
+ <fileset dir="${src}/main/c" >
+ <exclude name="**/.svn/**" />
+ <include name="**/*.c" />
+ <include name="**/*.h" />
+ <include name="**/CMakeLists.txt" />
+ </fileset>
+ </copy>
+
+ <copy todir="${dist}/examples/helloworld" overwrite="true" >
+ <fileset dir="${dist-src}" />
+ </copy>
+ </target>
+
+ <target name="debug" depends="dist-src,init-debug,test" />
+ <target name="release" depends="dist-src,init-release,test" />
+
+ <!-- clean -->
+ <target name="clean" >
+ <delete dir="${target}" quiet="true" />
+ <delete dir="${src}/main/csharp/HelloWorldClientProj/bin" quiet="true" />
+ <delete dir="${src}/main/csharp/HelloWorldClientProj/obj" quiet="true" />
+ <delete dir="${src}/main/csharp/HelloWorldListenerProj/bin" quiet="true" />
+ <delete dir="${src}/main/csharp/HelloWorldListenerProj/obj" quiet="true" />
+ <delete dir="${src}/test/csharp/HelloWorldTestProj/bin" quiet="true" />
+ <delete dir="${src}/test/csharp/HelloWorldTestProj/obj" quiet="true" />
+ </target>
+</project>
Modified: incubator/etch/trunk/examples/helloworld/dist-build.xml
URL: http://svn.apache.org/viewvc/incubator/etch/trunk/examples/helloworld/dist-build.xml?rev=1230611&r1=1230610&r2=1230611&view=diff
==============================================================================
--- incubator/etch/trunk/examples/helloworld/dist-build.xml (original)
+++ incubator/etch/trunk/examples/helloworld/dist-build.xml Thu Jan 12 16:10:54 2012
@@ -1,193 +1,193 @@
-<?xml version="1.0" encoding="utf-8"?>
- <!--
- * Licensed to the Apache Software Foundation (ASF) under one *
- * or more contributor license agreements. See the NOTICE file *
- * distributed with this work for additional information *
- * regarding copyright ownership. The ASF licenses this file *
- * to you under the Apache License, Version 2.0 (the *
- * "License"); you may not use this file except in compliance *
- * with the License. You may obtain a copy of the License at *
- * *
- * http://www.apache.org/licenses/LICENSE-2.0 *
- * *
- * Unless required by applicable law or agreed to in writing, *
- * software distributed under the License is distributed on an *
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY *
- * KIND, either express or implied. See the License for the *
- * specific language governing permissions and limitations *
- * under the License. *
- -->
-<project name="etch-HelloWorld-example" basedir="." default="build">
- <description>HelloWorld Example</description>
-
- <property name="etch.home" location="${basedir}/../.."/>
- <property name="etch.version" value="@EtchVersion@"/>
- <property name="etch.longversion" value="@EtchLongVersion@"/>
- <!-- todo clean up variables etch-java-runtime.jar, etch-csharp-runtime.dll -->
- <property name="etch-java-runtime-name" value="apache-etch-java-runtime-${etch.longversion}.jar"/>
- <property name="etch-csharp-runtime-name" value="ApacheEtchCsharpIncubating.dll"/>
-
- <property name="etch-ant-plugin.jar" location="${etch.home}/lib/apache-etch-ant-plugin-${etch.longversion}.jar"/>
- <property name="etch-java-runtime.jar" location="${etch.home}/binding-java/lib/${etch-java-runtime-name}"/>
- <property name="etch-csharp-runtime.dll" location="${etch.home}/binding-csharp/lib/${etch-csharp-runtime-name}"/>
-
- <property name="src" location="${basedir}/src"/>
- <property name="src-main-etch" location="${src}/main/etch"/>
- <property name="src-main-java" location="${src}/main/java"/>
- <property name="src-main-csharp" location="${src}/main/csharp"/>
- <property name="target" location="${basedir}/target"/>
- <property name="generated-sources" location="${target}/generated-sources"/>
- <property name="gensrc-main-etch-java" location="${generated-sources}/main/etch/java"/>
- <property name="gensrc-main-etch-csharp" location="${generated-sources}/main/etch/csharp"/>
- <property name="gensrc-main-etch-c" location="${generated-sources}/main/etch/c"/>
- <property name="classes" location="${target}/classes"/>
- <property name="bin" location="${target}/bin"/>
-
- <condition property="BUILD.csharp" >
- <os family="windows" />
- </condition>
-
- <taskdef resource="org/apache/etch/tools/ant/etch.xml" classpath="${etch-ant-plugin.jar}"/>
+<?xml version="1.0" encoding="utf-8"?>
+ <!--
+ * Licensed to the Apache Software Foundation (ASF) under one *
+ * or more contributor license agreements. See the NOTICE file *
+ * distributed with this work for additional information *
+ * regarding copyright ownership. The ASF licenses this file *
+ * to you under the Apache License, Version 2.0 (the *
+ * "License"); you may not use this file except in compliance *
+ * with the License. You may obtain a copy of the License at *
+ * *
+ * http://www.apache.org/licenses/LICENSE-2.0 *
+ * *
+ * Unless required by applicable law or agreed to in writing, *
+ * software distributed under the License is distributed on an *
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY *
+ * KIND, either express or implied. See the License for the *
+ * specific language governing permissions and limitations *
+ * under the License. *
+ -->
+<project name="etch-HelloWorld-example" basedir="." default="build">
+ <description>HelloWorld Example</description>
+
+ <property name="etch.home" location="${basedir}/../.."/>
+ <property name="etch.version" value="@EtchVersion@"/>
+ <property name="etch.longversion" value="@EtchLongVersion@"/>
+ <!-- todo clean up variables etch-java-runtime.jar, etch-csharp-runtime.dll -->
+ <property name="etch-java-runtime-name" value="apache-etch-java-runtime-${etch.longversion}.jar"/>
+ <property name="etch-csharp-runtime-name" value="ApacheEtchCsharpIncubating.dll"/>
+
+ <property name="etch-ant-plugin.jar" location="${etch.home}/lib/apache-etch-ant-plugin-${etch.longversion}.jar"/>
+ <property name="etch-java-runtime.jar" location="${etch.home}/binding-java/lib/${etch-java-runtime-name}"/>
+ <property name="etch-csharp-runtime.dll" location="${etch.home}/binding-csharp/lib/${etch-csharp-runtime-name}"/>
+
+ <property name="src" location="${basedir}/src"/>
+ <property name="src-main-etch" location="${src}/main/etch"/>
+ <property name="src-main-java" location="${src}/main/java"/>
+ <property name="src-main-csharp" location="${src}/main/csharp"/>
+ <property name="target" location="${basedir}/target"/>
+ <property name="generated-sources" location="${target}/generated-sources"/>
+ <property name="gensrc-main-etch-java" location="${generated-sources}/main/etch/java"/>
+ <property name="gensrc-main-etch-csharp" location="${generated-sources}/main/etch/csharp"/>
+ <property name="gensrc-main-etch-c" location="${generated-sources}/main/etch/c"/>
+ <property name="classes" location="${target}/classes"/>
+ <property name="bin" location="${target}/bin"/>
+
+ <condition property="BUILD.csharp" >
+ <os family="windows" />
+ </condition>
+
+ <taskdef resource="org/apache/etch/tools/ant/etch.xml" classpath="${etch-ant-plugin.jar}"/>
<taskdef resource="org/apache/ant/dotnet/antlib.xml" classpath="${etch.home}/lib/ant-dotnet-1.1.jar" />
-
- <target name="build" depends="build-java, build-csharp, build-c, done"/>
-
- <target name="build-java" depends="gensrc-java">
- <javac destdir="${classes}" source="1.5" debug="true">
- <classpath>
- <pathelement location="${etch-java-runtime.jar}"/>
- </classpath>
- <src path="${src-main-java}"/>
- <src path="${gensrc-main-etch-java}"/>
- </javac>
-
- <jar jarfile="${bin}/helloworld.jar">
- <manifest>
- <attribute name="Class-Path" value="${etch-java-runtime-name}"/>
- </manifest>
- <fileset dir="${classes}"/>
- </jar>
-
- <copy todir="${bin}" file="${etch-java-runtime.jar}"/>
- </target>
-
- <target name="done">
- <echo>
-
-To run java HelloWorld example, open a cmd window and run these
-commands:
-
-> cd target\bin
-> start java -cp helloworld.jar org.apache.etch.examples.helloworld.MainHelloWorldListener
-> start java -cp helloworld.jar org.apache.etch.examples.helloworld.MainHelloWorldClient
-
-To run csharp example:
-
-> cd target\bin
-> start HelloWorldListener.exe
-> start HelloWorldClient.exe
-
-To run the c example:
-> first build using cmake (see below)
-
-You have to set the following variable in CMake:
-- ETCH_HOME must point to your Etch directory (this is were you installed Etch, or target/Installers/dist if building from trunk)
-
-on the shell, you could do this using:
-
-cd examples/helloworld/target
-cmake .. -DETCH_HOME:string=[YOUR ETCH INSTALLATION DIR]
-make (or open visual studio on win32...)
-
-You also have to set the following environment variable:
-- APR_ICONV_PATH to [YOUR ETCH INSTALLATION DIR]/binding-c/extern/apr/iconv/
-
-To run c example:
-
-> cd target\bin
-> start helloworld-server.exe
-> start helloworld-client.exe
-
-
-You can mix and match the various clients and listeners.
-
- </echo>
- </target>
-
- <target name="build-csharp" depends="gensrc-csharp" if="BUILD.csharp" >
- <csc
- debug="true"
- warnLevel="1"
- unsafe="false"
- targetType="exe"
- incremental="false"
- mainClass = "org.apache.etch.examples.helloworld.MainHelloWorldClient"
- destFile="${bin}/HelloWorldClient.exe">
- <src dir="${src-main-csharp}/HelloWorldClientProj" includes="**/*.cs"/>
- <src dir="${src-main-csharp}/org.apache.etch.examples.helloworld" includes="**/*.cs"/>
- <src dir="${gensrc-main-etch-csharp}" includes="**/*.cs"/>
- <reference file="${etch-csharp-runtime.dll}"/>
- </csc>
-
- <csc
- debug="true"
- warnLevel="1"
- unsafe="false"
- targetType="exe"
- incremental="false"
- mainClass = "org.apache.etch.examples.helloworld.MainHelloWorldListener"
- destFile="${bin}/HelloWorldListener.exe">
- <src dir="${src-main-csharp}/HelloWorldListenerProj" includes="**/*.cs"/>
- <src dir="${src-main-csharp}/org.apache.etch.examples.helloworld" includes="**/*.cs"/>
- <src dir="${gensrc-main-etch-csharp}" includes="**/*.cs"/>
- <reference file="${etch-csharp-runtime.dll}"/>
- </csc>
-
- <copy todir="${bin}" file="${etch-csharp-runtime.dll}"/>
- </target>
-
- <target name="build-c" depends="gensrc-c">
- <echo message="c binding sources can be built with cmake!"/>
- </target>
-
- <target name="gensrc-java" depends="init">
- <etch
- home="${etch.home}"
- binding="java"
- quiet="true"
- outputDir="${gensrc-main-etch-java}"
- file="${src-main-etch}/HelloWorld.etch"/>
- </target>
-
- <target name="gensrc-csharp" depends="init">
- <etch
- home="${etch.home}"
- binding="csharp"
- quiet="true"
- outputDir="${gensrc-main-etch-csharp}"
- file="${src-main-etch}/HelloWorld.etch"/>
- </target>
-
- <target name="gensrc-c" depends="init">
- <etch
- home="${etch.home}"
- binding="c"
- quiet="true"
- outputDir="${gensrc-main-etch-c}"
- file="${src-main-etch}/HelloWorld.etch"/>
- </target>
-
- <target name="init">
- <mkdir dir="${target}"/>
- <mkdir dir="${generated-sources}"/>
- <mkdir dir="${gensrc-main-etch-java}"/>
- <mkdir dir="${gensrc-main-etch-csharp}"/>
- <mkdir dir="${gensrc-main-etch-c}"/>
- <mkdir dir="${classes}"/>
- <mkdir dir="${bin}"/>
- </target>
-
- <target name="clean">
- <delete dir="${target}"/>
- </target>
-</project>
+
+ <target name="build" depends="build-java, build-csharp, build-c, done"/>
+
+ <target name="build-java" depends="gensrc-java">
+ <javac destdir="${classes}" source="1.5" debug="true">
+ <classpath>
+ <pathelement location="${etch-java-runtime.jar}"/>
+ </classpath>
+ <src path="${src-main-java}"/>
+ <src path="${gensrc-main-etch-java}"/>
+ </javac>
+
+ <jar jarfile="${bin}/helloworld.jar">
+ <manifest>
+ <attribute name="Class-Path" value="${etch-java-runtime-name}"/>
+ </manifest>
+ <fileset dir="${classes}"/>
+ </jar>
+
+ <copy todir="${bin}" file="${etch-java-runtime.jar}"/>
+ </target>
+
+ <target name="done">
+ <echo>
+
+To run java HelloWorld example, open a cmd window and run these
+commands:
+
+> cd target\bin
+> start java -cp helloworld.jar org.apache.etch.examples.helloworld.MainHelloWorldListener
+> start java -cp helloworld.jar org.apache.etch.examples.helloworld.MainHelloWorldClient
+
+To run csharp example:
+
+> cd target\bin
+> start HelloWorldListener.exe
+> start HelloWorldClient.exe
+
+To run the c example:
+> first build using cmake (see below)
+
+You have to set the following variable in CMake:
+- ETCH_HOME must point to your Etch directory (this is were you installed Etch, or target/Installers/dist if building from trunk)
+
+on the shell, you could do this using:
+
+cd examples/helloworld/target
+cmake .. -DETCH_HOME:string=[YOUR ETCH INSTALLATION DIR]
+make (or open visual studio on win32...)
+
+You also have to set the following environment variable:
+- APR_ICONV_PATH to [YOUR ETCH INSTALLATION DIR]/binding-c/extern/apr/iconv/
+
+To run c example:
+
+> cd target\bin
+> start helloworld-server.exe
+> start helloworld-client.exe
+
+
+You can mix and match the various clients and listeners.
+
+ </echo>
+ </target>
+
+ <target name="build-csharp" depends="gensrc-csharp" if="BUILD.csharp" >
+ <csc
+ debug="true"
+ warnLevel="1"
+ unsafe="false"
+ targetType="exe"
+ incremental="false"
+ mainClass = "org.apache.etch.examples.helloworld.MainHelloWorldClient"
+ destFile="${bin}/HelloWorldClient.exe">
+ <src dir="${src-main-csharp}/HelloWorldClientProj" includes="**/*.cs"/>
+ <src dir="${src-main-csharp}/org.apache.etch.examples.helloworld" includes="**/*.cs"/>
+ <src dir="${gensrc-main-etch-csharp}" includes="**/*.cs"/>
+ <reference file="${etch-csharp-runtime.dll}"/>
+ </csc>
+
+ <csc
+ debug="true"
+ warnLevel="1"
+ unsafe="false"
+ targetType="exe"
+ incremental="false"
+ mainClass = "org.apache.etch.examples.helloworld.MainHelloWorldListener"
+ destFile="${bin}/HelloWorldListener.exe">
+ <src dir="${src-main-csharp}/HelloWorldListenerProj" includes="**/*.cs"/>
+ <src dir="${src-main-csharp}/org.apache.etch.examples.helloworld" includes="**/*.cs"/>
+ <src dir="${gensrc-main-etch-csharp}" includes="**/*.cs"/>
+ <reference file="${etch-csharp-runtime.dll}"/>
+ </csc>
+
+ <copy todir="${bin}" file="${etch-csharp-runtime.dll}"/>
+ </target>
+
+ <target name="build-c" depends="gensrc-c">
+ <echo message="c binding sources can be built with cmake!"/>
+ </target>
+
+ <target name="gensrc-java" depends="init">
+ <etch
+ home="${etch.home}"
+ binding="java"
+ quiet="true"
+ outputDir="${gensrc-main-etch-java}"
+ file="${src-main-etch}/HelloWorld.etch"/>
+ </target>
+
+ <target name="gensrc-csharp" depends="init">
+ <etch
+ home="${etch.home}"
+ binding="csharp"
+ quiet="true"
+ outputDir="${gensrc-main-etch-csharp}"
+ file="${src-main-etch}/HelloWorld.etch"/>
+ </target>
+
+ <target name="gensrc-c" depends="init">
+ <etch
+ home="${etch.home}"
+ binding="c"
+ quiet="true"
+ outputDir="${gensrc-main-etch-c}"
+ file="${src-main-etch}/HelloWorld.etch"/>
+ </target>
+
+ <target name="init">
+ <mkdir dir="${target}"/>
+ <mkdir dir="${generated-sources}"/>
+ <mkdir dir="${gensrc-main-etch-java}"/>
+ <mkdir dir="${gensrc-main-etch-csharp}"/>
+ <mkdir dir="${gensrc-main-etch-c}"/>
+ <mkdir dir="${classes}"/>
+ <mkdir dir="${bin}"/>
+ </target>
+
+ <target name="clean">
+ <delete dir="${target}"/>
+ </target>
+</project>