[Git][java-team/javatools][master] jh_build: Fix wrong path for jar cmd

Niels Thykier gitlab at salsa.debian.org
Sat Mar 16 08:35:52 GMT 2019


Niels Thykier pushed to branch master at Debian Java Maintainers / javatools


Commits:
80595123 by Niels Thykier at 2019-03-16T08:35:31Z
jh_build: Fix wrong path for jar cmd

Signed-off-by: Niels Thykier <niels at thykier.net>

- - - - -


2 changed files:

- debian/changelog
- jh_build


Changes:

=====================================
debian/changelog
=====================================
@@ -1,3 +1,12 @@
+javatools (0.72.6) UNRELEASED; urgency=medium
+
+  * Team upload.
+  * jh_build: Fix wrong path for jar command when the jar was path
+    was specified without a slash.  Thanks to Gilles Filippini for
+    reporting the bug.  (Closes: #924653)
+
+ -- Niels Thykier <niels at thykier.net>  Sat, 16 Mar 2019 08:34:04 +0000
+
 javatools (0.72.5) unstable; urgency=medium
 
   [ Markus Koschany ]


=====================================
jh_build
=====================================
@@ -234,7 +234,8 @@ sub do_build {
 		return;
 	}
 
-	my $dir = dirname($jarfile);
+	# dirname gets it wrong when $jarfile does not contain a slash (returning the basename instead).
+	my $dir = index($jarfile, '/') > -1 ? dirname($jarfile) : '.';
 	my $resolved_dir = realpath($dir) // error("Cannot resolve $dir: $!");
 	my $jarpath = "${resolved_dir}/${basename}";
 	complex_doit(qq{cd debian/_jh_build.$ext && @JAR cfm "$jarpath" ../_jh_manifest.$ext *});



View it on GitLab: https://salsa.debian.org/java-team/javatools/commit/805951237028af300c47fce95646663d7881a268

-- 
View it on GitLab: https://salsa.debian.org/java-team/javatools/commit/805951237028af300c47fce95646663d7881a268
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-java-commits/attachments/20190316/21254f3e/attachment.html>


More information about the pkg-java-commits mailing list