changeset 1415:7247c046d9dc

added build-time config to use Twelvemonkeys-ImageIO plugin instead of JAI-ImageIO. activate with "mvn -Dimageio=12m".
author robcast
date Thu, 22 Oct 2015 16:17:04 +0200
parents 840004733070
children 3e2f71bafcfb
files common/pom.xml pom.xml servlet3/pom.xml
diffstat 3 files changed, 105 insertions(+), 56 deletions(-) [+]
line wrap: on
line diff
--- a/common/pom.xml	Thu Oct 22 11:01:19 2015 +0200
+++ b/common/pom.xml	Thu Oct 22 16:17:04 2015 +0200
@@ -1,55 +1,104 @@
 <?xml version="1.0"?>
-<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
-    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
-  <modelVersion>4.0.0</modelVersion>
-  <parent>
-    <artifactId>digilib</artifactId>
-    <groupId>digilib</groupId>
-    <version>2.3-SNAPSHOT</version>
-  </parent>
-  <artifactId>digilib-common</artifactId>
-  <name>digilib-common</name>
-  <description>The Digital Image Library - common library</description>
-  <url>http://digilib.sourceforge.net</url>
-  <packaging>jar</packaging>
-  <build>
-  	<pluginManagement>
-  		<plugins>
-  			<plugin>
-  				<groupId>org.apache.maven.plugins</groupId>
-  				<artifactId>maven-compiler-plugin</artifactId>
-                <configuration>
-                    <source>1.7</source>
-                    <target>1.7</target> 
-                </configuration>
-  			</plugin>
-   		</plugins>
-  	</pluginManagement>
-  </build>
+<project
+	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
+	xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+	<modelVersion>4.0.0</modelVersion>
+	<parent>
+		<artifactId>digilib</artifactId>
+		<groupId>digilib</groupId>
+		<version>2.3-SNAPSHOT</version>
+	</parent>
+	
+	<artifactId>digilib-common</artifactId>
+	<name>digilib-common</name>
+	<description>The Digital Image Library - common library</description>
+	<url>http://digilib.sourceforge.net</url>
+	<packaging>jar</packaging>
+	
+	<build>
+		<pluginManagement>
+			<plugins>
+				<plugin>
+					<groupId>org.apache.maven.plugins</groupId>
+					<artifactId>maven-compiler-plugin</artifactId>
+					<configuration>
+						<source>1.7</source>
+						<target>1.7</target>
+					</configuration>
+				</plugin>
+			</plugins>
+		</pluginManagement>
+	</build>
 
-  <dependencies>
-    <dependency>
-        <groupId>com.github.jai-imageio</groupId>
-        <artifactId>jai-imageio-core</artifactId>
-        <version>1.3.0</version>
-    </dependency>
-    <!-- <dependency>
-        <groupId>com.github.jai-imageio</groupId>
-        <artifactId>jai-imageio-jpeg2000</artifactId>
-        <version>1.3.0</version>
-    </dependency> -->
-  	<dependency>
-  		<groupId>org.devlib.schmidt</groupId>
-  		<artifactId>imageinfo</artifactId>
-        <version>1.9</version>
-  		<type>jar</type>
-  		<scope>compile</scope>
-  	</dependency>
-  	<dependency>
-  		<groupId>log4j</groupId>
-  		<artifactId>log4j</artifactId>
-  		<type>jar</type>
-  		<scope>compile</scope>
-  	</dependency>
-  </dependencies>
+	<profiles>
+		<profile>
+			<id>imageio-jai</id>
+            <!--  use JAI-ImageIO plugin -->
+			<activation>
+				<activeByDefault>true</activeByDefault>
+				<property>
+					<name>imageio</name>
+					<value>jai</value>
+				</property>
+			</activation>
+			<dependencies>
+				<dependency>
+					<groupId>com.github.jai-imageio</groupId>
+					<artifactId>jai-imageio-core</artifactId>
+					<version>1.3.0</version>
+                    <type>jar</type>
+                    <scope>compile</scope>
+				</dependency>
+				<!-- 
+				<dependency> 
+			         <groupId>com.github.jai-imageio</groupId> 
+			         <artifactId>jai-imageio-jpeg2000</artifactId> 
+				     <version>1.3.0</version> 
+				 </dependency> 
+				 -->
+			</dependencies>
+		</profile>
+		<profile>
+			<id>imageio-12m</id>
+            <!-- use Twelvemonkeys ImageIO plugins -->
+			<activation>
+				<property>
+					<name>imageio</name>
+					<value>12m</value>
+				</property>
+			</activation>
+			<dependencies>
+				<dependency>
+					<groupId>com.twelvemonkeys.imageio</groupId>
+					<artifactId>imageio-jpeg</artifactId>
+					<version>3.1.2</version>
+                    <type>jar</type>
+                    <scope>compile</scope>
+				</dependency>
+				<dependency>
+					<groupId>com.twelvemonkeys.imageio</groupId>
+					<artifactId>imageio-tiff</artifactId>
+					<version>3.1.2</version>
+                    <type>jar</type>
+                    <scope>compile</scope>
+				</dependency>
+			</dependencies>
+		</profile>
+	</profiles>
+
+	<dependencies>
+		<dependency>
+			<groupId>org.devlib.schmidt</groupId>
+			<artifactId>imageinfo</artifactId>
+			<version>1.9</version>
+			<type>jar</type>
+			<scope>compile</scope>
+		</dependency>
+		<dependency>
+			<groupId>log4j</groupId>
+			<artifactId>log4j</artifactId>
+			<type>jar</type>
+			<scope>compile</scope>
+		</dependency>
+	</dependencies>
 </project>
--- a/pom.xml	Thu Oct 22 11:01:19 2015 +0200
+++ b/pom.xml	Thu Oct 22 16:17:04 2015 +0200
@@ -3,6 +3,10 @@
   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>
 
+  <properties>
+    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+  </properties>
+
   <groupId>digilib</groupId>
   <artifactId>digilib</artifactId>
   <version>2.3-SNAPSHOT</version>
@@ -242,9 +246,6 @@
       </dependency>
     </dependencies>
   </dependencyManagement>
-  <properties>
-    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
-  </properties>
 
   <dependencies>
   </dependencies>
--- a/servlet3/pom.xml	Thu Oct 22 11:01:19 2015 +0200
+++ b/servlet3/pom.xml	Thu Oct 22 16:17:04 2015 +0200
@@ -13,7 +13,6 @@
   			<plugin>
   				<groupId>org.apache.maven.plugins</groupId>
   				<artifactId>maven-compiler-plugin</artifactId>
-                <version>3.3</version>
                 <configuration>
                     <source>1.7</source>
                     <target>1.7</target>