Welcome to PlantUML Q&A, where you can ask questions and receive answers from other members of the community.

You can also submit new features request and vote for them.

Compilation Network Issue

0 votes

Distro: Arch

Package Manager: Yaourt

Java Version:

$ java -version
java version "1.9.0-ea"
Java(TM) SE Runtime Environment (build 1.9.0-ea-b85)
Java HotSpot(TM) 64-Bit Server VM (build 1.9.0-ea-b85, mixed mode)

Issue: Does not compile with a JavaC error

Output:

   [mkdir] Created dir: /tmp/yaourt-tmp-kfries/aur-plantuml/src/plantuml-8030/build
   [javac] /tmp/yaourt-tmp-kfries/aur-plantuml/src/plantuml-8030/build.xml:23: warning: 'includeantruntime' was not set, defaulting to build.sysclasspath=last; set to false for repeatable builds
   [javac] Compiling 1838 source files to /tmp/yaourt-tmp-kfries/aur-plantuml/src/plantuml-8030/build
   [javac]  
   [javac]           WARNING
   [javac]  
   [javac] The -source switch defaults to 1.9 in JDK 1.9.
   [javac] If you specify -target 1.6 you now must also specify -source 1.6.
   [javac] Ant will implicitly add -source 1.6 for you.  Please change your build file.
   [javac] warning: [options] bootstrap class path not set in conjunction with -source 1.6
   [javac] warning: [options] source value 1.6 is obsolete and will be removed in a future release
   [javac] warning: [options] target value 1.6 is obsolete and will be removed in a future release
   [javac] warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
   [javac] /tmp/yaourt-tmp-kfries/aur-plantuml/src/plantuml-8030/src/net/sourceforge/plantuml/png/PngIOMetadata.java:47: warning: PNGMetadata is internal proprietary API and may be removed in a future release
   [javac] import com.sun.imageio.plugins.png.PNGMetadata;
   [javac]                                   ^
   [javac] /tmp/yaourt-tmp-kfries/aur-plantuml/src/plantuml-8030/src/net/sourceforge/plantuml/command/BlocLines.java:56: error: incompatible types: List<CAP#1> cannot be converted to List<CharSequence>
   [javac]             this.lines = Collections.unmodifiableList(lines);
   [javac]                                                      ^
   [javac]   where CAP#1 is a fresh type-variable:
   [javac]     CAP#1 extends CharSequence from capture of ? extends CharSequence
   [javac] /tmp/yaourt-tmp-kfries/aur-plantuml/src/plantuml-8030/src/net/sourceforge/plantuml/png/PngIOMetadata.java:56: warning: PNGMetadata is internal proprietary API and may be removed in a future release
   [javac]             final PNGMetadata pngMetadata = new PNGMetadata();
   [javac]                   ^
   [javac] /tmp/yaourt-tmp-kfries/aur-plantuml/src/plantuml-8030/src/net/sourceforge/plantuml/png/PngIOMetadata.java:56: warning: PNGMetadata is internal proprietary API and may be removed in a future release
   [javac]             final PNGMetadata pngMetadata = new PNGMetadata();
   [javac]                                                 ^
   [javac] /tmp/yaourt-tmp-kfries/aur-plantuml/src/plantuml-8030/src/net/sourceforge/plantuml/png/PngIOMetadata.java:60: warning: PNGMetadata is internal proprietary API and may be removed in a future release
   [javac]                     pngMetadata.pHYs_unitSpecifier = PNGMetadata.PHYS_UNIT_METER;
   [javac]                                                      ^
   [javac] Note: Some input files use or override a deprecated API.
   [javac] Note: Recompile with -Xlint:deprecation for details.
   [javac] Note: Some input files use unchecked or unsafe operations.
   [javac] Note: Recompile with -Xlint:unchecked for details.
   [javac] 1 error
   [javac] 8 warnings

BUILD FAILED

asked Oct 16, 2015 in bug by kfries6 (120 points)

2 Answers

0 votes
That's strange... We have not tried java 1.9 yet.

Is it possible for you to edit file BlocLines.java (which is in dir src/net/sourceforge/plantuml/command) ?

You can change line 56 from :

        this.lines = Collections.unmodifiableList(lines);

to

        this.lines = (List<CharSequence>) Collections.unmodifiableList(lines);

Or download the patched file from here https://dl.dropboxusercontent.com/u/13064071/BlocLines.java

And tell us if it's working better that way ?

Thanks!
answered Oct 16, 2015 by plantuml (125,190 points)
edited Oct 16, 2015 by plantuml
0 votes
This should be fixed in V8032.

Thanks for the report!
answered Nov 1, 2015 by plantuml (125,190 points)
Support This Project Offer 250 Mo! Follow PlantUML on Twitter
...