<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>com.github.pfmiles</groupId>
	<artifactId>kan-java</artifactId>
	<version>0.1</version>
	<packaging>jar</packaging>

	<name>kan-java</name>
	<description>A dynamic compilation tool for java which also allows you to cut language features.</description>
	<url>https://github.com/pfmiles/kan-java</url>

	<licenses>
		<license>
			<name>Eclipse Public License - v 1.0</name>
			<url>http://www.eclipse.org/legal/epl-v10.html</url>
			<distribution>repo</distribution>
		</license>
	</licenses>

	<developers>
		<developer>
			<id>pf_miles</id>
			<name>Yue Wen</name>
			<email>miles.wy.1@gmail.com</email>
		</developer>
	</developers>

	<scm>
		<url>https://github.com/pfmiles/kan-java</url>
		<connection>scm:git:git@github.com:pfmiles/kan-java.git</connection>
	</scm>

	<properties>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<maven.compiler.source>1.6</maven.compiler.source>
		<maven.compiler.target>1.6</maven.compiler.target>
	</properties>

	<profiles>
		<profile>
			<id>unix_profile</id>
			<activation>
				<os>
					<family>unix</family>
				</os>
			</activation>
			<properties>
				<toolsjar>${java.home}/../lib/tools.jar</toolsjar>
			</properties>
		</profile>
		<profile>
			<id>windows_profile</id>
			<activation>
				<os>
					<family>windows</family>
				</os>
			</activation>
			<properties>
				<toolsjar>${java.home}/../lib/tools.jar</toolsjar>
			</properties>
		</profile>
		<profile>
			<id>osx_profile</id>
			<activation>
				<os>
					<family>mac</family>
				</os>
			</activation>
			<properties>
				<toolsjar>${java.home}/../Classes/classes.jar</toolsjar>
			</properties>
		</profile>
	</profiles>

	<dependencies>
		<dependency>
			<groupId>org.codehaus.groovy</groupId>
			<artifactId>groovy-all</artifactId>
			<version>2.3.7</version>
			<!-- Uncomment line below to use invokedynamic version of Groovy (requires 
				Java 7 or higher). -->
			<!-- <classifier>indy</classifier> -->
		</dependency>
		<dependency>
			<groupId>com.sun</groupId>
			<artifactId>tools</artifactId>
			<version>1.6.0</version>
			<scope>system</scope>
			<systemPath>${toolsjar}</systemPath>
		</dependency>
		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<version>3.8.1</version>
			<scope>test</scope>
		</dependency>
	</dependencies>
	<build>
		<plugins>
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>build-helper-maven-plugin</artifactId>
				<version>1.9.1</version>
				<executions>
					<execution>
						<id>add-source</id>
						<phase>generate-sources</phase>
						<goals>
							<goal>add-source</goal>
						</goals>
						<configuration>
							<sources>
								<source>${basedir}/src/main/groovy</source>
							</sources>
						</configuration>
					</execution>
					<execution>
						<id>add-test-source</id>
						<phase>generate-test-sources</phase>
						<goals>
							<goal>add-test-source</goal>
						</goals>
						<configuration>
							<sources>
								<source>${basedir}/src/test/groovy</source>
							</sources>
						</configuration>
					</execution>
				</executions>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-eclipse-plugin</artifactId>
				<version>2.9</version>
				<configuration>
					<additionalProjectnatures>
						<projectnature>org.eclipse.jdt.groovy.core.groovyNature</projectnature>
					</additionalProjectnatures>
					<sourceIncludes>
						<sourceInclude>**/*.groovy</sourceInclude>
					</sourceIncludes>
					<downloadSources>true</downloadSources>
					<downloadJavadocs>true</downloadJavadocs>
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-compiler-plugin</artifactId>
				<version>3.2</version>
				<configuration>
					<compilerId>groovy-eclipse-compiler</compilerId>
				</configuration>
				<dependencies>
					<dependency>
						<groupId>org.codehaus.groovy</groupId>
						<artifactId>groovy-eclipse-compiler</artifactId>
						<version>2.9.1-01</version>
					</dependency>
					<dependency>
						<groupId>org.codehaus.groovy</groupId>
						<artifactId>groovy-eclipse-batch</artifactId>
						<version>2.3.7-01</version>
					</dependency>
				</dependencies>
			</plugin>
		</plugins>
	</build>
</project>
