Home | History | Annotate | Download | only in gdx-tools
      1 <?xml version="1.0" encoding="UTF-8"?>
      2 <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">
      3   <modelVersion>4.0.0</modelVersion>
      4   <parent>
      5     <groupId>com.badlogicgames.gdx</groupId>
      6     <artifactId>gdx-parent</artifactId>
      7     <version>1.9.3</version>
      8     <relativePath>../../pom.xml</relativePath>
      9   </parent>
     10 
     11   <artifactId>gdx-tools</artifactId>
     12   <packaging>jar</packaging>
     13   <name>libGDX Tools</name>
     14 
     15   <properties>
     16     <particleClass>com.badlogic.gdx.tools.particleeditor.ParticleEditor</particleClass>
     17   </properties>
     18 
     19   <dependencies>
     20     <dependency>
     21       <groupId>${project.groupId}</groupId>
     22       <artifactId>gdx-backend-lwjgl</artifactId>
     23       <version>${project.version}</version>
     24     </dependency>
     25     
     26     <dependency>
     27       <groupId>${project.groupId}</groupId>
     28       <artifactId>gdx-backend-headless</artifactId>
     29       <version>${project.version}</version>
     30     </dependency>
     31     
     32     <dependency>
     33       <groupId>${project.groupId}</groupId>
     34       <artifactId>gdx-freetype</artifactId>
     35       <version>${project.version}</version>
     36     </dependency>
     37 
     38     <dependency>
     39       <groupId>${project.groupId}</groupId>
     40       <artifactId>gdx-freetype-platform</artifactId>
     41       <version>${project.version}</version>
     42       <classifier>natives-desktop</classifier>
     43     </dependency>
     44 
     45     <dependency>
     46       <groupId>com.badlogicgames.gdx</groupId>
     47       <artifactId>gdx-platform</artifactId>
     48       <version>${project.version}</version>
     49       <classifier>natives-desktop</classifier>
     50       <scope>test</scope>
     51     </dependency>
     52   </dependencies>
     53 
     54   <build>
     55     <sourceDirectory>src</sourceDirectory>
     56     <resources>
     57       <resource>
     58         <directory>assets</directory>
     59       </resource>
     60     </resources>
     61 
     62     <plugins>
     63       <plugin>
     64         <artifactId>maven-assembly-plugin</artifactId>
     65         <version>2.4</version>
     66         <configuration>
     67           <descriptors>
     68             <descriptor>assembly.xml</descriptor>
     69           </descriptors>
     70         </configuration>
     71         <executions>
     72           <execution>
     73             <id>make-assembly</id> <!-- this is used for inheritance merges -->
     74             <phase>package</phase> <!-- bind to the packaging phase -->
     75             <goals>
     76               <goal>single</goal>
     77             </goals>
     78           </execution>
     79         </executions>
     80       </plugin>
     81       <!-- the assembly plugin insists on generating a separate artifact, but we want our main
     82            artifact to have all the bits included; so we sneakily copy the assembled artifact over
     83            the main artifact after the assembly plugin has run -->
     84       <plugin>
     85         <artifactId>maven-antrun-plugin</artifactId>
     86         <version>1.7</version>
     87         <executions>
     88           <execution>
     89             <id>replace-main-artifact</id>
     90             <phase>integration-test</phase>
     91             <configuration>
     92               <target>
     93                 <property name="root" value="${project.artifactId}-${project.version}" />
     94                 <copy file="${project.build.directory}/${root}-distribution.jar" tofile="${project.build.directory}/${root}.jar" />
     95               </target>
     96             </configuration>
     97             <goals>
     98               <goal>run</goal>
     99             </goals>
    100           </execution>
    101         </executions>
    102       </plugin>
    103       <!-- unpack natives when running particle editor -->
    104       <plugin>
    105         <groupId>com.googlecode.mavennatives</groupId>
    106         <artifactId>maven-nativedependencies-plugin</artifactId>
    107         <version>0.0.6</version>
    108         <executions>
    109           <execution>
    110             <id>unpacknatives</id>
    111             <phase>test-compile</phase>
    112             <goals><goal>copy</goal></goals>
    113           </execution>
    114         </executions>
    115       </plugin>
    116       <plugin>
    117             <groupId>org.apache.maven.plugins</groupId>
    118             <artifactId>maven-source-plugin</artifactId>
    119             <executions>
    120                 <execution>
    121                     <id>attach-sources</id>
    122                     <phase>generate-resources</phase>
    123                     <goals>
    124                         <goal>jar-no-fork</goal>
    125                     </goals>
    126                 </execution>
    127             </executions>
    128         </plugin>
    129     </plugins>
    130   </build>
    131 
    132   <profiles>
    133     <!-- allows one to run the particle editor via: mvn test -Pparticles -->
    134     <profile>
    135       <id>particles</id>
    136       <build>
    137         <plugins>
    138           <plugin>
    139             <artifactId>maven-antrun-plugin</artifactId>
    140             <version>1.6</version>
    141             <executions>
    142               <execution>
    143                 <phase>test</phase>
    144                 <configuration>
    145                   <target>
    146                     <java fork="true" classname="${particleClass}" classpathref="maven.test.classpath">
    147                       <sysproperty key="java.library.path" value="target/natives" />
    148                     </java>
    149                   </target>
    150                 </configuration>
    151                 <goals>
    152                   <goal>run</goal>
    153                 </goals>
    154               </execution>
    155             </executions>
    156           </plugin>
    157         </plugins>
    158       </build>
    159     </profile>
    160   </profiles>
    161 </project>
    162