changeset in /hg/icedtea6: More refactoring -- the last big one ...

Deepak Bhole dbhole at redhat.com
Thu Oct 2 13:49:34 PDT 2008


changeset 358cb21c4730 in /hg/icedtea6
details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=358cb21c4730
description:
	More refactoring -- the last big one in the forseeable future.

	Implemented proper sandbox for liveconnect calls.

	Added error detection in the plugin, so it doesn't loop forever if Java side
	encounters an error.

diffstat:

30 files changed, 2483 insertions(+), 2274 deletions(-)
.hgignore                                                                     |    1 
ChangeLog                                                                     |   44 
IcedTeaPlugin.cc                                                              |  214 +-
Makefile.am                                                                   |   31 
plugin/icedtea/org/classpath/icedtea/plugin/GetMemberPluginCallRequest.java   |   78 
plugin/icedtea/org/classpath/icedtea/plugin/GetWindowPluginCallRequest.java   |   76 
plugin/icedtea/org/classpath/icedtea/plugin/PluginAppletSecurityContext.java  |  855 --------
plugin/icedtea/org/classpath/icedtea/plugin/PluginCallRequestFactoryImpl.java |   22 
plugin/icedtea/org/classpath/icedtea/plugin/PluginMain.java                   |  193 -
plugin/icedtea/org/classpath/icedtea/plugin/PluginMessageConsumer.java        |   76 
plugin/icedtea/org/classpath/icedtea/plugin/PluginMessageHandlerWorker.java   |   79 
plugin/icedtea/org/classpath/icedtea/plugin/PluginObjectStore.java            |  119 -
plugin/icedtea/org/classpath/icedtea/plugin/PluginStreamHandlerImpl.java      |  362 ---
plugin/icedtea/org/classpath/icedtea/plugin/RequestQueue.java                 |   40 
plugin/icedtea/org/classpath/icedtea/plugin/TestEnv.java                      |  172 -
plugin/icedtea/org/classpath/icedtea/plugin/VoidPluginCallRequest.java        |   69 
plugin/icedtea/sun/applet/AppletSecurityContext.java                          |   25 
plugin/icedtea/sun/applet/AppletSecurityContextManager.java                   |    6 
plugin/icedtea/sun/applet/GetMemberPluginCallRequest.java                     |   76 
plugin/icedtea/sun/applet/GetWindowPluginCallRequest.java                     |   75 
plugin/icedtea/sun/applet/PluginAppletSecurityContext.java                    | 1021 ++++++++++
plugin/icedtea/sun/applet/PluginCallRequestFactory.java                       |   19 
plugin/icedtea/sun/applet/PluginMain.java                                     |  188 +
plugin/icedtea/sun/applet/PluginMessageConsumer.java                          |   67 
plugin/icedtea/sun/applet/PluginMessageHandlerWorker.java                     |   78 
plugin/icedtea/sun/applet/PluginObjectStore.java                              |  121 +
plugin/icedtea/sun/applet/PluginStreamHandler.java                            |  371 +++
plugin/icedtea/sun/applet/RequestQueue.java                                   |   39 
plugin/icedtea/sun/applet/TestEnv.java                                        |  172 +
plugin/icedtea/sun/applet/VoidPluginCallRequest.java                          |   68 

diffs (truncated from 5148 to 500 lines):

diff -r f4981f8a1720 -r 358cb21c4730 .hgignore
--- a/.hgignore	Wed Oct 01 05:52:01 2008 -0400
+++ b/.hgignore	Wed Oct 01 16:40:56 2008 -0400
@@ -25,7 +25,6 @@ gcjwebplugin.so
 gcjwebplugin.so
 IcedTeaPlugin.o
 IcedTeaPlugin.so
-IcedTeaPlugin.jar
 extra-source-files.txt
 rt-source-files.txt
 hotspot-tools-source-files.txt
