-
Notifications
You must be signed in to change notification settings - Fork 15
/
pom.xml
292 lines (273 loc) · 10.8 KB
/
pom.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
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
<?xml version="1.0" encoding="UTF-8"?>
<!--
Maven project configuration file
http://maven.apache.org/
For building this project: mvn package
-->
<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">
<modelVersion>4.0.0</modelVersion>
<groupId>org.osgeo</groupId>
<artifactId>proj</artifactId>
<version>2.1-SNAPSHOT</version>
<name>PROJ bindings</name>
<url>https://github.com/OSGeo/PROJ-JNI</url>
<description>
Java Native Interface for the PROJ C/C++ library.
PROJ is a generic coordinate transformation software that transforms
geospatial coordinates from one coordinate reference system (CRS) to another.
This includes cartographic projections as well as geodetic transformations.
This package exposes PROJ services as implementations of GeoAPI interfaces.
Both PROJ and GeoAPI are modeled according the ISO 19111 international standard.
</description>
<organization>
<name>Open Source Geospatial Foundation</name>
<url>https://www.osgeo.org/</url>
</organization>
<licenses>
<license>
<name>MIT</name>
<distribution>repo</distribution>
</license>
</licenses>
<scm>
<connection>scm:git:https://github.com/OSGeo/PROJ-JNI</connection>
<url>https://github.com/OSGeo/PROJ-JNI</url>
</scm>
<developers>
<developer>
<id>kbevers</id>
<name>Kristian Evers</name>
<email>kristianevers@gmail.com</email>
<organization>Open Source Geospatial Foundation</organization>
<organizationUrl>https://www.osgeo.org</organizationUrl>
<roles>
<role>C/C++ developer</role>
</roles>
<timezone>+1</timezone>
</developer>
<developer>
<id>desruisseaux</id>
<name>Martin Desruisseaux</name>
<email>martin.desruisseaux@geomatys.com</email>
<organization>Geomatys</organization>
<organizationUrl>https://www.geomatys.com</organizationUrl>
<roles>
<role>Java developer</role>
</roles>
<timezone>+1</timezone>
</developer>
</developers>
<dependencies>
<dependency>
<groupId>org.opengis</groupId>
<artifactId>geoapi</artifactId>
<version>${geoapi.version}</version>
</dependency>
<dependency>
<groupId>org.opengis</groupId>
<artifactId>geoapi-conformance</artifactId>
<version>${geoapi.version}</version>
<scope>test</scope>
</dependency>
</dependencies>
<!--
Version numbers of main dependencies are specified here.
JSR-385 is inherited as a transitive dependency, so it is not specified here.
Seshat is not used by PROJ-JNI, but copied for convenience because execution
of GIGS tests (for example) requires a JSR-385 implementation. We must ensure
that the Seshat version specified here uses the same JSR-385 version as GeoAPI.
-->
<properties>
<geoapi.version>3.0.2</geoapi.version>
<seshat.version>1.3</seshat.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<build>
<plugins>
<!-- Require Java 11 for compilation. -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>3.4.1</version>
<executions>
<execution>
<id>enforce</id>
<configuration>
<rules>
<requireJavaVersion>
<version>11</version>
</requireJavaVersion>
<dependencyConvergence/>
</rules>
</configuration>
<goals>
<goal>enforce</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- Compilation: target Java 11, enable all warnings. -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.13.0</version>
<configuration>
<release>11</release>
<showWarnings>true</showWarnings>
<showDeprecation>true</showDeprecation>
<useIncrementalCompilation>false</useIncrementalCompilation>
<compilerArgs>
<arg>-h</arg> <arg>${project.build.sourceDirectory}/../cpp</arg>
</compilerArgs>
</configuration>
</plugin>
<!-- Test execution. -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.2.5</version>
<configuration>
<systemPropertyVariables>
<java.util.logging.config.file>${project.basedir}/src/config/logging.properties</java.util.logging.config.file>
</systemPropertyVariables>
<argLine>-Xcheck:jni</argLine>
<trimStackTrace>false</trimStackTrace>
</configuration>
</plugin>
<!-- JAR packaging: add project name and version in MANIFEST.MF file. -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>3.3.0</version>
<configuration>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
<manifest>
<addClasspath>true</addClasspath>
<classpathLayoutType>simple</classpathLayoutType>
<addDefaultImplementationEntries>true</addDefaultImplementationEntries>
</manifest>
<manifestEntries>
<Built-On>${maven.build.timestamp}</Built-On>
<Specification-Title>GeoAPI</Specification-Title>
<Specification-Version>${geoapi.version}</Specification-Version>
<Specification-Vendor>Open Geospatial Consortium</Specification-Vendor>
<Implementation-URL>https://github.com/OSGeo/PROJ-JNI</Implementation-URL>
</manifestEntries>
</archive>
</configuration>
</plugin>
<!-- Use Ant for tasks that we cannot execute with Maven. -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<version>3.1.0</version>
<executions>
<!--
Compile C/C++ code using CMake. Configuration will be written in `target/cmake` and will not
be redone, unless that directory is deleted. The compiled native file will be written in the
`classes/org/…/proj/` directory for inclusion in the JAR file and will not be rebuilt, unless
that file is deleted. Symbolic links to binaries will be created in the `target` directory.
-->
<execution>
<id>build-native</id>
<phase>process-classes</phase>
<goals><goal>run</goal></goals>
<configuration>
<target>
<property name="source.directory" value="${project.basedir}/src/main/cpp"/>
<property name="target.directory" value="${project.build.directory}"/>
<property name= "cmake.subdir" value="cmake"/>
<ant dir="${target.directory}" antfile="${project.basedir}/src/main/cpp/build.xml" inheritAll="true"/>
</target>
</configuration>
</execution>
<!--
"Copy" the native binary among test classes because `Class.getResource(…)` searches in the directory
of `module-info.class`, which is overwritten in `test-classes`. This is needed for running the tests
in a named Jigsaw module (not needed when running as unnamed module).
-->
<execution>
<id>build-tests</id>
<phase>process-test-classes</phase>
<goals><goal>run</goal></goals>
<configuration>
<target>
<first id="native-binary"><fileset dir="${project.build.directory}/classes/org/osgeo/proj" includes="*-binding.*"/></first>
<basename property="native-binary-filename" file="${toString:native-binary}"/>
<symlink overwrite="true" resource="${toString:native-binary}"
link="${project.build.directory}/test-classes/org/osgeo/proj/${native-binary-filename}"/>
</target>
</configuration>
</execution>
</executions>
</plugin>
<!-- Copy dependencies in the output modules directory. -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>3.6.1</version>
<executions>
<execution>
<id>copy-dependencies</id>
<phase>package</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
<outputDirectory>${project.build.directory}</outputDirectory>
<includeScope>compile</includeScope>
</configuration>
</execution>
<!-- Add a JSR-385 implementation for convenience (can be ignored). -->
<execution>
<id>copy</id>
<phase>package</phase>
<goals>
<goal>copy</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<groupId>tech.uom</groupId>
<artifactId>seshat</artifactId>
<version>${seshat.version}</version>
<outputDirectory>${project.build.directory}</outputDirectory>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<!-- JavaDoc configuration. -->
<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.6.3</version>
<configuration>
<excludePackageNames>org.osgeo.proj.spi</excludePackageNames>
<encoding>${project.build.sourceEncoding}</encoding>
<docencoding>${project.build.sourceEncoding}</docencoding>
<charset>${project.build.sourceEncoding}</charset>
<author>false</author>
<version>true</version>
<noqualifier>all</noqualifier>
<quiet>true</quiet>
<keywords>true</keywords>
<breakiterator>true</breakiterator>
<validateLinks>true</validateLinks>
<detectJavaApiLink>false</detectJavaApiLink>
<links>
<link>https://docs.oracle.com/en/java/javase/13/docs/api</link>
<link>https://www.geoapi.org/3.0/javadoc</link>
</links>
<additionalOptions>
<additionalOption>--add-stylesheet "${project.basedir}/src/main/javadoc/customization.css"</additionalOption>
</additionalOptions>
</configuration>
</plugin>
</plugins>
</build>
</project>