pom.xml 4.78 KB
Newer Older
1
<?xml version="1.0" encoding="UTF-8"?>
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21

<!--
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.
-->

22 23 24 25 26
<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>
  <parent>
27
    <groupId>org.apache.tvm</groupId>
28 29 30 31 32
    <artifactId>tvm4j-parent</artifactId>
    <version>0.0.1-SNAPSHOT</version>
    <relativePath>../pom.xml</relativePath>
  </parent>

33
  <groupId>org.apache.tvm</groupId>
34 35 36 37 38 39
  <artifactId>tvm4j-core</artifactId>
  <version>0.0.1-SNAPSHOT</version>
  <name>TVM4J Package - Core</name>

  <profiles>
    <profile>
40
      <id>osx-x86_64</id>
41
      <properties>
42
        <platform>osx-x86_64</platform>
Yizhi Liu committed
43
        <libtvm.so.filename>libtvm_runtime.dylib</libtvm.so.filename>
44 45 46
      </properties>
    </profile>
    <profile>
47
      <id>linux-x86_64</id>
48
      <properties>
49
        <platform>linux-x86_64</platform>
Yizhi Liu committed
50
        <libtvm.so.filename>libtvm_runtime.so</libtvm.so.filename>
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
      </properties>
    </profile>
  </profiles>

  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-jar-plugin</artifactId>
        <configuration>
          <excludes>
            <exclude>META-INF/*.SF</exclude>
            <exclude>META-INF/*.DSA</exclude>
            <exclude>META-INF/*.RSA</exclude>
          </excludes>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-checkstyle-plugin</artifactId>
        <version>2.17</version>
        <dependencies>
          <dependency>
            <groupId>com.puppycrawl.tools</groupId>
            <artifactId>checkstyle</artifactId>
80
            <version>8.18</version>
81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96
          </dependency>
        </dependencies>
        <executions>
          <execution>
            <phase>process-sources</phase>
            <goals>
              <goal>check</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
          <failsOnError>true</failsOnError>
          <configLocation>${project.parent.basedir}/conf/google_checks.xml</configLocation>
          <consoleOutput>true</consoleOutput>
        </configuration>
      </plugin>
97
      <plugin>
98 99 100 101 102 103 104 105 106
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
        <version>2.7</version>
        <configuration>
          <forkCount>1</forkCount>
          <reuseForks>true</reuseForks>
          <threadCount>1</threadCount>
          <argLine>
            -Djava.library.path=${project.parent.basedir}/native/${platform}/target
107
            -Dlibtvm.so.path=${project.parent.basedir}/../build/${libtvm.so.filename}
108
            -Dlog4j.configuration=file://${project.parent.basedir}/conf/log4j.properties
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
          </argLine>
        </configuration>
        <executions>
          <execution>
            <id>test</id>
            <!--
             We put it in the integration-test phase,
             because the test suites require the jni library,
             which means, in order to run the unit tests,
             we have to compile all the modules first.
            -->
            <phase>integration-test</phase>
            <goals>
              <goal>test</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
  <dependencies>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>4.11</version>
      <scope>test</scope>
    </dependency>
136 137 138 139 140 141 142 143 144 145 146 147
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
      <version>1.7.25</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-simple</artifactId>
      <version>1.7.25</version>
      <scope>test</scope>
    </dependency>
148 149
  </dependencies>
</project>