Source: javatools
Version: 0.72.10
Severity: wishlist
Tags: patch
User: reproducible-bui...@lists.alioth.debian.org
Usertags: toolchain randomness
X-Debbugs-Cc: reproducible-b...@lists.alioth.debian.org

Hi,

Whilst working on the Reproducible Builds effort [0] we noticed that
jssc could not be built reproducibly. I eventually tracked this down
and I think this is very similar to a similar, older issue detailed
here:

  https://bugs.debian.org/926542
  
... as somehow debhelper itself was parsing this strangely and ending
up printing warnings such as:

   -s/--same-arch is deprecated; please use -a/--arch instead

If I applied the following patch to src:jssc then the build became
reproducible:

-       jh_build -o "-source 1.6 -target 1.6 -encoding UTF-8" 
--javadoc-opts="-source 1.6 -encoding UTF-8"
+       jh_build --javacopts "-source 1.6 -target 1.6 -encoding UTF-8" 
--javadoc-opts="-source 1.6 -encoding UTF-8"

… but that seems a bit silly.

Patch for javastools attached that removes the "-o" option, but this
might not be the best idea (ie. one should likely deprecate it first,
such as how the -N short arg was also deprecated (see the top of the
jh_build file).

  [0] https://reproducible-builds.org/


Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      la...@debian.org / chris-lamb.co.uk
       `-


diff --git a/jh_build b/jh_build
index 51ce5dd..c489a47 100755
--- a/jh_build
+++ b/jh_build
@@ -136,7 +136,7 @@ init(options => {
        'no-javadoc' => sub { $build_javadoc = 0; },
        'clean' => \$do_clean,
        # Space-separated list of options
-       'javacopts|o=s' => sub { @javac_opts = split(' ', $_[1])},
+       'javacopts=s' => sub { @javac_opts = split(' ', $_[1])},
        'javadoc-opts=s' => sub { @javadoc_opts = split(' ', $_[1])},
 });
 

Reply via email to