2

I have an issue with my pom.xml file. I have a project made with Spring MVC and uses this dependency:

<dependency>
    <groupId>net.sf.jasperreports</groupId>
    <artifactId>jasperreports</artifactId>
    <version>6.3.0</version>
</dependency>

The project was developed on a 64bits Gnome Debian based system and works fine, but yesterday I tried to checkout the project from Github on a 32 bit Debian LXDE laptop, but I have Maven errors, Eclipse keeps saying that I have missing dependencies:

  • Missing artifact org.olap4j:olap4j:jar:0.9.7.309-JS-3
  • Missing artifact com.lowagie:itext:jar:2.1.7.js5

Although I'm using the the same software version on both machines (32 and 64 bits):

  • Eclipse Mars.
  • apache-tomcat-8.0.33.
  • jdk1.8.0_92

The solution I found (after almost kill maven) was to add the extra maven dependencies required. For me this solution didn’t have to much sense because it's only needed on the 32 bits machine:

<!-- https://mvnrepository.com/artifact/com.lowagie/itext -->
<dependency>
    <groupId>com.lowagie</groupId>
    <artifactId>itext</artifactId>
    <version>2.1.7</version>
</dependency>


<!-- https://mvnrepository.com/artifact/org.olap4j/olap4j -->
<dependency>
    <groupId>org.olap4j</groupId>
    <artifactId>olap4j</artifactId>
    <version>1.2.0</version>
</dependency>

After a research I discovered that Jasperreports 6.3.0 has already included the missing dependencies in the jar file, that's why on the 64bits machine the only dependency needed is the jasperreports 6.3.0.

My questions are:

  • Why do I need to have two versions of pom file: one for the 32 bits computer and the other for the 64bits computer considering that the software tools version are the same?.
  • How can I have only one version of pom file that works on both platforms?.

Thanks in advance!

Lonzak
  • 9,334
  • 5
  • 57
  • 88
  • That is indeed strange. Do you also use the same maven version on both machines? And what JDK do you use (which version and what architecture)? (Since you could use a 32 Bit JDK on a 64 bit machine...) – Lonzak May 15 '17 at 08:04

1 Answers1

0

I think the best result is when you add the JasperSoft repository to your pom.xml/settings.xml:

<repository>
    <id>jaspersoft.artifactory</id>
    <url>https://jaspersoft.jfrog.io/artifactory/third-party-ce-artifacts/</url>
</repository>

this repo replace https://jasperreports.artifactoryonline.com

The 32/64bit in java almost doesn't matter because the JVM. It is JVM that does the "dirty job"

Cavva79
  • 379
  • 6
  • 17