forked from AlfrescoArchive/alfresco-php-sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.xml
executable file
·177 lines (146 loc) · 6.19 KB
/
build.xml
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
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
<project name="PHP">
<!-- Set base directory property -->
<dirname property="php.base.dir" file="${ant.file.PHP}"/>
<target name="init">
<!-- Set properties -->
<property environment="env" />
<property file="${php.base.dir}/build.properties" />
<!--
<path id="classpath.compile">
<fileset dir="alfresco/war/WEB-INF/lib">
<include name="**/*.jar" />
<exclude name="optional/**" />
</fileset>
</path>
-->
</target>
<!-- Packages the php library -->
<target name="package-php-lib"
depends="init">
<echo>Packaging Alfresco PHP library</echo>
<mkdir dir="${php.dist.dir}" />
<zip destfile="${php.dist.dir}/${php.dist.phplib.name}.zip">
<zipfileset dir="${php.phplib.api.dir}"
prefix="alfresco-php-library"/>
</zip>
<tar destfile="${php.dist.dir}/${php.dist.phplib.name}.tar.gz"
longfile="gnu"
compression="gzip">
<tarfileset dir="${php.phplib.api.dir}"
prefix="alfresco-php-library"/>
</tar>
</target>
<!-- TODO clean up AMP build scripts and dependancies
NOTE: these have been copied from the Alfresco build environment and need to be factored to work in this stand alone environment
<target name="incremental-php"
depends="package-php" />
<target name="build-php"
depends="clean-php, incremental-php" />
<target name="clean-php"
depends="init">
<clean projectdir="${dir.module.php}" />
</target>
<target name="compile-php"
depends="init">
<compile-java projectdir="${dir.module.php}" />
</target>
<target name="package-php"
depends="package-php-war, deploy-webclient-tomcat" />
<target name="package-php-jar"
depends="compile-php">
<mkdir dir="${dir.module.php.dist}" />
<jar jarfile="${dir.module.php.dist}/${file.name.jar.php}"
basedir="${dir.module.php.classes}" />
</target>
<target name="package-php-war"
depends="package-php-extension">
<echo>Installing PHP Integration into WAR...</echo>
<install-amp ampfile="${dir.module.php.dist}/${file.name.amp.php}"
warfile="${dir.project.webclient.dist}/${file.name.war.webclient}" />
</target>
<target name="package-php-extension"
depends="package-php-jar">
<zip destfile="${dir.module.php.dist}/${file.name.amp.php}"
update="true">
<zipfileset file="${dir.module.php.property}/module.properties"/>
<zipfileset file="${dir.module.php.dist}/${file.name.jar.php}"
prefix="lib"/>
<zipfileset dir="${dir.module.php}/${dir.name.lib}"
prefix="lib">
<exclude name="**/source/**"/>
</zipfileset>
<zipfileset dir="${dir.module.php.web.php}/Examples"
prefix="web/php/Examples"/>
<zipfileset dir="${dir.module.php.config}"
prefix="config">
<exclude name="**/module.properties"/>
</zipfileset>
</zip>
</target>
<target name="incremental-mediawiki"
depends="package-mediawiki" />
<target name="build-mediawiki"
depends="clean-mediawiki, incremental-mediawiki" />
<target name="clean-mediawiki"
depends="init">
<clean projectdir="${dir.module.mediawiki}" />
</target>
<target name="compile-mediawiki"
depends="init">
<compile-java projectdir="${dir.module.mediawiki}" />
</target>
<target name="package-mediawiki"
depends="package-mediawiki-war, deploy-webclient-tomcat" />
<target name="package-mediawiki-jar"
depends="compile-mediawiki">
<mkdir dir="${dir.module.mediawiki.dist}" />
<jar jarfile="${dir.module.mediawiki.dist}/${file.name.jar.mediawiki}"
basedir="${dir.module.mediawiki.classes}" />
</target>
<target name="package-mediawiki-war"
depends="package-mediawiki-extension">
<echo>Installing mediawiki integration into WAR...</echo>
<install-amp ampfile="${dir.module.mediawiki.dist}/${file.name.amp.mediawiki}"
warfile="${dir.project.webclient.dist}/${file.name.war.webclient}" />
</target>
<target name="package-mediawiki-extension"
depends="package-mediawiki-jar">
<zip destfile="${dir.module.mediawiki.dist}/${file.name.amp.mediawiki}"
update="true">
<zipfileset file="${dir.module.mediawiki.property}/module.properties"/>
<zipfileset file="${dir.module.mediawiki.dist}/${file.name.jar.mediawiki}"
prefix="lib"/>
<zipfileset dir="${dir.module.mediawiki.config}"
prefix="config">
<exclude name="**/module.properties"/>
</zipfileset>
<zipfileset dir="${dir.module.mediawiki.web.php}/mediawiki"
prefix="web/php/wiki"/>
Copy the extension into the correct place
<zipfileset dir="${dir.module.mediawiki.web.php}/alfresco-integration"
prefix="web/php/wiki/extensions/alfresco-integration">
<exclude name="LocalSettings.php"/>
</zipfileset>
Copy the localSetting.php file into the correct location
<zipfileset file="${dir.module.mediawiki.web.php}/alfresco-integration/LocalSettings.php"
prefix="web/php/wiki"/>
</zip>
</target>
<target name="test-mediawiki"
depends="compile-mediawiki">
<run-tests projectdir="${dir.module.mediawiki}" />
</target>
<target name="generate-javadocs-mediawiki"
depends="init">
<generate-javadocs documenttitle="Alfresco MediaWiki Extension"
windowtitle="MediaWiki Integration"
projectdir="${dir.module.mediawiki}"/>
</target>
<target name="refresh-mediawiki"
depends="init">
<copy todir="${dir.mediawiki}/extensions">
<fileset dir="${dir.module.php.source.remote}/Integration/MediaWiki" includes="*.php"/>
</copy>
</target>
-->
</project>