pom.xml 4.03 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
<?xml version="1.0" encoding="UTF-8"?>
<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>
    <groupId>ml.dmlc.tvm</groupId>
    <artifactId>tvm4j-parent</artifactId>
    <version>0.0.1-SNAPSHOT</version>
    <relativePath>../pom.xml</relativePath>
  </parent>

  <groupId>ml.dmlc.tvm</groupId>
  <artifactId>tvm4j-core</artifactId>
  <version>0.0.1-SNAPSHOT</version>
  <name>TVM4J Package - Core</name>

  <profiles>
    <profile>
20
      <id>osx-x86_64</id>
21
      <properties>
22
        <platform>osx-x86_64</platform>
Yizhi Liu committed
23
        <libtvm.so.filename>libtvm_runtime.dylib</libtvm.so.filename>
24 25 26
      </properties>
    </profile>
    <profile>
27
      <id>linux-x86_64</id>
28
      <properties>
29
        <platform>linux-x86_64</platform>
Yizhi Liu committed
30
        <libtvm.so.filename>libtvm_runtime.so</libtvm.so.filename>
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
      </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>
            <version>6.12</version>
          </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>
77
      <plugin>
78 79 80 81 82 83 84 85 86
        <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
87
            -Dlibtvm.so.path=${project.parent.basedir}/../build/${libtvm.so.filename}
88
            -Dlog4j.configuration=file://${project.parent.basedir}/conf/log4j.properties
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
          </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>
116 117 118 119 120 121 122 123 124 125 126 127
    <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>
128 129
  </dependencies>
</project>