Path: csiph.com!eternal-september.org!feeder.eternal-september.org!aioe.org!bofh.it!news.nic.it!robomod From: Andreas Tille Newsgroups: linux.debian.maint.java Subject: Continuing work on qualimap (Was: Any help?) Date: Tue, 24 Nov 2015 14:20:02 +0100 Message-ID: References: X-Original-To: Bas Couwenberg X-Mailbox-Line: From debian-java-request@lists.debian.org Tue Nov 24 13:18:06 2015 Old-Return-Path: X-Amavis-Spam-Status: No, score=-5.245 tagged_above=-10000 required=5.3 tests=[BAYES_00=-2, FOURLA=0.1, LDO_WHITELIST=-5, MEDS2=2, RP_MATCHES_RCVD=-0.345] autolearn=no autolearn_force=no X-Policyd-Weight: using cached result; rate:hard: -6.1 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.23 (2014-03-12) X-Mailing-List: archive/latest/18908 List-ID: List-URL: List-Archive: https://lists.debian.org/msgid-search/20151124131752.GL29080@an3as.eu Approved: robomod@news.nic.it Lines: 159 Organization: linux.* mail to news gateway Sender: robomod@news.nic.it X-Original-Cc: debian-java@lists.debian.org X-Original-Date: Tue, 24 Nov 2015 14:17:52 +0100 X-Original-Message-ID: <20151124131752.GL29080@an3as.eu> X-Original-References: <20151123094802.GB13138@an3as.eu> <56537AEB.9090908@xs4all.nl> <20151123212047.GA29080@an3as.eu> <5653A874.7090807@xs4all.nl> <20151124114218.GI29080@an3as.eu> <8b914f9c6b2f4a33b2ae365f7001028b@xs4all.nl> Xref: csiph.com linux.debian.maint.java:8589 Hi Bas, I decided to switch back to the list to make these helpful hints available for web search. I guess you will not mind the proof that you are just very helpful. ;-) For those who are missing context: Bas is helping me getting git://git.debian.org/git/debian-med/qualimap.git into shape. On Tue, Nov 24, 2015 at 01:04:55PM +0100, Bas Couwenberg wrote: > On 2015-11-24 12:42, Andreas Tille wrote: > >On Tue, Nov 24, 2015 at 12:59:48AM +0100, Sebastiaan Couwenberg wrote: > >>samtools.jar is not available in the maven repository, so you'll need to > >>install it manually in d/rules like elasticsearch did for jts: > >> > >>https://sources.debian.net/src/elasticsearch/1.7.3%2Bdfsg-2/debian/rules/#L34 > >>https://sources.debian.net/src/elasticsearch/1.7.3%2Bdfsg-2/debian/maven.rules/#L10 > >> > >>miglayout.jar is likewise also not in the maven repository, but you may > >>be able to use miglayout-parent instead. > > > >I added libmiglayout-java as Build-Depends. I do not understand the hint > >to miglayout-parent. Any example? > > Maven can only use the packaged JARs if they're available in the local Maven > repository, to check if a Java package registers the JARs it builds with > Maven (using maven-repo-helper) I check the package content with apt-file, > eg.: > > $ apt-file show libmiglayout-java > libmiglayout-java: /usr/share/doc/libmiglayout-java/changelog.Debian.gz > libmiglayout-java: /usr/share/doc/libmiglayout-java/copyright > libmiglayout-java: /usr/share/java/miglayout-4.2.jar > libmiglayout-java: /usr/share/java/miglayout-core-4.2.jar > libmiglayout-java: /usr/share/java/miglayout-core.jar > libmiglayout-java: /usr/share/java/miglayout-ideutil-4.2.jar > libmiglayout-java: /usr/share/java/miglayout-ideutil.jar > libmiglayout-java: /usr/share/java/miglayout-swing-4.2.jar > libmiglayout-java: /usr/share/java/miglayout-swing.jar > libmiglayout-java: /usr/share/java/miglayout-swt-4.2.jar > libmiglayout-java: /usr/share/java/miglayout-swt.jar > libmiglayout-java: /usr/share/java/miglayout.jar > libmiglayout-java: > /usr/share/maven-repo/com/miglayout/miglayout-core/4.2/miglayout-core-4.2.jar > libmiglayout-java: > /usr/share/maven-repo/com/miglayout/miglayout-core/4.2/miglayout-core-4.2.pom > libmiglayout-java: /usr/share/maven-repo/com/miglayout/miglayout-core/debian/miglayout-core-debian.jar > libmiglayout-java: /usr/share/maven-repo/com/miglayout/miglayout-core/debian/miglayout-core-debian.pom > libmiglayout-java: /usr/share/maven-repo/com/miglayout/miglayout-ideutil/4.2/miglayout-ideutil-4.2.jar > libmiglayout-java: /usr/share/maven-repo/com/miglayout/miglayout-ideutil/4.2/miglayout-ideutil-4.2.pom > libmiglayout-java: /usr/share/maven-repo/com/miglayout/miglayout-ideutil/debian/miglayout-ideutil-debian.jar > libmiglayout-java: /usr/share/maven-repo/com/miglayout/miglayout-ideutil/debian/miglayout-ideutil-debian.pom > libmiglayout-java: /usr/share/maven-repo/com/miglayout/miglayout-parent/4.2/miglayout-parent-4.2.pom > libmiglayout-java: /usr/share/maven-repo/com/miglayout/miglayout-parent/debian/miglayout-parent-debian.pom > libmiglayout-java: /usr/share/maven-repo/com/miglayout/miglayout-swing/4.2/miglayout-swing-4.2.jar > libmiglayout-java: /usr/share/maven-repo/com/miglayout/miglayout-swing/4.2/miglayout-swing-4.2.pom > libmiglayout-java: /usr/share/maven-repo/com/miglayout/miglayout-swing/debian/miglayout-swing-debian.jar > libmiglayout-java: /usr/share/maven-repo/com/miglayout/miglayout-swing/debian/miglayout-swing-debian.pom > libmiglayout-java: > /usr/share/maven-repo/com/miglayout/miglayout-swt/4.2/miglayout-swt-4.2.jar > libmiglayout-java: > /usr/share/maven-repo/com/miglayout/miglayout-swt/4.2/miglayout-swt-4.2.pom > libmiglayout-java: /usr/share/maven-repo/com/miglayout/miglayout-swt/debian/miglayout-swt-debian.jar > libmiglayout-java: /usr/share/maven-repo/com/miglayout/miglayout-swt/debian/miglayout-swt-debian.pom > > As you can see there is no entry in the maven-repo for the miglayout > artifact, only the -core, -ideutil, -swing & -swg JARs. > > The miglayout-parent artifact is the only one not matching a JAR by the same > name, so I suspect it's for miglayout.jar. > > To use miglayout-parent for the miglayout dependency you need to add the > following to maven.rules to mangle the dependency defined in pom.xml: > > com.miglayout s/miglayout/miglayout-parent/ * s/.*/debian/ * * > > Because the pom.xml has this dependency: > > > com.miglayout > miglayout > 3.7.4 > > > It will cause maven to check for /usr/share/maven-repo/com/miglayout/miglayout/3.7.4/miglayout-3.7.4.{jar,pom}, > but that isn't provided by libmiglayout-java. You need to mangle the version > to check for /usr/share/maven-repo/com/miglayout/miglayout/debian/miglayout-debian.{jar,pom} > at least, but that still leaves the missing artifact (miglayout vs > miglayout-parent). With the suggested entry in maven.rules, maven will check > for /usr/share/maven-repo/com/miglayout/miglayout-parent/debian/miglayout-parent-debian.{jar,pom} > instead. Thanks for your patience in explaining. The fog becomes a bit clearer even if it has not fully settled. ;-) > If the -parent artifact doesn't provide the classes required for qualimap, > they're probably provided by miglayout-core for which you'd need this entry > in maven.rules: > > com.miglayout s/miglayout/miglayout-core/ * s/.*/debian/ * * > > >>picard.jar is in the same boat as samtools.jar, and needs to be manually > >>installed into the local maven repository. Just to prove that I did not fully understood the principle I have now: ... mvn --offline install:install-file \ -Dmaven.repo.local=/build/qualimap-2.1.3+dfsg/debian/maven-repo \ -Dfile=/usr/share/java/sam.jar \ -DgroupId=net/sf \ -DartifactId=samtools \ -Dversion=fake \ -Dpackaging=jar [INFO] NOTE: Maven is executing in offline mode. Any artifacts not already in your local repository will be inaccessible. [INFO] Scanning for projects... [INFO] Searching repository for plugin with prefix: 'install'. [INFO] ------------------------------------------------------------------------ [INFO] Building qualimap [INFO] task-segment: [install:install-file] (aggregator-style) [INFO] ------------------------------------------------------------------------ [INFO] [install:install-file {execution: default-cli}] [INFO] pom.xml not found in sam.jar [INFO] ------------------------------------------------------------------------ [ERROR] BUILD ERROR [INFO] ------------------------------------------------------------------------ [INFO] The artifact information is incomplete or not valid: [0] 'groupId' with value 'net/sf' does not match a valid id pattern. ... I'm afraid that it might be due to the fact that in sam.jar two directories (or should I say groupIds?) reside next to each other. I might have choosen the wrong one or any other thing was wrong. > This just shows that you also need to build depend on > libmaven-install-plugin-java, because it wasn't found in the local maven > repository used for the packaged JARs. Damn, this was a simple one which I should have found myself ... > >is not specifically connected to the maven override rules. > > > >I'm afraid I keep on doing things terribly wrong. :-( > > You'll get the hang of it eventually :-) I do not give up the hope. ;-) Thanks a lot for your private support Andreas. -- http://fam-tille.de