minesweeper/pom.xml
author Jaroslav Tulach <jtulach@netbeans.org>
Fri, 11 Apr 2014 10:40:19 +0200
changeset 130 3d99b96ffbd4
parent 129 ff497594741e
child 131 49834c96798d
permissions -rw-r--r--
Expanded description
     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/xsd/maven-4.0.0.xsd">
     3   <modelVersion>4.0.0</modelVersion>
     4 
     5   <groupId>org.apidesign.demo</groupId>
     6   <artifactId>minesweeper</artifactId>
     7   <version>1.0-SNAPSHOT</version>
     8   <packaging>jar</packaging>
     9   <parent>
    10       <artifactId>demo</artifactId>
    11       <groupId>org.apidesign.html</groupId>
    12       <version>1.0-SNAPSHOT</version>
    13   </parent>
    14 
    15   <name>Mine Sweeper</name>
    16   <description>
    17       Demonstration of DukeScript rendering technology.
    18       Plus old, good, simple and entertainin game.
    19       Improve your coding skills by playing a game and 
    20       meanwhile learn what a rendering technology of the
    21       future is going to look like. Learn to use DukeScript:
    22       Write once, display (and deploy) anywhere!
    23   </description>
    24   <url>http://html.java.net/</url>
    25   <properties>
    26     <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    27     <brwsr.startpage>pages/index.html</brwsr.startpage>
    28     <project.mainclass>org.apidesign.demo.minesweeper.Main</project.mainclass>
    29     <netbeans.compile.on.save>none</netbeans.compile.on.save>
    30   </properties>
    31   <build>
    32       <plugins>
    33           <plugin>
    34               <groupId>org.apache.maven.plugins</groupId>
    35               <artifactId>maven-compiler-plugin</artifactId>
    36               <version>2.3.2</version>
    37               <configuration>
    38                   <source>1.6</source>
    39                   <target>1.6</target>
    40               </configuration>
    41           </plugin>
    42           <plugin>
    43               <groupId>org.apache.maven.plugins</groupId>
    44               <artifactId>maven-jar-plugin</artifactId>
    45               <version>2.4</version>
    46               <configuration>
    47                   <archive>
    48                       <manifest>
    49                           <mainClass>${project.mainclass}</mainClass>
    50                           <addClasspath>true</addClasspath>
    51                           <classpathPrefix>lib/</classpathPrefix>
    52                       </manifest>
    53                   </archive>
    54               </configuration>
    55           </plugin>
    56           <plugin>
    57               <groupId>org.codehaus.mojo</groupId>
    58               <artifactId>exec-maven-plugin</artifactId>
    59               <version>1.2.1</version>
    60               <configuration>
    61                   <systemProperties>
    62                       <systemProperty>
    63                           <key>browser.rootdir</key>
    64                           <value>${basedir}/src/main/webapp/</value>
    65                       </systemProperty>
    66                   </systemProperties>
    67                   <mainClass>${project.mainclass}</mainClass>
    68               </configuration>
    69           </plugin>      
    70       </plugins>
    71   </build>
    72   <dependencies>
    73     <dependency>
    74         <groupId>org.netbeans.html</groupId>
    75         <artifactId>net.java.html.json</artifactId>
    76         <version>${net.java.html.version}</version>
    77     </dependency>
    78     <dependency>
    79         <groupId>org.netbeans.html</groupId>
    80         <artifactId>net.java.html.boot</artifactId>
    81         <version>${net.java.html.version}</version>
    82     </dependency>
    83     <dependency>
    84         <groupId>org.netbeans.html</groupId>
    85         <artifactId>net.java.html</artifactId>
    86         <version>${net.java.html.version}</version>
    87     </dependency>
    88     <dependency>
    89         <groupId>org.netbeans.html</groupId>
    90         <artifactId>net.java.html.sound</artifactId>
    91         <version>${net.java.html.version}</version>
    92     </dependency>
    93     <dependency>
    94         <groupId>org.netbeans.html</groupId>
    95         <artifactId>ko4j</artifactId>
    96         <version>${net.java.html.version}</version>
    97     </dependency>
    98     <dependency>
    99       <groupId>org.netbeans.html</groupId>
   100       <artifactId>nbrwsr</artifactId>
   101       <version>${net.java.html.version}</version>
   102       <scope>provided</scope>
   103     </dependency>
   104     <dependency>
   105       <groupId>org.testng</groupId>
   106       <artifactId>testng</artifactId>
   107       <version>6.7</version>
   108       <scope>test</scope>
   109     </dependency>
   110   </dependencies>
   111   <profiles>
   112       <profile>
   113           <id>fxbrwsr</id>
   114           <activation>
   115               <activeByDefault>true</activeByDefault>
   116           </activation>
   117           <build>
   118             <plugins>
   119                 <plugin>
   120                     <artifactId>maven-assembly-plugin</artifactId>
   121                     <version>2.4</version>
   122                     <executions>
   123                         <execution>
   124                             <id>distro-assembly</id>
   125                             <phase>package</phase>
   126                             <goals>
   127                                 <goal>single</goal>
   128                             </goals>
   129                             <configuration>
   130                                 <descriptors>
   131                                     <descriptor>src/main/assembly/html.java.net.xml</descriptor>
   132                                 </descriptors>
   133                             </configuration>
   134                         </execution>
   135                     </executions>                
   136                 </plugin>      
   137             </plugins>
   138           </build>
   139           <dependencies>
   140             <dependency>
   141                 <groupId>org.netbeans.html</groupId>
   142                 <artifactId>net.java.html.boot.fx</artifactId>
   143                 <version>${net.java.html.version}</version>
   144                 <scope>runtime</scope>
   145             </dependency>
   146           </dependencies>
   147       </profile>
   148       <profile>
   149           <id>bck2brwsr</id>
   150           <activation>
   151               <property>
   152                   <name>brwsr</name>
   153                   <value>bck2brwsr</value>
   154               </property>
   155           </activation>
   156           <build>
   157               <plugins>
   158                   <plugin>
   159                       <groupId>org.apidesign.bck2brwsr</groupId>
   160                       <artifactId>bck2brwsr-maven-plugin</artifactId>
   161                       <version>${bck2brwsr.version}</version>
   162                       <executions>
   163                           <execution>
   164                               <goals>
   165                                   <goal>brwsr</goal>
   166                               </goals>
   167                           </execution>
   168                       </executions>
   169                       <configuration>
   170                           <directory>${basedir}/src/main/webapp/</directory>
   171                           <startpage>${brwsr.startpage}</startpage>
   172                       </configuration>
   173                   </plugin>
   174                   <plugin>
   175                       <groupId>org.apache.maven.plugins</groupId>
   176                       <artifactId>maven-compiler-plugin</artifactId>
   177                       <configuration>
   178                           <compilerArguments>
   179                               <bootclasspath>netbeans.ignore.jdk.bootclasspath</bootclasspath>
   180                           </compilerArguments>
   181                       </configuration>
   182                   </plugin>
   183                   <plugin>
   184                       <artifactId>maven-assembly-plugin</artifactId>
   185                       <version>2.4</version>
   186                       <executions>
   187                           <execution>
   188                               <id>distro-assembly</id>
   189                               <phase>package</phase>
   190                               <goals>
   191                                   <goal>single</goal>
   192                               </goals>
   193                               <configuration>
   194                                   <descriptors>
   195                                       <descriptor>src/main/assembly/bck2brwsr.xml</descriptor>
   196                                   </descriptors>
   197                               </configuration>
   198                           </execution>
   199                       </executions>                
   200                   </plugin>      
   201               </plugins>
   202           </build>
   203           <dependencies>
   204               <dependency>
   205                   <groupId>org.apidesign.bck2brwsr</groupId>
   206                   <artifactId>emul</artifactId>
   207                   <version>${bck2brwsr.version}</version>
   208                   <classifier>rt</classifier>
   209               </dependency>
   210               <dependency>
   211                   <groupId>org.apidesign.bck2brwsr</groupId>
   212                   <artifactId>ko-bck2brwsr</artifactId>
   213                   <version>${bck2brwsr.version}</version>
   214                   <scope>runtime</scope>
   215               </dependency>
   216               <dependency>
   217                   <groupId>org.apidesign.bck2brwsr</groupId>
   218                   <artifactId>vm4brwsr</artifactId>
   219                   <classifier>js</classifier>
   220                   <type>zip</type>
   221                   <version>${bck2brwsr.version}</version>
   222                   <scope>provided</scope>
   223               </dependency>
   224           </dependencies>
   225       </profile>
   226       <profile>
   227           <id>dlvkbrwsr</id>
   228           <properties>
   229               <platform.version>4.1.1.4</platform.version>
   230               <android.plugin.version>3.7.0</android.plugin.version>
   231               <debug>false</debug>
   232           </properties>
   233           <dependencies>
   234               <dependency>
   235                   <groupId>com.google.android</groupId>
   236                   <artifactId>android</artifactId>
   237                   <version>${platform.version}</version>
   238                   <scope>provided</scope>
   239               </dependency>
   240               <dependency>
   241                   <groupId>org.apidesign.brwsr</groupId>
   242                   <artifactId>dlvkbrwsr</artifactId>
   243                   <version>0.5</version>
   244                   <type>jar</type>
   245               </dependency>
   246               <dependency>
   247                   <groupId>org.netbeans.html</groupId>
   248                   <artifactId>ko-ws-tyrus</artifactId>
   249                   <version>${net.java.html.version}</version>
   250                   <exclusions>
   251                       <exclusion>
   252                           <artifactId>org.json-osgi</artifactId>
   253                           <groupId>de.twentyeleven.skysail</groupId>
   254                       </exclusion>
   255                   </exclusions>
   256               </dependency>
   257           </dependencies>
   258           <build>
   259               <plugins>
   260                   <plugin>
   261                       <groupId>com.jayway.maven.plugins.android.generation2</groupId>
   262                       <artifactId>android-maven-plugin</artifactId>
   263                       <version>${android.plugin.version}</version>
   264                       <extensions>true</extensions>
   265                       <configuration>
   266                           <classifier>apk</classifier>
   267                           <attachJar>false</attachJar>
   268                           <apkDebug>debug</apkDebug>
   269                           <assetsDirectory>src/main/webapp</assetsDirectory>
   270                           <sdk>
   271                               <platform>16</platform>
   272                           </sdk>
   273                           <apk>
   274                               <metaIncludes>
   275                                   <metaInclude>services/org.apidesign.**</metaInclude>
   276                               </metaIncludes>
   277                           </apk>
   278                           <extractDuplicates>true</extractDuplicates>
   279                           <file>${project.build.directory}/${project.build.finalName}.apk</file>
   280                       </configuration>
   281                       <executions>
   282                           <execution>
   283                               <id>apk</id>
   284                               <goals>
   285                                   <goal>apk</goal>
   286                                   <goal>dex</goal>
   287                               </goals>
   288                           </execution>
   289                       </executions>
   290                   </plugin>
   291                   <plugin>
   292                       <groupId>org.apache.maven.plugins</groupId>
   293                       <artifactId>maven-install-plugin</artifactId>
   294                       <version>2.5.1</version>
   295                       <configuration>
   296                           <groupId>${project.groupId}</groupId>
   297                           <artifactId>${project.artifactId}</artifactId>
   298                           <version>${project.version}</version>
   299                           <file>${project.build.directory}/${project.build.finalName}.apk</file>
   300                           <packaging>apk</packaging>
   301                           <skip>true</skip>
   302                       </configuration>
   303                       <executions>
   304                           <execution>
   305                               <id>install-apk</id>
   306                               <phase>install</phase>
   307                               <goals>
   308                                   <goal>install-file</goal>
   309                               </goals>
   310                           </execution>
   311                       </executions>
   312                   </plugin>
   313               </plugins>
   314           </build>
   315       </profile>
   316       <profile>
   317           <id>teabrwsr</id>
   318           <build>
   319               <plugins>
   320                   <plugin>
   321                       <groupId>org.teavm</groupId>
   322                       <artifactId>teavm-maven-plugin</artifactId>
   323                       <version>${teavm.version}</version>
   324                       <dependencies>
   325                           <dependency>
   326                               <groupId>org.teavm</groupId>
   327                               <artifactId>teavm-classlib</artifactId>
   328                               <version>${teavm.version}</version>
   329                           </dependency>
   330                           <!-- This module adds html4j support. It mainly includes JavaScriptBuilder support.
   331                           Also there are some little patches to JCL emulation, that are required to pass TCK -->
   332                           <dependency>
   333                               <groupId>org.teavm</groupId>
   334                               <artifactId>teavm-html4j</artifactId>
   335                               <version>${teavm.version}</version>
   336                           </dependency>
   337                       </dependencies>
   338                       <executions>
   339                           <execution>
   340                               <id>generate-minesweeper</id>
   341                               <goals>
   342                                   <goal>build-javascript</goal>
   343                               </goals>
   344                               <phase>process-classes</phase>
   345                               <configuration>
   346                                   <!-- Whether we want TeaVM to minify (obfuscate) the generated JavaScript -->
   347                                   <minifying>false</minifying>
   348                                   <properties>
   349                                       <!-- This classes (separated with , ; space) will be available through vm.loadClass() -->
   350                                       <html4j.entryPoints>org.apidesign.demo.minesweeper.MainBrwsr</html4j.entryPoints>
   351                                   </properties>
   352                                   <!-- Don't include main page - we created it by ourselves -->
   353                                   <mainPageIncluded>false</mainPageIncluded>
   354                                   <!-- Merge runtime.js instead of putting as a separate file -->
   355                                   <runtime>MERGED</runtime>
   356                                   <!-- Name of the generated file -->
   357                                   <targetFileName>bck2brwsr.js</targetFileName>
   358                                   <targetDirectory>${project.build.directory}/teavm</targetDirectory>
   359                                   <!-- This transformer adds null checks before virtual calls. It is not included
   360                                   by default as we don't always need these null checks -->
   361                                   <transformers>
   362                                       <param>org.teavm.javascript.NullPointerExceptionTransformer</param>
   363                                   </transformers>
   364                               </configuration>
   365                           </execution>
   366                       </executions>
   367                   </plugin>
   368                   <plugin>
   369                       <artifactId>maven-assembly-plugin</artifactId>
   370                       <version>2.4</version>
   371                       <executions>
   372                           <execution>
   373                               <id>distro-assembly</id>
   374                               <phase>package</phase>
   375                               <goals>
   376                                   <goal>single</goal>
   377                               </goals>
   378                               <configuration>
   379                                   <descriptors>
   380                                       <descriptor>src/main/assembly/teabrwsr.xml</descriptor>
   381                                   </descriptors>
   382                               </configuration>
   383                           </execution>
   384                       </executions>                
   385                   </plugin>      
   386               </plugins>
   387           </build>
   388       </profile>
   389       <profile>
   390           <id>nbrwsr</id>
   391           <dependencies>
   392               <dependency>
   393                   <groupId>org.netbeans.html</groupId>
   394                   <artifactId>nbrwsr</artifactId>
   395                   <version>${net.java.html.version}</version>
   396                   <scope>compile</scope>
   397               </dependency>
   398           </dependencies>
   399           <build>
   400               <plugins>
   401                   <plugin>
   402                       <groupId>org.apache.maven.plugins</groupId>
   403                       <artifactId>maven-resources-plugin</artifactId>
   404                       <version>2.6</version>
   405                       <executions>
   406                           <execution>
   407                               <id>include-webpages</id>
   408                               <goals>
   409                                   <goal>copy-resources</goal>
   410                               </goals>
   411                               <phase>process-resources</phase>
   412                               <configuration>
   413                                   <outputDirectory>${basedir}/target/classes/org/apidesign/demo/minesweeper</outputDirectory>
   414                                   <overwrite>true</overwrite>
   415                                   <resources>          
   416                                       <resource>
   417                                           <directory>src/main/webapp/pages</directory>
   418                                       </resource>
   419                                   </resources>              
   420                               </configuration>   
   421                           </execution>
   422                       </executions>
   423                   </plugin>
   424                   <plugin>
   425                       <groupId>org.codehaus.mojo</groupId>
   426                       <artifactId>nbm-maven-plugin</artifactId>
   427                       <version>3.13</version>
   428                       <extensions>true</extensions>
   429                       <executions>
   430                           <execution>
   431                               <id>default-manifest</id>
   432                               <phase>process-classes</phase>
   433                               <goals>
   434                                   <goal>manifest</goal>
   435                               </goals>
   436                               <configuration>
   437                                   <useOSGiDependencies>true</useOSGiDependencies>
   438                                   <brandingToken>html4j4nb</brandingToken>
   439                                   <cluster>extra</cluster>
   440                                   <verifyIntegrity>false</verifyIntegrity>
   441                               </configuration>
   442                           </execution>                       
   443                           <execution>
   444                               <id>default-nbm</id>
   445                               <phase>package</phase>
   446                               <goals>
   447                                   <goal>nbm</goal>
   448                               </goals>
   449                               <configuration>
   450                                   <useOSGiDependencies>true</useOSGiDependencies>
   451                                   <cluster>extra</cluster>
   452                                   <verifyIntegrity>false</verifyIntegrity>
   453                               </configuration>
   454                           </execution>
   455                       </executions>
   456                       <configuration>
   457                           <useOSGiDependencies>true</useOSGiDependencies>
   458                           <brandingToken>html4j4nb</brandingToken>
   459                           <cluster>html4j4nb</cluster>
   460                           <verifyIntegrity>false</verifyIntegrity>
   461                       </configuration>
   462                   </plugin>                      
   463 
   464                   <plugin>
   465                       <groupId>org.apache.maven.plugins</groupId>
   466                       <artifactId>maven-jar-plugin</artifactId>
   467                       <configuration>
   468                           <!-- to have the jar plugin pickup the nbm generated manifest -->
   469                           <useDefaultManifestFile>true</useDefaultManifestFile>
   470                       </configuration>
   471                   </plugin>
   472               </plugins>
   473           </build>
   474       </profile>      
   475   </profiles>  
   476 </project>