-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpom.xml
119 lines (118 loc) · 3.95 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
<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/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>example</groupId>
<artifactId>CMakeMavenProject</artifactId>
<packaging>jar</packaging>
<version>1.0-SNAPSHOT</version>
<name>CMakeMavenProject</name>
<url>http://maven.apache.org</url>
<properties>
<maven.compiler.source>11</maven.compiler.source>
<maven.compiler.target>11</maven.compiler.target>
<maven.test.skip>false</maven.test.skip>
<conan.dependency.directory>${project.build.directory}/conan</conan.dependency.directory>
<build.type>Release</build.type>
<cmake.build.directory>${project.build.directory}/cmake</cmake.build.directory>
</properties>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>com.googlecode.cmake-maven-project</groupId>
<artifactId>cmake-maven-plugin</artifactId>
<version>3.23.2-b1</version>
<configuration>
<!-- use system cmake -->
<downloadBinaries>false</downloadBinaries>
<!-- generate properties -->
<sourcePath>${project.basedir}</sourcePath>
<targetPath>${cmake.build.directory}</targetPath>
<generator>Ninja</generator>
<!-- compile properties -->
<projectDirectory>${cmake.build.directory}</projectDirectory>
<!-- test properties-->
<buildDirectory>${cmake.build.directory}</buildDirectory>
</configuration>
<executions>
<execution>
<?m2e execute onConfiguration?>
<id>cmake-generate</id>
<phase>process-sources</phase>
<goals>
<goal>generate</goal>
</goals>
<configuration>
<options>
<option>-DSKIP_BUILD_TESTS:BOOL=${maven.test.skip}</option>
<option>-DCMAKE_BUILD_TYPE:STRING=${build.type}</option>
</options>
<environmentVariables>
<!-- This environment variable is picked up by conan to force building dependencies with Ninja. -->
<CONAN_CMAKE_GENERATOR>Ninja</CONAN_CMAKE_GENERATOR>
</environmentVariables>
</configuration>
</execution>
<execution>
<?m2e ignore?>
<id>cmake-compile</id>
<phase>compile</phase>
<goals>
<goal>compile</goal>
</goals>
<configuration>
<options>
<option>-v</option>
</options>
</configuration>
</execution>
<execution>
<id>cmake-test</id>
<phase>test</phase>
<goals>
<goal>test</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>com.googlecode.cmake-maven-project</groupId>
<artifactId>cmake-maven-plugin</artifactId>
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>skipTests</id>
<activation>
<property>
<name>skipTests</name>
</property>
</activation>
<properties>
<maven.test.skip>true</maven.test.skip>
</properties>
</profile>
<profile>
<id>debug</id>
<properties>
<build.type>Debug</build.type>
</properties>
</profile>
</profiles>
</project>