blob: 12c7c76db8dc3b39ba16ac073b84c604ae737c0c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
|
<!--
* 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="scatours-binaries" default="compile">
<property environment="env"/>
<fail unless="env.TUSCANY_HOME">
Error: Please set the TUSCANY_HOME environment variable.
</fail>
<target name="check-lib-dir">
<!-- check whether there is a lib directory (it only exists when building the distribution) -->
<condition property="lib-dir">
<available file="../../lib" type="dir"/>
</condition>
</target>
<target name="no-lib-dir" unless="lib-dir">
<echo>The ant build for "binaries" only produces output when building from the distribution.</echo>
</target>
<target name="compile" depends="check-lib-dir, no-lib-dir" if="lib-dir">
<!-- copy jars and build.xml to target/clients -->
<mkdir dir="target/clients"/>
<copy todir="target/clients" flatten="true">
<fileset dir="../clients">
<include name="**/scatours-client-*.jar"/>
</fileset>
</copy>
<copy file="src/main/resources/build-clients.xml" tofile="target/clients/build.xml"/>
<!-- copy jars and files to target/contributions -->
<mkdir dir="target/contributions"/>
<copy todir="target/contributions" flatten="true">
<fileset dir="../contributions">
<include name="**/target/scatours-contribution-*.jar"/>
<exclude name="**/target/scatours-contribution-payment-bpel-process.jar"/>
</fileset>
</copy>
<mkdir dir="target/contributions/scatours-contribution-payment-bpel-process"/>
<unzip dest="target/contributions/scatours-contribution-payment-bpel-process">
<fileset dir="../contributions">
<include name="**/target/scatours-contribution-payment-bpel-process.jar"/>
</fileset>
</unzip>
<!-- copy files to target/domainconfig -->
<mkdir dir="target/domainconfig"/>
<unzip dest="target/domainconfig">
<fileset dir="../domainconfig">
<include name="**/scatours-domainconfig-*.jar"/>
</fileset>
<patternset>
<exclude name="META-INF"/>
<exclude name="META-INF/**/*"/>
</patternset>
</unzip>
<!-- copy jars to target/jaxws -->
<mkdir dir="target/jaxws"/>
<copy todir="target/jaxws">
<fileset dir="../../lib/jaxws">
<exclude name="jaxws-tools*.jar"/>
</fileset>
</copy>
<!-- copy jars and build.xml to target/launchers -->
<mkdir dir="target/launchers"/>
<copy todir="target/launchers" flatten="true">
<fileset dir="../launchers">
<include name="**/scatours-launcher-*.jar"/>
<exclude name="**/scatours-launcher-jumpstart.jar"/>
</fileset>
</copy>
<copy file="src/main/resources/build-launchers.xml" tofile="target/launchers/build.xml"/>
<!-- copy files to target/ode -->
<mkdir dir="target/ode"/>
<unzip dest="target/ode">
<fileset dir="${env.TUSCANY_HOME}/lib">
<include name="ode-dao-jpa-ojpa-derby*.zip"/>
</fileset>
</unzip>
<!-- copy jars to target/openejb -->
<mkdir dir="target/openejb"/>
<copy todir="target/openejb">
<fileset dir="../../lib/openejb"/>
</copy>
<!-- copy jars and build.xml to target/services -->
<mkdir dir="target/services"/>
<copy todir="target/services" flatten="true">
<fileset dir="../services">
<include name="**/scatours-service-*.jar"/>
</fileset>
</copy>
<copy file="src/main/resources/build-services.xml" tofile="target/services/build.xml"/>
<!-- copy jars and build-defs.xml to target/util -->
<mkdir dir="target/util"/>
<copy todir="target/util" flatten="true">
<fileset dir="../util">
<include name="**/scatours-util-*.jar"/>
</fileset>
<fileset file="src/main/resources/build-defs.xml"/>
</copy>
<!-- copy jars to target/webapps -->
<mkdir dir="target/webapps"/>
<copy todir="target/webapps" flatten="true">
<fileset dir="../contributions">
<include name="**/scatours-contribution-*.war"/>
</fileset>
</copy>
</target>
<target name="clean">
<delete dir="target" includeemptydirs="true"/>
</target>
</project>
|