diff -r f4981f8a1720 -r 358cb21c4730 ChangeLog
--- a/ChangeLog	Wed Oct 01 05:52:01 2008 -0400
+++ b/ChangeLog	Wed Oct 01 16:40:56 2008 -0400
@@ -1,3 +1,47 @@ 2008-10-01  Gary Benson  <gbenson at redhat
+2008-10-01	Deepak Bhole <dbhole at redhat.com>
+	* .hgignore: Removed IcedTeaPlugin.jar
+	* IcedTeaPlugin.cc: Updated classpath when launching Java. added checks to
+	detect error on Java side.
+	* Makefile.am: Updated to fit new refactored files.
+	* plugin/icedtea/sun/applet/AppletSecurityContextManager.java: New file,
+	moved out of org/classpath/icedtea/plugin/, as a result of refactoring.
+	* plugin/icedtea/sun/applet/PluginCallRequestFactory.java: Same.
+	* plugin/icedtea/sun/applet/PluginStreamHandler.java: Same.
+	* plugin/icedtea/sun/applet/GetMemberPluginCallRequest.java: Same.
+	* plugin/icedtea/sun/applet/GetWindowPluginCallRequest.java: Same.
+	* plugin/icedtea/sun/applet/PluginAppletSecurityContext.java: Same.
+	* plugin/icedtea/sun/applet/PluginMain.java: Same.
+	* plugin/icedtea/sun/applet/PluginMessageConsumer.java: Same.
+	* plugin/icedtea/sun/applet/PluginMessageHandlerWorker.java: Same.
+	* plugin/icedtea/sun/applet/PluginObjectStore.java: Same.
+	* plugin/icedtea/sun/applet/RequestQueue.java: Same.
+	* plugin/icedtea/sun/applet/TestEnv.java: Same.
+	* plugin/icedtea/sun/applet/VoidPluginCallRequest.java: Same.
+	* plugin/icedtea/org/classpath/icedtea/plugin/GetMemberPluginCallRequest.java: 
+	Removed, as a result of refactoring.
+	* plugin/icedtea/org/classpath/icedtea/plugin/GetWindowPluginCallRequest.java:
+	Same.
+	*plugin/icedtea/org/classpath/icedtea/plugin/PluginAppletSecurityContext.java:
+	Same.
+	* plugin/icedtea/org/classpath/icedtea/plugin/PluginCallRequestFactoryImpl.java:
+	Same.
+	* plugin/icedtea/org/classpath/icedtea/plugin/PluginMain.java: Same.
+	* plugin/icedtea/org/classpath/icedtea/plugin/PluginMessageConsumer.java:
+	Same.
+	*
+	plugin/icedtea/org/classpath/icedtea/plugin/PluginMessageHandlerWorker.java:
+	Same.
+	* plugin/icedtea/org/classpath/icedtea/plugin/PluginObjectStore.java:
+	Same.
+	*
+	plugin/icedtea/org/classpath/icedtea/plugin/PluginStreamHandlerImpl.java:
+	Same.
+	* plugin/icedtea/org/classpath/icedtea/plugin/RequestQueue.java: Same.
+	* plugin/icedtea/org/classpath/icedtea/plugin/TestEnv.java: Same.
+	* plugin/icedtea/org/classpath/icedtea/plugin/VoidPluginCallRequest.java:
+	Same.
+	* plugin/icedtea/sun/applet/AppletSecurityContext.java: Same.
+
 2008-10-01  Gary Benson  <gbenson at redhat.com>
 
 	* ports/hotspot/src/share/vm/shark/sharkState.cpp: Remove a
diff -r f4981f8a1720 -r 358cb21c4730 IcedTeaPlugin.cc
--- a/IcedTeaPlugin.cc	Wed Oct 01 05:52:01 2008 -0400
+++ b/IcedTeaPlugin.cc	Wed Oct 01 16:40:56 2008 -0400
@@ -244,7 +244,6 @@ static GError* channel_error = NULL;
 static GError* channel_error = NULL;
 // Fully-qualified appletviewer executable.
 static char* appletviewer_executable = NULL;
