Statistics
| Revision:

gvsig-tools / org.gvsig.maven.base / trunk / org.gvsig.maven.base / org.gvsig.maven.base.extension.pom / pom.xml @ 681

History | View | Annotate | Download (16.1 KB)

1
<?xml version="1.0" encoding="ISO-8859-1"?>
2

    
3
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
4

    
5
    <modelVersion>4.0.0</modelVersion>
6
    <artifactId>org.gvsig.maven.base.extension.pom</artifactId>
7
    <packaging>pom</packaging>
8
    <name>org.gvsig.maven.base.extension.pom</name>
9
    <description> Base POM for all GvSIG extension projects. This pom knows
10
                how to build and made an extension for GvSIG. The property
11
                "build-dir" must be set up correctly.</description>
12

    
13
    <parent>
14
        <groupId>org.gvsig</groupId>
15
        <artifactId>org.gvsig.maven.base.pom</artifactId>
16
        <version>1.0.8-SNAPSHOT</version>
17
    </parent>
18

    
19
    <properties>
20
        <!-- Name of the folder where andami looks for plugins -->
21
        <extensions.dir.name>gvSIG/extensiones</extensions.dir.name>
22
        <!-- Name of the folder where andami can find the plugin for the 
23
            current extension -->
24
        <extension.install.dir.name>${extensions.dir.name}/${project.artifactId}</extension.install.dir.name>
25
        <!-- Name of the folder where andami can find the plugin for the 
26
            appgvSIG extensions -->
27
        <gvsig.extension.install.dir.name>${extensions.dir.name}/org.gvsig.app/</gvsig.extension.install.dir.name>
28

    
29
        <!-- Absolute gvSIG extensions installation folder -->
30
        <gvsig.extensions.dir>${gvsig.install.dir}/${extensions.dir.name}</gvsig.extensions.dir>
31
        <!-- Absolute current extension installation folder into gvSIG -->
32
        <extension.install.dir>${gvsig.install.dir}/${extension.install.dir.name}</extension.install.dir>
33
        <!-- Maven assembly plugin configuration file for the current extension, 
34
            relative to the extension folder. -->
35
        <extension.distribution.file>
36
            distribution/distribution.xml
37
                </extension.distribution.file>
38
        <!-- Extension installation library dependencies folder -->
39
        <library-dir>lib</library-dir>
40
        <!-- Package info property values -->
41
        <package.info.state>devel</package.info.state>
42
        <package.info.official>true</package.info.official>
43
        <package.info.operatingSystem>all</package.info.operatingSystem>
44
        <package.info.architecture>all</package.info.architecture>
45
        <package.info.javaVM>j1_5</package.info.javaVM>
46
        <package.info.gvSIGVersion>2.0.0</package.info.gvSIGVersion>
47
        <package.info.baseDownloadURL>../../pool/${pom.artifactId}</package.info.baseDownloadURL>
48
        <package.info.dependencies></package.info.dependencies>
49
        <package.info.owner>gvSIG Association</package.info.owner>
50
        <package.info.sourcesURL>${project.scm.url}</package.info.sourcesURL>
51
        <package.info.webURL>http://www.gvsig.com</package.info.webURL>
52
        <package.info.categories></package.info.categories>
53
    </properties>
54

    
55
    <profiles>
56
        <profile>
57
            <id>install-extension</id>
58
            <activation>
59
                <activeByDefault>true</activeByDefault>
60
                <property>
61
                    <name>install-extension</name>
62
                </property>
63
            </activation>
64
            <build>
65
                <plugins>
66
                    <!-- This plugin configuration is duplicated in the create-installer 
67
                        profile, because of ordering issues, as it must be run before the org.gvsig.installer.maven 
68
                        plugin -->
69
                    <plugin>
70
                        <artifactId>maven-assembly-plugin
71
                                                </artifactId>
72
                        <configuration>
73
                            <descriptors>
74
                                <descriptor>${extension.distribution.file}</descriptor>
75
                            </descriptors>
76
                            <ignoreDirFormatExtensions>true</ignoreDirFormatExtensions>
77
                            <appendAssemblyId>true</appendAssemblyId>
78
                        </configuration>
79
                        <executions>
80
                            <execution>
81
                                <id>make-assembly</id><!-- this is used for 
82
                                    inheritance merges -->
83
                                <phase>install</phase><!-- append to the 
84
                                    packaging phase. -->
85
                                <goals>
86
                                    <goal>attached</goal>
87
                                </goals>
88
                            </execution>
