java-vm-2.eclass: Only call nsplugin functions if necessary
authorJames Le Cuirot <chewi@gentoo.org>
Fri, 1 Jan 2016 13:37:10 +0000 (13:37 +0000)
committerJames Le Cuirot <chewi@gentoo.org>
Fri, 1 Jan 2016 22:49:14 +0000 (22:49 +0000)
…when install_mozilla_plugin has been called. All these functions will
be removed soon so this is a transitional measure.

eclass/java-vm-2.eclass

index eb94451c7c39e0fca6f79b770490dbfae7ee8297..7a5ba834e51863d05f5eeadc0a4c924e9de7a2e3 100644 (file)
@@ -84,8 +84,11 @@ java-vm-2_pkg_postinst() {
                fi
        fi
 
-       java-vm_check-nsplugin
-       java_mozilla_clean_
+       if [[ "${_install_mozilla_plugin_called}" = 1 ]]; then
+               java-vm_check-nsplugin
+               java_mozilla_clean_
+       fi
+
        fdo-mime_desktop_database_update
 }
 
@@ -360,6 +363,8 @@ java_get_plugin_dir_() {
 # Register a netscape java-plugin.
 
 install_mozilla_plugin() {
+       _install_mozilla_plugin_called=1
+
        local plugin="${1}"
        local variant="${2}"