-static char* extra_jars = NULL;
 static char* libjvm_so = NULL;
 
 class IcedTeaPluginFactory;
@@ -317,8 +316,6 @@ char const* TYPES[10] = { "Object",
   char context[16]; \
   GetCurrentPageAddress(&addr); \
   GetCurrentContextAddr(context); \
-  printf("Addr: %s , Context: %s\n", addr, context);\
-\
   nsCString message ("context ");                            \
   message.AppendInt (0);                                     \
   message += " reference ";                                  \
@@ -428,12 +425,14 @@ char const* TYPES[10] = { "Object",
 #define MESSAGE_RECEIVE_REFERENCE(reference, cast, name)                \
   nsresult res = NS_OK;                                                 \
   printf ("RECEIVE 1\n");                                               \
-  while (factory->result_map[reference]->returnIdentifier == -1)     \
+  while (factory->result_map[reference]->returnIdentifier == -1 &&\
+	     factory->result_map[reference]->errorOccured == PR_FALSE)     \
     {                                                                   \
       PROCESS_PENDING_EVENTS_REF (reference);                                \
     }                                                                   \
   printf ("RECEIVE 3\n"); \
-  if (factory->result_map[reference]->returnIdentifier == 0) \
+  if (factory->result_map[reference]->returnIdentifier == 0 || \
+	  factory->result_map[reference]->errorOccured == PR_TRUE) \
   {  \
 	  *name = NULL;                                                     \
   } else {                                                              \
@@ -449,25 +448,33 @@ char const* TYPES[10] = { "Object",
   PRBool processed = PR_FALSE;                                          \
   nsresult res = NS_OK;                                                 \
   printf("RECEIVE ID 1\n");                                             \
-  while (factory->result_map[reference]->returnIdentifier == -1)     \
+  while (factory->result_map[reference]->returnIdentifier == -1 &&\
+	     factory->result_map[reference]->errorOccured == PR_FALSE)     \
     {                                                                   \
       PROCESS_PENDING_EVENTS_REF (reference);                                \
     }                                                                   \
                                                                         \
+  if (factory->result_map[reference]->errorOccured == PR_TRUE)	 	    \
+  { \
+	  *id = NULL; \
+  } else \
+  { \
   *id = reinterpret_cast<cast>                                  \
     (new JNIID (factory->result_map[reference]->returnIdentifier, signature));         \
    printf ("RECEIVE_ID: %s result: %x = %d, %s\n",               \
            __func__, *id, factory->result_map[reference]->returnIdentifier,             \
-           signature);
+           signature); \
+  }
 
 #define MESSAGE_RECEIVE_VALUE(reference, ctype, result)                    \
   nsresult res = NS_OK;                                                    \
   printf("RECEIVE VALUE 1\n");                                             \
-  while (factory->result_map[reference]->returnValue == "")            \
+  while (factory->result_map[reference]->returnValue == "" && \
+	     factory->result_map[reference]->errorOccured == PR_FALSE)            \
     {                                                                      \
       PROCESS_PENDING_EVENTS_REF (reference);                                   \
     }                                                                      \
-  *result = ParseValue (type, factory->result_map[reference]->returnValue);            
+    *result = ParseValue (type, factory->result_map[reference]->returnValue);            
 // \
 //   char* valueString = ValueString (type, *result);              \
 //   printf ("RECEIVE_VALUE: %s result: %x = %s\n",                \
@@ -479,13 +486,19 @@ char const* TYPES[10] = { "Object",
   PRBool processed = PR_FALSE;                                  \
   nsresult res = NS_OK;                                         \
   printf("RECEIVE SIZE 1\n");                                 \
-  while (factory->result_map[reference]->returnValue == "")                        \
+  while (factory->result_map[reference]->returnValue == "" && \
+	     factory->result_map[reference]->errorOccured == PR_FALSE) \
     {                                                           \
       PROCESS_PENDING_EVENTS_REF (reference);                        \
     }                                                           \
   nsresult conversionResult;                                    \
-  *result = factory->result_map[reference]->returnValue.ToInteger (&conversionResult); \
-  PLUGIN_CHECK ("parse integer", conversionResult);             
+  if (factory->result_map[reference]->errorOccured == PR_TRUE) \
+	*result = NULL; \
+  else \
+  { \
+    *result = factory->result_map[reference]->returnValue.ToInteger (&conversionResult); \
+    PLUGIN_CHECK ("parse integer", conversionResult);             \
+  }
 // \
 //   printf ("RECEIVE_SIZE: %s result: %x = %d\n",                 \
 //           __func__, result, *result);
@@ -495,13 +508,19 @@ char const* TYPES[10] = { "Object",
   PRBool processed = PR_FALSE;                                  \
   nsresult res = NS_OK;                                         \
   printf("RECEIVE STRING 1\n");                                 \
-  while (factory->result_map[reference]->returnValue == "")                            \
+  while (factory->result_map[reference]->returnValue == "" && \
+	     factory->result_map[reference]->errorOccured == PR_FALSE)  \
     {                                                           \
       PROCESS_PENDING_EVENTS_REF (reference);                        \
     }                                                           \
-	printf("Setting result to: %s\n", strdup (factory->result_map[reference]->returnValue.get ())); \
-  *result = reinterpret_cast<char_type const*>                  \
-    (strdup (factory->result_map[reference]->returnValue.get ()));                     
+	if (factory->result_map[reference]->errorOccured == PR_TRUE) \
+		*result = NULL; \
+	else \
+	{\
+	  printf("Setting result to: %s\n", strdup (factory->result_map[reference]->returnValue.get ())); \
+      *result = reinterpret_cast<char_type const*>                  \
+                (strdup (factory->result_map[reference]->returnValue.get ()));\
+	}
 // \
 //   printf ("RECEIVE_STRING: %s result: %x = %s\n",               \
 //           __func__, result, *result);
@@ -511,16 +530,22 @@ char const* TYPES[10] = { "Object",
   PRBool processed = PR_FALSE;                                  \
   nsresult res = NS_OK;                                         \
   printf("RECEIVE STRING UCS 1\n");                                 \
-  while (factory->result_map[reference]->returnValueUCS.IsEmpty())                        \
+  while (factory->result_map[reference]->returnValueUCS.IsEmpty() && \
+	     factory->result_map[reference]->errorOccured == PR_FALSE) \
     {                                                           \
       PROCESS_PENDING_EVENTS_REF (reference);                        \
     }                                                           \
-  int length = factory->result_map[reference]->returnValueUCS.Length ();               \
-  jchar* newstring = static_cast<jchar*> (PR_Malloc (length));  \
-  memset (newstring, 0, length);                                \
-  memcpy (newstring, factory->result_map[reference]->returnValueUCS.get (), length);   \
-  std::cout << "Setting result to: " << factory->result_map[reference]->returnValueUCS.get() << std::endl; \
-  *result = static_cast<jchar const*> (newstring);
+	if (factory->result_map[reference]->errorOccured == PR_TRUE) \
+		*result = NULL; \
+	else \
+	{ \
+	  int length = factory->result_map[reference]->returnValueUCS.Length ();               \
+	  jchar* newstring = static_cast<jchar*> (PR_Malloc (length));  \
+	  memset (newstring, 0, length);                                \
+	  memcpy (newstring, factory->result_map[reference]->returnValueUCS.get (), length);   \
+	  std::cout << "Setting result to: " << factory->result_map[reference]->returnValueUCS.get() << std::endl; \
+	  *result = static_cast<jchar const*> (newstring); \
+	}
 
 // \
 //   printf ("RECEIVE_STRING: %s result: %x = %s\n",               \
@@ -530,11 +555,15 @@ char const* TYPES[10] = { "Object",
   PRBool processed = PR_FALSE;                                  \
   nsresult res = NS_OK;                                         \
   printf("RECEIVE BOOLEAN 1\n");                             \
-  while (factory->result_map[reference]->returnIdentifier == -1)               \
+  while (factory->result_map[reference]->returnIdentifier == -1 && \
+	     factory->result_map[reference]->errorOccured == PR_FALSE)               \
     {                                                           \
       PROCESS_PENDING_EVENTS_REF (reference);                        \
     }                                                           \
-  *result = factory->result_map[reference]->returnIdentifier;
+	if (factory->result_map[reference]->errorOccured == PR_TRUE) \
+		*result = NULL; \
+	else \
+	  *result = factory->result_map[reference]->returnIdentifier;
 //      res = factory->current->ProcessNextEvent (PR_TRUE,        \
 //                                                &processed);    \
 //      PLUGIN_CHECK_RETURN (__func__, res);                      \
@@ -1225,9 +1254,57 @@ template <class T> NS_IMETHODIMP
 template <class T> NS_IMETHODIMP
 IcedTeaRunnableMethod<T>::Run ()
 {
-  (object->*method) ();
-  return NS_OK;
-}
+    (object->*method) ();
+    return NS_OK;
+}
+
+
+// FIXME: Special class just for dispatching GetURL to another 
+// thread.. seriously, a class just for that? there has to be a better way!
+
+class GetURLRunnable : public nsIRunnable
+{
+public:
+  NS_DECL_ISUPPORTS
+  NS_DECL_NSIRUNNABLE
+
+  GetURLRunnable (nsIPluginInstancePeer* peer, const char* url, const char* target);
+
+  ~GetURLRunnable ();
+
+private:
+  nsIPluginInstancePeer* peer;
+  const char* url;
+  const char* target;
+};
+
+NS_IMPL_ISUPPORTS1 (GetURLRunnable, nsIRunnable)
+
+GetURLRunnable::GetURLRunnable (nsIPluginInstancePeer* peer, const char* url, const char* target)
+: peer(peer),
+  url(url),
+  target(target)
+{
+    NS_ADDREF (peer);
+}
+
+GetURLRunnable::~GetURLRunnable ()
+{
+  NS_RELEASE(peer);
+}
+
+NS_IMETHODIMP
+GetURLRunnable::Run ()
+{
+   nsCOMPtr<nsPIPluginInstancePeer> ownerGetter =
+                do_QueryInterface (peer);
+   nsIPluginInstanceOwner* owner = nsnull;
+   ownerGetter->GetOwner (&owner);
+
+   return owner->GetURL ((const char*) url, (const char*) target,
+                         nsnull, 0, nsnull, 0);
+}
+
 
 NS_IMPL_ISUPPORTS6 (IcedTeaPluginFactory, nsIFactory, nsIPlugin, nsIJVMManager,
                     nsIJVMPrefsWindow, nsIJVMPlugin, nsIInputStreamCallback)
@@ -2433,6 +2510,11 @@ IcedTeaPluginFactory::OnInputStreamReady
   return NS_OK;
 }
 
+#include <nsIWebNavigation.h>
+#include <nsServiceManagerUtils.h>
+#include <nsIExternalProtocolService.h>
+#include <nsNetUtil.h>
+
 void
 IcedTeaPluginFactory::HandleMessage (nsCString const& message)
 {
@@ -2477,8 +2559,11 @@ IcedTeaPluginFactory::HandleMessage (nsC
         {
           IcedTeaPluginInstance* instance = NULL;
           instances.Get (identifier, &instance);
-//          if (instance != 0)
-//            instance->peer->ShowStatus (nsCString (rest).get ());
+          if (instance != 0)
+		  {
+            instance->peer->ShowStatus (nsCString (rest).get ());
+
+          }
         }
       else if (command == "initialized")
         {
@@ -2504,9 +2589,10 @@ IcedTeaPluginFactory::HandleMessage (nsC
               nsIPluginInstanceOwner* owner = nsnull;
               ownerGetter->GetOwner (&owner);
 			  printf("Calling GetURL with %s and %s\n", nsCString (url).get (), nsCString (target).get ());
-              owner->GetURL (nsCString (url).get (),
-                             nsCString (target).get (),
-                             nsnull, 0, nsnull, 0);
+              nsCOMPtr<nsIRunnable> event = new GetURLRunnable (instance->peer,
+													 nsCString (url).get (),
+													 nsCString (target).get ());
+              current->Dispatch(event, nsIEventTarget::DISPATCH_NORMAL);
             }
         }
       else if (command == "GetWindow")
@@ -2841,20 +2927,47 @@ void IcedTeaPluginFactory::ProcessMessag
 void IcedTeaPluginFactory::ProcessMessage ()
 {
 	while (true) {
-		printf("Process thread sleeping...\n");
-		PR_Sleep(PR_INTERVAL_NO_TIMEOUT);
+		PR_Sleep(1000);
+
+		// If there was an interrupt, clear it
 		PR_ClearInterrupt();
-
-		printf("Process thread interrupted...\n");
-
 
 		// Was I interrupted for shutting down?
 		if (shutting_down == PR_TRUE) {
 			break;
 		}
 
-		ConsumeMsgFromJVM();
+		// Nope. Ok, is there work to do?
+		if (!jvmMsgQueue.empty())
+		    ConsumeMsgFromJVM();
+
+		// All done. Now let's process pending events
+
+		// Were there new events dispatched?
+		
+		PRBool this_has_pending, curr_has_pending, processed = PR_FALSE;
+		PRBool continue_processing = PR_TRUE;
+
+		while (continue_processing == PR_TRUE) {
+
+		  processThread->HasPendingEvents(&this_has_pending);
+		  if (this_has_pending == PR_TRUE) {
+			  processThread->ProcessNextEvent(PR_TRUE, &processed);
+			  printf("Pending event processed (this) ... %d\n", processed);
+		  }
+
+		  current->HasPendingEvents(&curr_has_pending);
+		  if (curr_has_pending == PR_TRUE) {
+			  current->ProcessNextEvent(PR_TRUE, &processed);
+			  printf("Pending event processed (current) ... %d\n", processed);
+		  }
+
+		  if (this_has_pending != PR_TRUE && curr_has_pending != PR_TRUE) {
+			  continue_processing = PR_FALSE;
+		  }
+		}
 	}
+
 }
 
 void IcedTeaPluginFactory::ConsumeMsgFromJVM ()
@@ -2872,9 +2985,7 @@ void IcedTeaPluginFactory::ConsumeMsgFro
 		HandleMessage (message);
 		printf("Processing complete\n");
 	}
-
-}
-
+}
 
 /**
  *
@@ -3189,9 +3300,9 @@ IcedTeaPluginFactory::StartAppletviewer 
   PLUGIN_CHECK_RETURN ("init process", result);
 
   // FIXME: hard-coded port number.
-  char const* args[8] = { "-classpath", extra_jars, "-Xdebug", "-Xnoagent", "-Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n", "org.classpath.icedtea.plugin.PluginMain", "50007" };
+  char const* args[5] = { "-Xdebug", "-Xnoagent", "-Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n", "sun.applet.PluginMain", "50007" };
 //  char const* args[2] = { "sun.applet.PluginMain", "50007" };
-  result = applet_viewer_process->Run (PR_FALSE, args, 8, nsnull);
+  result = applet_viewer_process->Run (PR_FALSE, args, 5, nsnull);
   PLUGIN_CHECK_RETURN ("run process", result);
 
   // start processing thread
@@ -3812,6 +3923,7 @@ nsresult
 nsresult
 IcedTeaJNIEnv::GetCurrentContextAddr(char *addr)
 {
+	return NS_OK;
     PLUGIN_TRACE_JNIENV ();
 
     // Get JSContext from stack.
@@ -3835,7 +3947,7 @@ nsresult
 nsresult
 IcedTeaJNIEnv::GetCurrentPageAddress(const char **addr)
 {
-
+	return NS_OK;
     PLUGIN_TRACE_JNIENV ();
 
     nsIPrincipal *prin;
@@ -4922,27 +5034,15 @@ NSGetFactory (nsISupports* aServMgr, nsC
 
   //executableString += nsCString ("/../../bin/pluginappletviewer");
   executable += nsCString ("/../../bin/java");
-  extrajars += jar;
-  extrajars += nsCString("/IcedTeaPlugin.jar");
-  extrajars += ":";
-  extrajars += jar;
-  extrajars += nsCString("/rt.jar");
 
   //executable += nsCString ("/client/libjvm.so");
 
   // Never freed.
   appletviewer_executable = strdup (executable.get ());
-  extra_jars = strdup (extrajars.get ());
   //libjvm_so = strdup (executable.get ());
   if (!appletviewer_executable)
     {
       PLUGIN_ERROR ("Failed to create java executable name.");
-      return NS_ERROR_OUT_OF_MEMORY;
-    }
-
-  if (!extra_jars)
-    {
-      PLUGIN_ERROR ("Failed to create plugin jar name.");
       return NS_ERROR_OUT_OF_MEMORY;
     }
 
diff -r f4981f8a1720 -r 358cb21c4730 Makefile.am
--- a/Makefile.am	Wed Oct 01 05:52:01 2008 -0400
+++ b/Makefile.am	Wed Oct 01 16:40:56 2008 -0400
@@ -12,13 +12,11 @@ if ENABLE_LIVECONNECT
 if ENABLE_LIVECONNECT
 ICEDTEAPLUGIN_CLEAN = clean-IcedTeaPlugin
 ICEDTEAPLUGIN_TARGET = IcedTeaPlugin.so
-ICEDTEAPLUGIN_JAR = IcedTeaPlugin.jar
 PLUGIN_PATCH = patches/icedtea-liveconnect.patch
 LIVECONNECT = $(abs_top_srcdir)/plugin/icedtea/
 else
 ICEDTEAPLUGIN_CLEAN =
 ICEDTEAPLUGIN_TARGET =
-ICEDTEAPLUGIN_JAR =
 PLUGIN_PATCH = patches/icedtea-plugin.patch
 LIVECONNECT = 
 if ENABLE_PLUGIN
@@ -48,7 +46,6 @@ distclean-local: clean-copy clean-jtreg 
 	rm -rf hotspot-tools
 if ENABLE_LIVECONNECT
 	rm -f IcedTeaPlugin.so
-	rm -rf IcedTeaPlugin.jar
 else
 if ENABLE_PLUGIN
 	rm -f gcjwebplugin.so
@@ -597,6 +594,7 @@ stamps/patch.stamp: stamps/patch-fsg.sta
 	fi
 if ENABLE_LIVECONNECT
 	cp -a plugin/icedtea/sun/applet/*java openjdk/jdk/src/share/classes/sun/applet/
+	cp -a plugin/icedtea/netscape openjdk/jdk/src/share/classes/
 endif
 
 clean-patch:
@@ -616,6 +614,7 @@ clean-patch:
 	if ! test x$${all_patches_ok} = "xyes" ; then \
 	  echo "WARNING Not all patches reverted cleanly" ; \
 	fi
+	rm -rf openjdk/jdk/src/share/classes/netscape
 	for file in plugin/icedtea/sun/applet/*java ; \
 	do \
 		rm -f openjdk/jdk/src/share/classes/sun/applet/`basename $file` ; \
@@ -911,7 +910,7 @@ stamps/icedtea.stamp: stamps/bootstrap-d
 stamps/icedtea.stamp: stamps/bootstrap-directory-symlink.stamp \
 	stamps/hotspot-tools.stamp stamps/plugs.stamp \
 	stamps/ports.stamp stamps/patch.stamp stamps/overlay.stamp \



More information about the distro-pkg-dev mailing list