89
                        </executions>
90
                    </plugin>
91
                    <!-- This plugin configuration is duplicated in the create-installer 
92
                        profile, because of ordering issues, as it must be run before the org.gvsig.installer.maven 
93
                        plugin -->
94
                    <plugin>
95
                        <artifactId>maven-antrun-plugin</artifactId>
96
                        <executions>
97
                            <execution>
98
                                <id>copy-to-andami</id>
99
                                <phase>install</phase>
100
                                <configuration>
101
                                    <tasks>
102
                                        <property name="project.packaging" value="${project.packaging}" />
103
                                        <property name="gvsig.install.dir" value="${gvsig.install.dir}" />
104
                                        <property name="distribution-final-name" value="${project.build.finalName}" />
105
                                        <ant antfile="${base.tools.path}/ant/gvsig-extension-tasks.xml" target="make-extension-new" inheritRefs="true" />
106
                                    </tasks>
107
                                </configuration>
108
                                <goals>
109
                                    <goal>run</goal>
110
                                </goals>
111
                            </execution>
112
                        </executions>
113
                    </plugin>
114
                    <plugin>
115
                        <artifactId>maven-clean-plugin</artifactId>
116
                        <configuration>
117
                            <filesets>
118
                                <fileset>
119
                                    <directory>${extension.install.dir}</directory>
120
                                    <includes>
121
                                        <include>**</include>
122
                                    </includes>
123
                                </fileset>
124
                            </filesets>
125
                        </configuration>
126
                    </plugin>
127
                    <plugin>
128
                        <groupId>org.codehaus.mojo</groupId>
129
                        <artifactId>properties-maven-plugin</artifactId>
130
                        <version>1.0-alpha-2</version>
131
                        <executions>
132
                            <execution>
133
                                <phase>initialize</phase>
134
                                <goals>
135
                                    <goal>read-project-properties</goal>
136
                                </goals>
137
                                <configuration>
138
                                    <files>
139
                                        <file>buildNumber.properties</file>
140
                                    </files>
141
                                </configuration>
142
                            </execution>
143
                        </executions>
144
                    </plugin>
145
                    <!-- Create the package.info file for the plugin and 
146
                        installer info in the compile phase. -->
147
                    <plugin>
148
                        <groupId>org.gvsig</groupId>
149
                        <artifactId>org.gvsig.installer.maven</artifactId>
150
                        <configuration>
151
                            <pluginsFolder>${gvsig.install.dir}/gvSIG/extensiones</pluginsFolder>
152
                            <packageFolder>${gvsig.install.dir}/install/pool/${project.artifactId}</packageFolder>
153
                            <buildNumber>${buildNumber}</buildNumber>
154
                            <state>${package.info.state}</state>
155
                            <official>${package.info.official}</official>
156
                            <operatingSystem>${package.info.operatingSystem}</operatingSystem>
157
                            <architecture>${package.info.architecture}</architecture>
158
                            <javaVM>${package.info.javaVM}</javaVM>
159
                            <gvSIGVersion>${package.info.gvSIGVersion}</gvSIGVersion>
160
                            <baseDownloadURL>${package.info.baseDownloadURL}</baseDownloadURL>
161
                            <pkgdependencies>${package.info.dependencies}</pkgdependencies>
162
                            <owner>${package.info.owner}</owner>
163
                            <sourcesURL>${package.info.sourcesURL}</sourcesURL>
164
                            <webURL>${package.info.webURL}</webURL>
165
                            <categories>${package.info.categories}</categories>
166
                        </configuration>
167
                        <executions>
168
                            <execution>
169
                                <id>write-info</id>
170
                                <phase>compile</phase>
171
                                <goals>
172
                                    <goal>write-info</goal>
173
                                </goals>
174
                            </execution>
175
                        </executions>
176
                    </plugin>
177
                </plugins>
178
            </build>
179
        </profile>
180
        <profile>
181
            <id>create-installer</id>
182
            <build>
183
                <plugins>
184
                    <plugin>
185
                        <groupId>org.codehaus.mojo</groupId>
186
                        <artifactId>buildnumber-maven-plugin</artifactId>
187
                        <version>1.0-beta-2</version>
188
                        <executions>
189
                            <execution>
190
                                <phase>validate</phase>
191
                                <goals>
192
                                    <goal>create</goal>
193
                                </goals>
194
                            </execution>
195
                        </executions>
196
                        <configuration>
