<?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/maven-v4_0_0.xsd">
  <modelVersion>4.0.0</modelVersion>
  <groupId>org.opennms.assemblies</groupId>
  <artifactId>opennms-remote-poller-windows</artifactId>
  <version>1.13.5-SNAPSHOT</version>
  <packaging>pom</packaging>
  <!-- 
    This "name" value is displayed in the installer and used to 
    construct the names of registry keys that contain configuration 
    data so do not change it unless you test the changes thoroughly.
  -->
  <name>OpenNMS Remote Poller</name>
  <profiles>
    <profile>
      <id>linux</id>
      <activation>
        <os>
          <name>Linux</name>
        </os>
      </activation>
      <build>
        <plugins>
          <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>nsis-maven-plugin</artifactId>
            <version>1.0-alpha-1</version>
            <configuration>
              <!-- Linux doesn't need a makensisBin param because it should be in the $PATH -->
              <scriptFile>remote-poller.nsi</scriptFile>
            </configuration>
            <executions>
              <execution>
                <goals>
                  <goal>generate-headerfile</goal>
                  <goal>make</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
    <profile>
      <id>windows</id>
      <activation>
        <os>
          <family>windows</family>
        </os>
      </activation>
      <build>
        <plugins>
          <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>nsis-maven-plugin</artifactId>
            <version>1.0-alpha-1</version>
            <configuration>
              <!-- You may have to change this path if you install NSIS in a different directory -->
              <makensisBin>C:\Progra~1\NSIS\makensis.exe</makensisBin>
              <scriptFile>remote-poller.nsi</scriptFile>
            </configuration>
            <executions>
              <execution>
                <goals>
                  <goal>generate-headerfile</goal>
                  <goal>make</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>
</project>
