From 4f2d7949f03e1c198bc888f2d05f421d35c57e21 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Mon, 9 Oct 2017 18:53:29 +0100 Subject: reinit the tree, so we can have metadata --- net-p2p/vuze/files/build.xml | 68 +++++++++++++ net-p2p/vuze/files/vuze-4.1.0.0-pre | 75 ++++++++++++++ net-p2p/vuze/files/vuze-5.3.0.0-disable-osx.patch | 60 +++++++++++ .../vuze-5.3.0.0-disable-shared-plugins.patch | 33 +++++++ .../vuze/files/vuze-5.3.0.0-disable-updaters.patch | 45 +++++++++ net-p2p/vuze/files/vuze-5.3.0.0-java5.patch | 11 +++ .../vuze/files/vuze-5.3.0.0-remove-classpath.patch | 10 ++ .../vuze/files/vuze-5.3.0.0-unbundle-commons.patch | 110 +++++++++++++++++++++ .../vuze/files/vuze-5.3.0.0-unbundle-json.patch | 42 ++++++++ .../files/vuze-5.6.0.0-commons-lang-entities.patch | 51 ++++++++++ .../files/vuze-5.6.0.0-invalid-characters.patch | 26 +++++ net-p2p/vuze/files/vuze-5.7.2.0-disable-osx.patch | 71 +++++++++++++ net-p2p/vuze/files/vuze.desktop | 9 ++ 13 files changed, 611 insertions(+) create mode 100644 net-p2p/vuze/files/build.xml create mode 100644 net-p2p/vuze/files/vuze-4.1.0.0-pre create mode 100644 net-p2p/vuze/files/vuze-5.3.0.0-disable-osx.patch create mode 100644 net-p2p/vuze/files/vuze-5.3.0.0-disable-shared-plugins.patch create mode 100644 net-p2p/vuze/files/vuze-5.3.0.0-disable-updaters.patch create mode 100644 net-p2p/vuze/files/vuze-5.3.0.0-java5.patch create mode 100644 net-p2p/vuze/files/vuze-5.3.0.0-remove-classpath.patch create mode 100644 net-p2p/vuze/files/vuze-5.3.0.0-unbundle-commons.patch create mode 100644 net-p2p/vuze/files/vuze-5.3.0.0-unbundle-json.patch create mode 100644 net-p2p/vuze/files/vuze-5.6.0.0-commons-lang-entities.patch create mode 100644 net-p2p/vuze/files/vuze-5.6.0.0-invalid-characters.patch create mode 100644 net-p2p/vuze/files/vuze-5.7.2.0-disable-osx.patch create mode 100644 net-p2p/vuze/files/vuze.desktop (limited to 'net-p2p/vuze/files') diff --git a/net-p2p/vuze/files/build.xml b/net-p2p/vuze/files/build.xml new file mode 100644 index 000000000000..7b060c14b2f2 --- /dev/null +++ b/net-p2p/vuze/files/build.xml @@ -0,0 +1,68 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/net-p2p/vuze/files/vuze-4.1.0.0-pre b/net-p2p/vuze/files/vuze-4.1.0.0-pre new file mode 100644 index 000000000000..505a7e704df3 --- /dev/null +++ b/net-p2p/vuze/files/vuze-4.1.0.0-pre @@ -0,0 +1,75 @@ +# +# Copyright (c) 2005, Petteri Räty +# Copyright (c) 2004, Jochen Maes +# Copyright (c) 2004, Karl Trygve Kalleberg +# Copyright (c) 2004, Gentoo Foundation +# +# Licensed under the GNU General Public License, v2 + +# The Azureus config dir has moved +olddotazudir="${HOME}/.Azureus" +oldgentoocfg="${olddotazudir}/gentoo.config" +dotazudir="${HOME}/.azureus" +gentoocfg="${dotazudir}/gentoo.config" + +if [[ -f "${oldgentoocfg}" && -f "${gentoocfg}" ]]; then + cat > /dev/stderr < "${gentoocfg}" < /dev/stderr + echo 'Unsetting ${UI_OPTIONS} and trying to migrate to ${UI}' > /dev/stderr + if [[ ${UI_OPTIONS} = *--ui=console* ]]; then + UI=console + elif [[ ${UI_OPTIONS} = *--ui=swt* ]]; then + UI=swt + else + echo 'Could not make $UI from $UI_OPTIONS' > /dev/stderr + fi + unset UI_OPTIONS +fi + +if [[ -z "${UI}" ]]; then + echo '$UI not set defaulting to swt' > /dev/stderr + UI="swt" +fi + +[[ ! -e "${dotazudir}" ]] && create_initial_config diff --git a/net-p2p/vuze/files/vuze-5.3.0.0-disable-osx.patch b/net-p2p/vuze/files/vuze-5.3.0.0-disable-osx.patch new file mode 100644 index 000000000000..070dae2d7562 --- /dev/null +++ b/net-p2p/vuze/files/vuze-5.3.0.0-disable-osx.patch @@ -0,0 +1,60 @@ +--- a/org/gudy/azureus2/ui/swt/mainwindow/SWTThread.java ++++ b/org/gudy/azureus2/ui/swt/mainwindow/SWTThread.java +@@ -229,57 +229,6 @@ public class SWTThread { + } + }); + +- if (Constants.isOSX) { +- +- // On Cocoa, we get a Close trigger on display. Need to check if all +- // platforms send this. +- display.addListener(SWT.Close, new Listener() { +- public void handleEvent(Event event) { +- event.doit = UIFunctionsManager.getUIFunctions().dispose(false, false); +- } +- }); +- +- String platform = SWT.getPlatform(); +- // use reflection here so we decouple generic SWT from OSX specific stuff to an extent +- +- if (platform.equals("carbon")) { +- try { +- +- Class ehancerClass = Class.forName("org.gudy.azureus2.ui.swt.osx.CarbonUIEnhancer"); +- +- Constructor constructor = ehancerClass.getConstructor(new Class[] {}); +- +- constructor.newInstance(new Object[] {}); +- +- } catch (Throwable e) { +- +- Debug.printStackTrace(e); +- } +- } else if (platform.equals("cocoa")) { +- try { +- +- Class ehancerClass = Class.forName("org.gudy.azureus2.ui.swt.osx.CocoaUIEnhancer"); +- +- Method mGetInstance = ehancerClass.getMethod("getInstance", new Class[0]); +- Object claObj = mGetInstance.invoke(null, new Object[0] ); +- +- Method mHookAppMenu = claObj.getClass().getMethod("hookApplicationMenu", new Class[] {}); +- if (mHookAppMenu != null) { +- mHookAppMenu.invoke(claObj, new Object[0]); +- } +- +- Method mHookDocOpen = claObj.getClass().getMethod("hookDocumentOpen", new Class[] {}); +- if (mHookDocOpen != null) { +- mHookDocOpen.invoke(claObj, new Object[0]); +- } +- +- } catch (Throwable e) { +- +- Debug.printStackTrace(e); +- } +- } +- } +- + if (app != null) { + app.runInSWTThread(); + runner = new Thread(new AERunnable() { diff --git a/net-p2p/vuze/files/vuze-5.3.0.0-disable-shared-plugins.patch b/net-p2p/vuze/files/vuze-5.3.0.0-disable-shared-plugins.patch new file mode 100644 index 000000000000..b459c8b38308 --- /dev/null +++ b/net-p2p/vuze/files/vuze-5.3.0.0-disable-shared-plugins.patch @@ -0,0 +1,33 @@ +Disallow users to install into the shared plugin directory, +which they won't have write access to. This doesn't disable +shared plugins, just removes the installation UI. + + +--- a/org/gudy/azureus2/ui/swt/pluginsinstaller/IPWListPanel.java ++++ b/org/gudy/azureus2/ui/swt/pluginsinstaller/IPWListPanel.java +@@ -234,13 +234,13 @@ public class IPWListPanel extends AbstractWizardPanel { + } + + public boolean +- isNextEnabled() ++ isFinishEnabled() + { + return(((InstallPluginWizard)wizard).getPluginList().size() > 0 ); + } + +- public IWizardPanel getNextPanel() { +- return new IPWInstallModePanel(wizard,this); ++ public IWizardPanel getFinishPanel() { ++ return new IPWFinishPanel(wizard,this); + } + + public void updateList() { +@@ -252,7 +252,7 @@ public class IPWListPanel extends AbstractWizardPanel { + } + } + wizard.setPluginList( list ); +- wizard.setNextEnabled( isNextEnabled() ); ++ wizard.setFinishEnabled( isFinishEnabled() ); + + } + } diff --git a/net-p2p/vuze/files/vuze-5.3.0.0-disable-updaters.patch b/net-p2p/vuze/files/vuze-5.3.0.0-disable-updaters.patch new file mode 100644 index 000000000000..1bf78cf1009d --- /dev/null +++ b/net-p2p/vuze/files/vuze-5.3.0.0-disable-updaters.patch @@ -0,0 +1,45 @@ +--- a/org/gudy/azureus2/pluginsimpl/local/PluginInitializer.java ++++ b/org/gudy/azureus2/pluginsimpl/local/PluginInitializer.java +@@ -130,18 +130,6 @@ PluginInitializer + "Magnet URI Handler", + "true", + "false"}, +- { PluginManagerDefaults.PID_CORE_UPDATE_CHECKER, +- "org.gudy.azureus2.update.CoreUpdateChecker", +- "azbpcoreupdater", +- "CoreUpdater", +- "true", +- "true"}, +- { PluginManagerDefaults.PID_CORE_PATCH_CHECKER, +- "org.gudy.azureus2.update.CorePatchChecker", +- "azbpcorepatcher", +- "CorePatcher", +- "true", +- "true"}, + { PluginManagerDefaults.PID_PLATFORM_CHECKER, + "org.gudy.azureus2.platform.PlatformManagerPluginDelegate", + "azplatform2", +--- a/org/gudy/azureus2/pluginsimpl/update/PluginUpdatePlugin.java ++++ b/org/gudy/azureus2/pluginsimpl/update/PluginUpdatePlugin.java +@@ -562,6 +562,10 @@ PluginUpdatePlugin + } + } + ++ if ( pi.getPluginState().isShared()) { ++ continue; ++ } ++ + String mand = pi.getPluginProperties().getProperty( "plugin.mandatory"); + + boolean pi_mandatory = mand != null && mand.trim().toLowerCase().equals("true"); +--- a/org/gudy/azureus2/ui/swt/updater2/SWTUpdateChecker.java ++++ b/org/gudy/azureus2/ui/swt/updater2/SWTUpdateChecker.java +@@ -64,7 +64,7 @@ public class SWTUpdateChecker implements UpdatableComponent + public static void + initialize() + { +- PluginInitializer.getDefaultInterface().getUpdateManager().registerUpdatableComponent(new SWTUpdateChecker(),true); ++// PluginInitializer.getDefaultInterface().getUpdateManager().registerUpdatableComponent(new SWTUpdateChecker(),true); + } + + public SWTUpdateChecker() { diff --git a/net-p2p/vuze/files/vuze-5.3.0.0-java5.patch b/net-p2p/vuze/files/vuze-5.3.0.0-java5.patch new file mode 100644 index 000000000000..b6d2a59c43a2 --- /dev/null +++ b/net-p2p/vuze/files/vuze-5.3.0.0-java5.patch @@ -0,0 +1,11 @@ +--- a/build.xml ++++ b/build.xml +@@ -36,7 +36,7 @@ NOTE: You may need to set the ANT_OPTS="-Xmx512m" env prop in order to compil + + + +- ++ + + + diff --git a/net-p2p/vuze/files/vuze-5.3.0.0-remove-classpath.patch b/net-p2p/vuze/files/vuze-5.3.0.0-remove-classpath.patch new file mode 100644 index 000000000000..290b902203a8 --- /dev/null +++ b/net-p2p/vuze/files/vuze-5.3.0.0-remove-classpath.patch @@ -0,0 +1,10 @@ +--- a/build.xml ++++ b/build.xml +@@ -46,7 +46,6 @@ NOTE: You may need to set the ANT_OPTS="-Xmx512m" env prop in order to compil + + + +- + + + diff --git a/net-p2p/vuze/files/vuze-5.3.0.0-unbundle-commons.patch b/net-p2p/vuze/files/vuze-5.3.0.0-unbundle-commons.patch new file mode 100644 index 000000000000..deed0af9c7b2 --- /dev/null +++ b/net-p2p/vuze/files/vuze-5.3.0.0-unbundle-commons.patch @@ -0,0 +1,110 @@ +--- a/com/aelitis/azureus/core/metasearch/Result.java ++++ b/com/aelitis/azureus/core/metasearch/Result.java +@@ -27,7 +27,7 @@ import java.util.Locale; + import java.util.Map; + import java.util.Random; + +-import org.apache.commons.lang.Entities; ++import org.apache.commons.lang.StringEscapeUtils; + import org.gudy.azureus2.core3.util.DisplayFormatters; + import org.json.simple.JSONObject; + +@@ -372,6 +372,6 @@ public abstract class Result { + if ( input == null ){ + return( null ); + } +- return( Entities.HTML40.unescape( input )); ++ return( StringEscapeUtils.unescapeHtml( input )); + } + } +--- a/com/aelitis/azureus/core/metasearch/impl/web/WebResult.java ++++ b/com/aelitis/azureus/core/metasearch/impl/web/WebResult.java +@@ -88,14 +88,14 @@ public class WebResult extends Result { + public void setNameFromHTML(String name) { + if(name != null) { + name = removeHTMLTags(name); +- this.name = Entities.HTML40.unescape(name); ++ this.name = StringEscapeUtils.unescapeHtml(name); + } + } + + public void setCommentsFromHTML(String comments) { + if(comments != null) { + comments = removeHTMLTags(comments); +- comments = Entities.HTML40.unescape(comments); ++ comments = StringEscapeUtils.unescapeHtml(comments); + comments = comments.replaceAll(",", ""); + comments = comments.replaceAll(" ", ""); + try{ +@@ -108,7 +108,7 @@ public class WebResult extends Result { + public void setCategoryFromHTML(String category) { + if(category != null) { + category = removeHTMLTags(category); +- this.category = Entities.HTML40.unescape(category).trim(); ++ this.category = StringEscapeUtils.unescapeHtml(category).trim(); + /*int separator = this.category.indexOf(">"); + + if(separator != -1) { +@@ -133,7 +133,7 @@ public class WebResult extends Result { + public void setNbPeersFromHTML(String nbPeers) { + if(nbPeers != null) { + nbPeers = removeHTMLTags(nbPeers); +- String nbPeersS = Entities.HTML40.unescape(nbPeers); ++ String nbPeersS = StringEscapeUtils.unescapeHtml(nbPeers); + nbPeersS = nbPeersS.replaceAll(",", ""); + nbPeersS = nbPeersS.replaceAll(" ", ""); + try { +@@ -148,7 +148,7 @@ public class WebResult extends Result { + public void setNbSeedsFromHTML(String nbSeeds) { + if(nbSeeds != null) { + nbSeeds = removeHTMLTags(nbSeeds); +- String nbSeedsS = Entities.HTML40.unescape(nbSeeds); ++ String nbSeedsS = StringEscapeUtils.unescapeHtml(nbSeeds); + nbSeedsS = nbSeedsS.replaceAll(",", ""); + nbSeedsS = nbSeedsS.replaceAll(" ", ""); + try { +@@ -163,7 +163,7 @@ public class WebResult extends Result { + public void setNbSuperSeedsFromHTML(String nbSuperSeeds) { + if(nbSuperSeeds != null) { + nbSuperSeeds = removeHTMLTags(nbSuperSeeds); +- String nbSuperSeedsS = Entities.HTML40.unescape(nbSuperSeeds); ++ String nbSuperSeedsS = StringEscapeUtils.unescapeHtml(nbSuperSeeds); + nbSuperSeedsS = nbSuperSeedsS.replaceAll(",", ""); + nbSuperSeedsS = nbSuperSeedsS.replaceAll(" ", ""); + try { +@@ -230,7 +230,7 @@ public class WebResult extends Result { + public void setPublishedDateFromHTML(String publishedDate) { + if(publishedDate != null) { + publishedDate = removeHTMLTags(publishedDate); +- String publishedDateS = Entities.HTML40.unescape(publishedDate).replace((char)160,(char)32); ++ String publishedDateS = StringEscapeUtils.unescapeHtml(publishedDate).replace((char)160,(char)32); + this.publishedDate = dateParser.parseDate(publishedDateS); + } + } +@@ -239,7 +239,7 @@ public class WebResult extends Result { + public void setSizeFromHTML(String size) { + if(size != null) { + size = removeHTMLTags(size); +- String sizeS = Entities.HTML40.unescape(size).replace((char)160,(char)32); ++ String sizeS = StringEscapeUtils.unescapeHtml(size).replace((char)160,(char)32); + sizeS = sizeS.replaceAll("<[^>]+>", " "); + //Add a space between the digits and unit if there is none + sizeS = sizeS.replaceFirst("(\\d)([a-zA-Z])", "$1 $2"); +@@ -285,7 +285,7 @@ public class WebResult extends Result { + public void setVotesFromHTML(String votes_str) { + if(votes_str != null) { + votes_str = removeHTMLTags(votes_str); +- votes_str = Entities.HTML40.unescape(votes_str); ++ votes_str = StringEscapeUtils.unescapeHtml(votes_str); + votes_str = votes_str.replaceAll(",", ""); + votes_str = votes_str.replaceAll(" ", ""); + try { +@@ -299,7 +299,7 @@ public class WebResult extends Result { + public void setVotesDownFromHTML(String votes_str) { + if(votes_str != null) { + votes_str = removeHTMLTags(votes_str); +- votes_str = Entities.HTML40.unescape(votes_str); ++ votes_str = StringEscapeUtils.unescapeHtml(votes_str); + votes_str = votes_str.replaceAll(",", ""); + votes_str = votes_str.replaceAll(" ", ""); + try { diff --git a/net-p2p/vuze/files/vuze-5.3.0.0-unbundle-json.patch b/net-p2p/vuze/files/vuze-5.3.0.0-unbundle-json.patch new file mode 100644 index 000000000000..18d5ac7670ff --- /dev/null +++ b/net-p2p/vuze/files/vuze-5.3.0.0-unbundle-json.patch @@ -0,0 +1,42 @@ +--- a/com/aelitis/azureus/util/ImportExportUtils.java ++++ b/com/aelitis/azureus/util/ImportExportUtils.java +@@ -360,7 +360,7 @@ public final class ImportExportUtils { + + throws IOException + { +- List l = new JSONArray(data.length); ++ List l = new JSONArray(); + + map.put( key, l ); + +--- a/com/aelitis/azureus/util/JSONUtils.java ++++ b/com/aelitis/azureus/util/JSONUtils.java +@@ -74,7 +74,7 @@ public class JSONUtils + * @since 3.0.1.5 + */ + public static JSONObject encodeToJSONObject(Map map) { +- JSONObject newMap = new JSONObject((int)(map.size()*1.5)); ++ JSONObject newMap = new JSONObject(); + + for (Map.Entry entry: ((Map)map).entrySet()){ + String key = entry.getKey(); +@@ -105,9 +105,7 @@ public class JSONUtils + */ + public static String encodeToJSON(Map map) { + JSONObject jobj = encodeToJSONObject(map); +- StringBuilder sb = new StringBuilder(8192); +- jobj.toString( sb ); +- return( sb.toString()); ++ return( jobj.toString()); + } + + public static String encodeToJSON(Collection list) { +@@ -138,7 +136,7 @@ public class JSONUtils + * @since 3.0.1.5 + */ + private static JSONArray encodeToJSONArray(Collection list) { +- JSONArray newList = new JSONArray(list.size()); ++ JSONArray newList = new JSONArray(); + + for ( Object value: list ){ + diff --git a/net-p2p/vuze/files/vuze-5.6.0.0-commons-lang-entities.patch b/net-p2p/vuze/files/vuze-5.6.0.0-commons-lang-entities.patch new file mode 100644 index 000000000000..c58d475995ee --- /dev/null +++ b/net-p2p/vuze/files/vuze-5.6.0.0-commons-lang-entities.patch @@ -0,0 +1,51 @@ +diff --git a/org/gudy/azureus2/core3/util/AddressUtils.java b/org/gudy/azureus2/core3/util/AddressUtils.java +index 6691951..38f14ee 100644 +--- a/org/gudy/azureus2/core3/util/AddressUtils.java ++++ b/org/gudy/azureus2/core3/util/AddressUtils.java +@@ -494,11 +494,11 @@ AddressUtils + try{ + // unfortunately we have an incompatible base64 standard in i2p, they replaced / with ~ and + with - + +- char[] encoded = to_decode.toCharArray(); ++ byte[] encoded = to_decode.getBytes(); + + for ( int i=0;i ehancerClass = Class.forName("org.gudy.azureus2.ui.swt.osx.CarbonUIEnhancer"); +- +- Constructor constructor = ehancerClass.getConstructor(new Class[] {}); +- +- constructor.newInstance(new Object[] {}); +- +- } catch (Throwable e) { +- +- Debug.printStackTrace(e); +- } +- } else if (platform.equals("cocoa")) { +- try { +- +- Class ehancerClass = Class.forName("org.gudy.azureus2.ui.swt.osx.CocoaUIEnhancer"); +- +- Method mGetInstance = ehancerClass.getMethod("getInstance", new Class[0]); +- Object claObj = mGetInstance.invoke(null, new Object[0] ); +- +- Method mHookAppMenu = claObj.getClass().getMethod("hookApplicationMenu", new Class[] {}); +- if (mHookAppMenu != null) { +- mHookAppMenu.invoke(claObj, new Object[0]); +- } +- +- Method mHookDocOpen = claObj.getClass().getMethod("hookDocumentOpen", new Class[] {}); +- if (mHookDocOpen != null) { +- mHookDocOpen.invoke(claObj, new Object[0]); +- } +- +- Method mIsRetinaDisplay = claObj.getClass().getMethod("isRetinaDisplay"); +- if (mIsRetinaDisplay != null) { +- isRetinaDisplay = (Boolean) mIsRetinaDisplay.invoke(claObj); +- } +- +- +- } catch (Throwable e) { +- +- Debug.printStackTrace(e); +- } +- } +- } +- + if (app != null) { + app.runInSWTThread(); + runner = new Thread(new AERunnable() { diff --git a/net-p2p/vuze/files/vuze.desktop b/net-p2p/vuze/files/vuze.desktop new file mode 100644 index 000000000000..cee9fcae3824 --- /dev/null +++ b/net-p2p/vuze/files/vuze.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Name=Vuze +Comment=Vuze BitTorrent Client +Exec=vuze +Icon=vuze +Terminal=false +Categories=Network; +Type=Application +MimeType=application/x-bittorrent; -- cgit v1.2.3