This is an automated email from the git hooks/post-receive script. ebourg-guest pushed a commit to branch master in repository jxplorer.
commit 6f2039a7fe77f04ec60d78d58c9b8a8899778949 Author: Emmanuel Bourg <ebo...@apache.org> Date: Thu Mar 8 00:36:11 2018 +0100 Fixed the build failure with Java 9 (Closes: #875591) --- debian/changelog | 7 ++ debian/patches/05-java9-compatibility.patch | 158 ++++++++++++++++++++++++++++ debian/patches/series | 1 + debian/rules | 2 +- 4 files changed, 167 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index b7d8b53..d645876 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +jxplorer (3.3.2+dfsg-5) UNRELEASED; urgency=medium + + * Team upload. + * Fixed the build failure with Java 9 (Closes: #875591) + + -- Emmanuel Bourg <ebo...@apache.org> Thu, 08 Mar 2018 00:21:10 +0100 + jxplorer (3.3.2+dfsg-4) unstable; urgency=medium * Upload to unstable. diff --git a/debian/patches/05-java9-compatibility.patch b/debian/patches/05-java9-compatibility.patch new file mode 100644 index 0000000..30772d9 --- /dev/null +++ b/debian/patches/05-java9-compatibility.patch @@ -0,0 +1,158 @@ +--- a/src/com/ca/directory/jxplorer/editor/audioeditor.java ++++ b/src/com/ca/directory/jxplorer/editor/audioeditor.java +@@ -12,8 +12,6 @@ + import java.util.logging.Logger; + import java.util.logging.Level; + +-import sun.audio.*; +- + /** + * Simple audio editor that trys to play the audio clip. + * Allows the user to save and load audio clips from a file and +@@ -25,7 +23,7 @@ + protected CBButton btnPlay, btnStop; + protected JLabel label; + protected File file; +- protected AudioStream audioStream; ++// protected AudioStream audioStream; + protected audioaccessory audioAccess; + + private static Logger log = Logger.getLogger(audioeditor.class.getName()); +@@ -130,6 +128,7 @@ + */ + public void audioPlay() + { ++/* + try + { + audioStream = new AudioStream(new ByteArrayInputStream(bytes)); +@@ -144,6 +143,7 @@ + } + + AudioPlayer.player.start(audioStream); ++*/ + } + + /** +@@ -151,7 +151,7 @@ + */ + public void audioStop() + { +- AudioPlayer.player.stop(audioStream); ++// AudioPlayer.player.stop(audioStream); + } + + /** +@@ -276,4 +276,4 @@ + editMe.setValue(getNewValue()); + quit(); + } +-} +\ No newline at end of file ++} +--- a/src/com/ca/directory/jxplorer/editor/audioaccessory.java ++++ b/src/com/ca/directory/jxplorer/editor/audioaccessory.java +@@ -5,10 +5,8 @@ + // + import com.ca.commons.cbutil.CBButton; + import com.ca.commons.cbutil.CBIntText; +-import sun.applet.AppletAudioClip; + + import javax.swing.*; +-import java.applet.AudioClip; + import java.awt.*; + import java.awt.event.ActionEvent; + import java.awt.event.ActionListener; +@@ -19,7 +17,7 @@ + + public class audioaccessory extends JPanel implements PropertyChangeListener { + +- protected AudioClip currentClip; ++//protected AudioClip currentClip; + protected String currentName=""; + protected JLabel fileLabel; + protected CBButton playButton, stopButton, helpButton; +@@ -41,6 +39,7 @@ + + playButton.addActionListener(new ActionListener() { + public void actionPerformed(ActionEvent e) { ++/* + if (currentClip != null) { + if (unSupported){ + infoBox = new JOptionPane(); //TE: information box added to inform user that certain types of audio can't be played. +@@ -50,13 +49,16 @@ + currentClip.stop(); + currentClip.play(); + } ++*/ + } + }); + stopButton.addActionListener(new ActionListener() { + public void actionPerformed(ActionEvent e) { ++/* + if (currentClip != null) { + currentClip.stop(); + } ++*/ + } + }); + } +@@ -109,16 +111,16 @@ + if (name.equals(currentName)) { + return; + } +- if (currentClip != null) { currentClip.stop(); } ++// if (currentClip != null) { currentClip.stop(); } + currentName = name; + try { + URL u = f.getAbsoluteFile().toURL(); // CB try to make URL handling more robust... + //URL u = new URL("file:///" + f.getAbsolutePath()); +- currentClip = new AppletAudioClip(u); ++// currentClip = new AppletAudioClip(u); + } + catch (Exception e) { + e.printStackTrace(); +- currentClip = null; ++// currentClip = null; + fileLabel.setText(CBIntText.get("Error loading clip.")); + } + fileLabel.setText(" " + name); +@@ -133,7 +135,7 @@ + + public void stopPlay() + { +- if(currentClip == null) {return;} +- currentClip.stop(); ++// if(currentClip == null) {return;} ++// currentClip.stop(); + } +-} +\ No newline at end of file ++} +--- a/src/com/ca/directory/jxplorer/tree/SmartTree.java ++++ b/src/com/ca/directory/jxplorer/tree/SmartTree.java +@@ -2176,7 +2176,8 @@ + * method to get the cursor to update properly. + */ + +- dragSource = new DragSource() ++ dragSource = new DragSource(); ++/* + { + protected DragSourceContext createDragSourceContext + (DragSourceContextPeer dscp, DragGestureEvent dgl, Cursor dragCursor, +@@ -2191,6 +2192,7 @@ + }; + } + }; ++*/ + + + DragGestureRecognizer dgr = dragSource.createDefaultDragGestureRecognizer(this, +@@ -2568,4 +2570,4 @@ + refresh(root.parentDN()); + } + } +-} +\ No newline at end of file ++} diff --git a/debian/patches/series b/debian/patches/series index 60e6806..b0e0a44 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -3,3 +3,4 @@ 01paths 02jkslocation 04connecthelp +05-java9-compatibility.patch diff --git a/debian/rules b/debian/rules index b002de7..c92d67a 100755 --- a/debian/rules +++ b/debian/rules @@ -22,7 +22,7 @@ override_dh_auto_build: -mkdir jars cd help && jar cf ../jars/jxplorer_help.jar * # build jxplorer - jh_build --javacopts="-source 1.5 -target 1.5" --javadoc-opts="-source 1.5" jxplorer.jar src + jh_build --javacopts="-source 1.7 -target 1.7" --javadoc-opts="-source 1.7" jxplorer.jar src # tests $(JAVA) com.ca.directory.jxplorer.viewer.tableviewer.TableViewerTestSuite $(JAVA) com.ca.commons.naming.NamingTestSuite -- Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/jxplorer.git _______________________________________________ pkg-java-commits mailing list pkg-java-comm...@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-java-commits