197
                            <format>{0,number,#}</format>
198
                            <items>
199
                                <item>buildNumber</item>
200
                            </items>
201
                            <doCheck>false</doCheck>
202
                            <doUpdate>false</doUpdate>
203
                        </configuration>
204
                    </plugin>
205
                    <!-- This plugin configuration is duplicated in the install-extension 
206
                        profile, because of ordering issues, as it must be run before the org.gvsig.installer.maven 
207
                        plugin -->
208
                    <plugin>
209
                        <artifactId>maven-assembly-plugin
210
                        </artifactId>
211
                        <configuration>
212
                            <descriptors>
213
                                <descriptor>${extension.distribution.file}</descriptor>
214
                            </descriptors>
215
                            <ignoreDirFormatExtensions>true</ignoreDirFormatExtensions>
216
                            <appendAssemblyId>true</appendAssemblyId>
217
                        </configuration>
218
                        <executions>
219
                            <execution>
220
                                <id>make-assembly</id><!-- this is used for 
221
                                    inheritance merges -->
222
                                <phase>install</phase><!-- append to the 
223
                                    packaging phase. -->
224
                                <goals>
225
                                    <goal>attached</goal>
226
                                </goals>
227
                            </execution>
228
                        </executions>
229
                    </plugin>
230
                    <!-- This plugin configuration is duplicated in the install-extension 
231
                        profile, because of ordering issues, as it must be run before the org.gvsig.installer.maven 
232
                        plugin -->
233
                    <plugin>
234
                        <artifactId>maven-antrun-plugin</artifactId>
235
                        <executions>
236
                            <execution>
237
                                <id>copy-to-andami</id>
238
                                <phase>install</phase>
239
                                <configuration>
240
                                    <tasks>
241
                                        <property name="project.packaging" value="${project.packaging}" />
242
                                        <property name="gvsig.install.dir" value="${gvsig.install.dir}" />
243
                                        <property name="distribution-final-name" value="${project.build.finalName}" />
244
                                        <ant antfile="${base.tools.path}/ant/gvsig-extension-tasks.xml" target="make-extension-new" inheritRefs="true" />
245
                                    </tasks>
246
                                </configuration>
247
                                <goals>
248
                                    <goal>run</goal>
249
                                </goals>
250
                            </execution>
251
                        </executions>
252
                    </plugin>
253
                    <!-- Create the package.info file for the plugin and 
254
                        installer info in the compile phase, and create the plugin installer in the 
255
                        install phase. -->
256
                    <plugin>
257
                        <groupId>org.gvsig</groupId>
258
                        <artifactId>org.gvsig.installer.maven</artifactId>
259
                        <configuration>
260
                            <pluginsFolder>${gvsig.install.dir}/gvSIG/extensiones</pluginsFolder>
261
                            <packageFolder>${gvsig.install.dir}/install/pool/${project.artifactId}</packageFolder>
262
                            <buildNumber>${buildNumber}</buildNumber>
263
                            <state>${package.info.state}</state>
264
                            <official>${package.info.official}</official>
265
                            <operatingSystem>${package.info.operatingSystem}</operatingSystem>
266
                            <architecture>${package.info.architecture}</architecture>
267
                            <javaVM>${package.info.javaVM}</javaVM>
268
                            <gvSIGVersion>${package.info.gvSIGVersion}</gvSIGVersion>
269
                            <baseDownloadURL>${package.info.baseDownloadURL}</baseDownloadURL>
270
                            <pkgdependencies>${package.info.dependencies}</pkgdependencies>
271
                            <owner>${package.info.owner}</owner>
272
                            <sourcesURL>${package.info.sourcesURL}</sourcesURL>
273
                            <webURL>${package.info.webURL}</webURL>
274
                        </configuration>
275
                        <executions>
276
                            <execution>
277
                                <id>write-info</id>
278
                                <phase>compile</phase>
279
                                <goals>
280
                                    <goal>write-info</goal>
281
                                </goals>
282
                            </execution>
283
                            <execution>
284
                                <id>create-plugin-package</id>
285
                                <phase>install</phase>
286
                                <goals>
287
                                    <goal>create-package</goal>
288
                                </goals>
289
                            </execution>
290
                            <execution>
291
                                <id>create-plugin-package-index</id>
292
                                <phase>install</phase>
293
                                <goals>
294
                                    <goal>create-package-index</goal>
295
                                </goals>
296
                            </execution>
297
                        </executions>
298
                    </plugin>
299
                </plugins>
300
            </build>
301
        </profile>
302
    </profiles>
303
</project>