<!-- Copyright (c) 2013 LogonBox Limited. All rights reserved. This program 
	and the accompanying materials are made available under the terms of the 
	GNU Public License v3.0 which accompanies this distribution, and is available 
	at http://www.gnu.org/licenses/gpl.html -->
<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>
    <artifactId>client-logonbox-vpn-dbconvert</artifactId>
    <name>Hypersocket - Client (Convert database to configuration files)</name>

    <parent>
        <groupId>com.logonbox</groupId>
        <artifactId>logonbox-desktop-vpn-clients</artifactId>
        <version>3.0.2-SNAPSHOT</version>
        <relativePath>..</relativePath>
    </parent>

    <build>
        <directory>target</directory>
        <plugins>
            <plugin>
                <groupId>com.nervepoint</groupId>
                <artifactId>google-translate-v2-java-maven-plugin</artifactId>
                <executions>
                    <execution>
                        <phase>process-resources</phase>
                        <goals>
                            <goal>translate</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-dependency-plugin</artifactId>
                <executions>
                    <execution>
                        <id>copy-dbconvert-dependencies</id>
                        <phase>package</phase>
                        <goals>
                            <goal>copy-dependencies</goal>
                        </goals>
                        <configuration>
                            <excludeScope>provided</excludeScope>
                            <outputDirectory>${project.build.directory}/dependencies</outputDirectory>
                            <overWriteReleases>false</overWriteReleases>
                            <overWriteSnapshots>true</overWriteSnapshots>
                            <overWriteIfNewer>true</overWriteIfNewer>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

    <dependencies>
        <dependency>
            <groupId>org.apache.derby</groupId>
            <artifactId>derby</artifactId>
            <version>10.15.2.0</version>
        </dependency>
        <dependency>
            <groupId>org.apache.derby</groupId>
            <artifactId>derbyclient</artifactId>
            <version>10.15.2.0</version>
        </dependency>
        <dependency>
            <groupId>org.ini4j</groupId>
            <artifactId>ini4j</artifactId>
            <version>0.5.4</version>
        </dependency>
    </dependencies>

    <repositories>
        <repository>
            <id>public-releases</id>
            <name>public-releases</name>
            <url>https://artifactory.jadaptive.com/public-releases</url>
            <snapshots>
                <enabled>false</enabled>
            </snapshots>
            <releases />
        </repository>
        <repository>
            <id>public-snapshots</id>
            <name>public-snapshots</name>
            <url>https://artifactory.jadaptive.com/public-snapshots</url>
            <releases>
                <enabled>false</enabled>
            </releases>
            <snapshots />
        </repository>
        <repository>
            <id>opensource-releases</id>
            <name>opensource-releases</name>
            <url>https://artifactory.jadaptive.com/opensource-releases</url>
            <snapshots>
                <enabled>false</enabled>
            </snapshots>
            <releases />
        </repository>
        <repository>
            <id>opensource-snapshots</id>
            <name>opensource-snapshots</name>
            <url>https://artifactory.jadaptive.com/opensource-snapshots</url>
            <releases>
                <enabled>false</enabled>
            </releases>
            <snapshots />
        </repository>
    </repositories>

    <profiles>
        <profile>
            <id>native</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.graalvm.buildtools</groupId>
                        <artifactId>native-maven-plugin</artifactId>
                        <version>${native.maven.plugin.version}</version>
                        <extensions>true</extensions>
                        <executions>
                            <execution>
                                <id>build-native</id>
                                <goals>
                                    <goal>build</goal>
                                </goals>
                                <phase>package</phase>
                            </execution>
                            <execution>
                                <id>test-native</id>
                                <goals>
                                    <goal>test</goal>
                                </goals>
                                <phase>test</phase>
                            </execution>
                        </executions>
                        <configuration>
                            <imageName>dbconvert</imageName>
                            <mainClass>com.logonbox.vpn.client.dbconvert.DbConvert</mainClass>
                            <buildArgs>
                                <buildArg>--no-fallback</buildArg>
                                <buildArg>--report-unsupported-elements-at-runtime</buildArg>
                                <buildArg>--allow-incomplete-classpath</buildArg>
                            </buildArgs>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
</project>