[Jpackage-commits] dist/gwt/devel .cvsignore, 1.2, 1.3 Mozilla.java, NONE, 1.1 WebappClassLoader.java, NONE, 1.1 gwt-benchmarkViewer, NONE, 1.1 gwt-build.patch, 1.1, 1.2 gwt-i18nCreator, NONE, 1.1 gwt-java6.patch, NONE, 1.1 gwt-junitCreator, NONE, 1.1 gwt-mozilla.patch, NONE, 1.1 gwt-tomcat.patch, NONE, 1.1 gwt-webAppCreator, NONE, 1.1 gwt.spec, 1.1, 1.2 sources, 1.2, 1.3

David Walluck david at ryu.zarb.org
Wed Feb 25 22:20:51 CET 2009


Update of /home/projects/jpackage/cvs/dist/gwt/devel
In directory ryu.zarb.org:/tmp/cvs-serv4823

Modified Files:
	.cvsignore gwt-build.patch gwt.spec sources 
Added Files:
	Mozilla.java WebappClassLoader.java gwt-benchmarkViewer 
	gwt-i18nCreator gwt-java6.patch gwt-junitCreator 
	gwt-mozilla.patch gwt-tomcat.patch gwt-webAppCreator 
Log Message:
- build and script fixes

Index: .cvsignore
===================================================================
RCS file: /home/projects/jpackage/cvs/dist/gwt/devel/.cvsignore,v
retrieving revision 1.2
retrieving revision 1.3
diff -C 2 -d -r1.2 -r1.3
*** .cvsignore	21 Feb 2009 00:30:33 -0000	1.2
--- .cvsignore	25 Feb 2009 21:20:49 -0000	1.3
***************
*** 1,2 ****
- gwt-1.6.0-tools.tar.bz2
  gwt-1.6.0.tar.bz2
--- 1 ----

--- NEW FILE: gwt-i18nCreator ---
#!/bin/sh
#
# gwt-i18nCreator script
# JPackage Project <http://www.jpackage.org/>

# Source functions library
if [ -f /usr/share/java-utils/java-functions ] ; then
  . /usr/share/java-utils/java-functions
else
  echo "Can't find functions library, aborting"
  exit 1
fi

# Configuration
MAIN_CLASS="com.google.gwt.i18n.tools.I18NCreator"
BASE_FLAGS=""
BASE_OPTIONS=""
BASE_JARS="gwt-user servlet_2_5_api gwt-dev-linux"

# Set parameters
set_jvm
set_classpath $BASE_JARS
set_flags $BASE_FLAGS
set_options $BASE_OPTIONS

# Let's start
run "$@"

--- NEW FILE: gwt-tomcat.patch ---
--- gwt-1.6.0/dev/core/src/com/google/gwt/dev/shell/tomcat/EmbeddedTomcatServer.java.tomcat	2009-01-21 20:07:18.000000000 -0500
+++ gwt-1.6.0/dev/core/src/com/google/gwt/dev/shell/tomcat/EmbeddedTomcatServer.java	2009-02-25 12:43:38.283235904 -0500
@@ -24,17 +24,18 @@
 import com.google.gwt.dev.shell.WorkDirs;
 import com.google.gwt.util.tools.Utility;
 
-import org.apache.catalina.Connector;
+import org.apache.catalina.connector.Connector;
 import org.apache.catalina.ContainerEvent;
 import org.apache.catalina.ContainerListener;
 import org.apache.catalina.Engine;
 import org.apache.catalina.LifecycleException;
-import org.apache.catalina.Logger;
+import org.apache.catalina.Lifecycle;
+//import org.apache.catalina.Logger;
 import org.apache.catalina.core.StandardContext;
 import org.apache.catalina.core.StandardHost;
 import org.apache.catalina.startup.Embedded;
 import org.apache.catalina.startup.HostConfig;
-import org.apache.coyote.tomcat5.CoyoteConnector;
+//import org.apache.coyote.tomcat5.CoyoteConnector;
 
 import java.io.File;
 import java.io.FileOutputStream;
@@ -85,7 +86,7 @@
   // Stop the embedded Tomcat server.
   //
   public static synchronized void stop() {
-    if (sTomcat != null) {
+    if (sTomcat != null && sTomcat.catEmbedded != null) {
       try {
         sTomcat.catEmbedded.stop();
       } catch (LifecycleException e) {
@@ -107,6 +108,7 @@
    * Tomcat with GWT and know exactly what version it is.
    */
   private static int computeLocalPort(Connector connector) {
+/*
     Throwable caught = null;
     try {
       Field phField = CoyoteConnector.class.getDeclaredField("protocolHandler");
@@ -133,6 +135,29 @@
     }
     throw new RuntimeException(
         "Failed to retrieve the startup port from Embedded Tomcat", caught);
+*/
+    return -1;
+  }
+
+  private static int findFreeLocalPort() {
+    ServerSocket socket = null;
+
+    try {
+      socket = new ServerSocket(0);
+      return socket.getLocalPort();
+    } catch (IOException e) {
+
+    } finally {
+      if (socket != null) {
+        try {
+          socket.close();
+        } catch (IOException e) {
+
+        }
+      }
+    }
+
+    return -1;
   }
 
   private Embedded catEmbedded;
@@ -167,9 +192,9 @@
     //
     sTomcat = this;
 
-    // Assume the working directory is simply the user's current directory.
+    // Assume the working directory is simply the user's home directory.
     //
-    File topWorkDir = new File(System.getProperty("user.dir"));
+    File topWorkDir = new File(System.getProperty("user.home"));
 
     // Tell Tomcat its base directory so that it won't complain.
     //
@@ -190,13 +215,13 @@
 
     // And set up an adapter that will work with the Catalina logger family.
     //
-    Logger catalinaLogger = new CatalinaLoggerAdapter(topLogger);
+    //Logger catalinaLogger = new CatalinaLoggerAdapter(topLogger);
 
     // Create an embedded server.
     //
     catEmbedded = new Embedded();
-    catEmbedded.setDebug(0);
-    catEmbedded.setLogger(catalinaLogger);
+    //catEmbedded.setDebug(0);
+    //catEmbedded.setLogger(logger);
 
     // The embedded engine is called "gwt".
     //
@@ -221,7 +246,7 @@
     //
     catHost.addContainerListener(new ContainerListener() {
       public void containerEvent(ContainerEvent event) {
-        if (StandardHost.PRE_INSTALL_EVENT.equals(event.getType())) {
+        if (/*StandardHost.PRE_INSTALL_EVENT*/Lifecycle.BEFORE_START_EVENT.equals(event.getType())) {
           StandardContext webapp = (StandardContext) event.getData();
           publishShellLoggerAttribute(logger, topLogger, webapp);
           publishShellWorkDirsAttribute(logger, workDirs, webapp);
@@ -238,13 +263,20 @@
     //
     catEmbedded.addEngine(catEngine);
     InetAddress nullAddr = null;
-    Connector connector = catEmbedded.createConnector(nullAddr, listeningPort,
+
+    if (listeningPort == 0) {
+        port = findFreeLocalPort();
+    } else {
+        port = listeningPort;
+   }
+
+    Connector connector = catEmbedded.createConnector(nullAddr, /*listeningPort*/port,
         false);
     catEmbedded.addConnector(connector);
 
     // start up!
     catEmbedded.start();
-    port = computeLocalPort(connector);
+    //port = computeLocalPort(connector);
 
     if (port != listeningPort) {
       logger.log(TreeLogger.INFO, "HTTP listening on port " + port, null);

--- NEW FILE: WebappClassLoader.java ---
/*
 * Licensed to the Apache Software Foundation (ASF) under one or more
 * contributor license agreements.  See the NOTICE file distributed with
 * this work for additional information regarding copyright ownership.
 * The ASF licenses this file to You under the Apache License, Version 2.0
 * (the "License"); you may not use this file except in compliance with
 * the License.  You may obtain a copy of the License at
 * 
 *      http://www.apache.org/licenses/LICENSE-2.0
 * 
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */


package org.apache.catalina.loader;
[...2350 lines suppressed...]

        String files[] = dir.list();
        if (files == null) {
            files = new String[0];
        }
        for (int i = 0; i < files.length; i++) {
            File file = new File(dir, files[i]);
            if (file.isDirectory()) {
                deleteDir(file);
            } else {
                file.delete();
            }
        }
        dir.delete();

    }


}


--- NEW FILE: gwt-benchmarkViewer ---
#!/bin/sh
#
# gwt-benchmarkViewer script
# JPackage Project <http://www.jpackage.org/>

# Source functions library
if [ -f /usr/share/java-utils/java-functions ] ; then
  . /usr/share/java-utils/java-functions
else
  echo "Can't find functions library, aborting"
  exit 1
fi

# Configuration
MAIN_CLASS="com.google.gwt.dev.GWTShell"
#MAIN_CLASS="com.google.gwt.dev.HostedMode"
BASE_FLAGS="-Dcom.google.gwt.junit.reportPath=$1"
BASE_OPTIONS=""
BASE_JARS="ant gwt-user gwt-dev-linux gwt-benchmark-viewer jcommon jfreechart swt"
TOMCAT_JARS="jakarta-commons-collections jakarta-commons-logging tomcat6/annotations-api tomcat6/catalina tomcat6/coyote tomcat6-jsp-2.1-api tomcat6-servlet-2.5-api"
CLASSPATH=/usr/share/tomcat6/bin/tomcat-juli.jar
#JETTY_JARS="ant jetty6/core/jetty6 jetty6/core/jetty6-util"
BASE_JARS="${BASE_JARS} ${TOMCAT_JARS}"

# Set parameters
set_jvm
set_classpath $BASE_JARS
set_flags $BASE_FLAGS
set_options $BASE_OPTIONS

# Let's start
export LD_LIBRARY_PATH=/usr/lib64/xulrunner-1.9:/usr/lib64/eclipse:/usr/lib64/gwt
run -port auto com.google.gwt.benchmarks.viewer.ReportViewer/ReportViewer.html?gwt.hybrid

--- NEW FILE: gwt-mozilla.patch ---
--- gwt-1.6.0/dev/linux/src/com/google/gwt/dev/shell/moz/BrowserWidgetMoz.java.orig	2009-02-22 15:23:39.624360965 -0500
+++ gwt-1.6.0/dev/linux/src/com/google/gwt/dev/shell/moz/BrowserWidgetMoz.java	2009-02-22 15:23:54.319361916 -0500
@@ -119,7 +119,7 @@
       public boolean matchesDOMWindow(int domWindow) {
         nsIWebBrowser webBrowser = (nsIWebBrowser) LowLevel.snatchFieldObjectValue(
             browser.getClass(), browser, "webBrowser");
-        int[] aContentDOMWindow = new int[1];
+        long[] aContentDOMWindow = new long[1];
         webBrowser.GetContentDOMWindow(aContentDOMWindow);
         if (aContentDOMWindow[0] == domWindow) {
           return true;
--- gwt-1.6.0/jni/linux.orig/ExternalWrapper.cpp	2008-12-10 19:39:41.000000000 -0500
+++ gwt-1.6.0/jni/linux/ExternalWrapper.cpp	2009-02-22 18:03:37.897236741 -0500
@@ -47,7 +47,7 @@
     jsval *argv, jsval *rval)
 {
   Tracer tracer("gwtOnLoad");
-  tracer.log("context=%08x", unsigned(cx));
+  tracer.log("context=%08x", long(cx));
   JsRootedValue::ContextManager context(cx);
   JsRootedValue::ensureRuntime(cx);
   if (argc < 3) {
@@ -125,10 +125,10 @@
     return JS_FALSE;
   }
 
-  tracer.log("scriptGlobal=%08x", unsigned(scriptGlobal.get()));
+  tracer.log("scriptGlobal=%08x", long(scriptGlobal.get()));
 
   jboolean result = savedJNIEnv->CallBooleanMethod(externalObject, methodID,
-      NS_REINTERPRET_CAST(jint, scriptGlobal.get()), jModuleName, jVersion);
+      NS_REINTERPRET_CAST(jlong, scriptGlobal.get()), jModuleName, jVersion);
   if (savedJNIEnv->ExceptionCheck()) {
     tracer.setFail("LowLevelMoz.ExternalObject.gwtOnLoad() threw an exception");
     return JS_FALSE;
@@ -145,7 +145,7 @@
     jsval *argv, jsval *rval)
 {
   Tracer tracer("initModule");
-  tracer.log("context=%08x", unsigned(cx));
+  tracer.log("context=%08x", long(cx));
   JsRootedValue::ContextManager context(cx);
   JsRootedValue::ensureRuntime(cx);
   if (argc < 1) {
@@ -318,7 +318,7 @@
       return NS_ERROR_UNEXPECTED;
     }
 
-    tracer.log("savedJNIEnv=%08x, llClass=%08x", unsigned(savedJNIEnv),
+    tracer.log("savedJNIEnv=%08x, llClass=%08x", long(savedJNIEnv),
         lowLevelMozClass);
     
     jmethodID methodID = savedJNIEnv->GetStaticMethodID(lowLevelMozClass,
@@ -330,7 +330,7 @@
     }
 
     jobject externalObject = savedJNIEnv->CallStaticObjectMethod(
-        lowLevelMozClass, methodID, NS_REINTERPRET_CAST(jint, topWindow.get()));
+        lowLevelMozClass, methodID, NS_REINTERPRET_CAST(jlong, topWindow.get()));
     if (!externalObject || savedJNIEnv->ExceptionCheck()) {
       tracer.setFail("createExternalObjectForDOMWindow failed");
       return NS_ERROR_UNEXPECTED;
--- gwt-1.6.0/jni/linux.orig/JsRootedValue.cpp	2007-07-25 16:51:13.000000000 -0400
+++ gwt-1.6.0/jni/linux/JsRootedValue.cpp	2009-02-22 18:04:50.576234899 -0500
@@ -40,5 +40,5 @@
     return;
   }
   stringClass = JS_GET_CLASS(cx, obj);
-  tracer.log("stringClass=%08x", unsigned(stringClass));
+  tracer.log("stringClass=%08x", long(stringClass));
 }
--- gwt-1.6.0/jni/linux.orig/JsRootedValue.h	2007-07-25 16:51:13.000000000 -0400
+++ gwt-1.6.0/jni/linux/JsRootedValue.h	2009-02-22 17:58:31.785285284 -0500
@@ -85,7 +85,7 @@
    */
   static void pushContext(JSContext* context) {
     Tracer tracer("JsRootedValue::pushContext");
-    tracer.log("pushed context=%08x", unsigned(context));
+    tracer.log("pushed context=%08x", long(context));
     contextStack.push(context);
   }
   
@@ -96,7 +96,7 @@
     Tracer tracer("JsRootedValue::popContext");
     JSContext* context = currentContext();
     contextStack.pop();
-    tracer.log("popped context=%08x", unsigned(context));
+    tracer.log("popped context=%08x", long(context));
   }
 
 public:
@@ -184,7 +184,7 @@
       ::abort();
     }
     JSContext* context = contextStack.top();
-    tracer.log("context=%08x", unsigned(context));
+    tracer.log("context=%08x", long(context));
     return context;
   }
 
--- gwt-1.6.0/jni/linux.orig/JsValueMoz.cpp	2008-03-28 20:50:28.000000000 -0400
+++ gwt-1.6.0/jni/linux/JsValueMoz.cpp	2009-02-22 18:02:51.770361675 -0500
@@ -47,7 +47,7 @@
 
   JsRootedValue* jsRootedValue = new JsRootedValue();
   savedJNIEnv->CallVoidMethod(obj, getFieldMeth, fieldName,
-  	 reinterpret_cast<jint>(jsRootedValue));
+  	 reinterpret_cast<jlong>(jsRootedValue));
   if (savedJNIEnv->ExceptionCheck()) {
   	 delete jsRootedValue;
     return 0;
@@ -78,7 +78,7 @@
   }
 
   savedJNIEnv->CallVoidMethod(obj, getFieldMeth, fieldName,
-  	 reinterpret_cast<jint>(jsRootedValue));
+  	 reinterpret_cast<jlong>(jsRootedValue));
   if (savedJNIEnv->ExceptionCheck()) {
     return false;
   }
@@ -216,7 +216,7 @@
   
   // argv[-1] is OBJECT_TO_JSVAL(this)
   JsRootedValue* jsThis = new JsRootedValue(argv[-1]);
-  tracer.log("jsthis=%08x, RV=%08x", unsigned(argv[-1]), unsigned(jsThis));
+  tracer.log("jsthis=%08x, RV=%08x", long(argv[-1]), long(jsThis));
 
   // create JsRootedValues for arguments  
   JsRootedValue *jsArgs[argc]; 
@@ -244,13 +244,13 @@
   // roots the JS interpreter has to search.
   
   // call Java method
-  savedJNIEnv->CallVoidMethod(dispMeth, invokeID, reinterpret_cast<int>(jsThis),
-      args, reinterpret_cast<int>(jsReturnVal));
+  savedJNIEnv->CallVoidMethod(dispMeth, invokeID, reinterpret_cast<long>(jsThis),
+      args, reinterpret_cast<long>(jsReturnVal));
   
   JSBool returnValue = JS_TRUE;
   
   if (savedJNIEnv->ExceptionCheck()) {
-    tracer.log("dispMeth=%08x", unsigned(dispMeth));
+    tracer.log("dispMeth=%08x", long(dispMeth));
     tracer.setFail("java exception is active:");
     jobject exception = savedJNIEnv->ExceptionOccurred();
     if (exception) {
@@ -293,7 +293,7 @@
 {
   Tracer tracer("JsValueMoz._createJsRootedValue");
   JsRootedValue* jsRootedValue = new JsRootedValue(jsval);
-  return NS_REINTERPRET_CAST(jint, jsRootedValue);
+  return NS_REINTERPRET_CAST(jlong, jsRootedValue);
 }
 
 /*
@@ -309,7 +309,7 @@
       (jsRootedValueInt);
   Tracer tracer("JsValueMoz._copyJsRootedValue", jsRootedValue);
   JsRootedValue* newRootedValue = new JsRootedValue(*jsRootedValue);
-  return NS_REINTERPRET_CAST(jint, newRootedValue);
+  return NS_REINTERPRET_CAST(jlong, newRootedValue);
 }
 
 /*
@@ -537,7 +537,7 @@
     JSObject* jsObject = JSVAL_TO_OBJECT(val);
     returnValue = !JS_InstanceOf(JsRootedValue::currentContext(), jsObject,
         &gwt_nativewrapper_class, 0);
-    tracer.log("jsobject=%08x, isJSObject=%s", unsigned(jsObject),
+    tracer.log("jsobject=%08x, isJSObject=%s", long(jsObject),
         returnValue ? "true" : "false");
   } else {
     tracer.log("not an object");
@@ -648,7 +648,7 @@
     JSObject* jsObject = JSVAL_TO_OBJECT(val);
     returnValue = JS_InstanceOf(JsRootedValue::currentContext(), jsObject,
         &gwt_nativewrapper_class, 0);
-    tracer.log("jsobject=%08x, wrappedJava=%s", unsigned(jsObject),
+    tracer.log("jsobject=%08x, wrappedJava=%s", long(jsObject),
         returnValue ? "true" : "false");
   } else {
     tracer.log("not an object");
@@ -835,7 +835,7 @@
   }
   // Save in output value so it won't get GCed.
   jsRootedValue->setObject(newObj); 
-  tracer.log("jsobject=%08x", unsigned(newObj));
+  tracer.log("jsobject=%08x", long(newObj));
   
   // This is collected when the gwt_nativewrapper_class destructor runs.
   jobject dispObjRef = jniEnv->NewGlobalRef(obj);
@@ -871,7 +871,7 @@
   // allocate a new root to hold the result of the getField call
   JsRootedValue* toStringFunc = new JsRootedValue(); 
   jniEnv->CallVoidMethod(obj, getFieldMeth, ident,
-      NS_REINTERPRET_CAST(jint, toStringFunc));
+      NS_REINTERPRET_CAST(jlong, toStringFunc));
   if (toStringFunc->isUndefined() || jniEnv->ExceptionCheck()) {
     tracer.throwHostedModeException(jniEnv, "getField(toString) failed");
     return;
@@ -907,7 +907,7 @@
     return;
   }
   tracer.log("JsRootedValue=%08x, method=%s, obj=%08x", jsRootedValueInt,
-      nameStr.str(), unsigned(dispatchMethod));
+      nameStr.str(), long(dispatchMethod));
   JSFunction* function = JS_NewFunction(cx, invokeJavaMethod, 0,
       JSFUN_LAMBDA, 0, nameStr.str());
   if (!function) {
@@ -929,8 +929,8 @@
     tracer.throwHostedModeException(jniEnv, "JS_NewObject failed");
     return;
   }
-  tracer.log("funObj=%08x, cleanupObj=%08x", unsigned(funObj),
-      unsigned(cleanupObj));
+  tracer.log("funObj=%08x, cleanupObj=%08x", long(funObj),
+        long(cleanupObj));
   // Store the cleanup object in funObj's reserved slot; now GC protected.
   if(!JS_SetReservedSlot(cx, funObj, 0, OBJECT_TO_JSVAL(cleanupObj))) {
     tracer.throwHostedModeException(jniEnv, "JS_SetReservedSlot failed");
--- gwt-1.6.0/jni/linux.orig/Makefile	2008-03-04 20:14:12.000000000 -0500
+++ gwt-1.6.0/jni/linux/Makefile	2009-02-22 18:24:35.194318624 -0500
@@ -16,7 +16,7 @@
 # Target settings
 ##
 #JAVA_HOME
-#JAVA_HOME=/usr/lib/j2sdk1.5-sun
+JAVA_HOME ?= /usr/lib/jvm/java
 
 # set GWT_TOOLS only if it is not already defined
 GWT_TOOLS ?= ../../../tools
@@ -55,33 +55,34 @@
 OBJS    := $(addprefix $(OBJDIR),$(SRCS:.cpp=.o))
 DEPS    := $(addprefix $(OBJDIR),$(SRCS:.cpp=.d))
 
-MOZDIR = $(GWT_TOOLS)/sdk/mozilla-1.7.12
-MOZINC = $(MOZDIR)/include
-MOZLIB = $(MOZDIR)/lib
+#MOZDIR = $(GWT_TOOLS)/sdk/mozilla-1.7.12
+#MOZINC = $(MOZDIR)/include
+#MOZLIB = $(MOZDIR)/lib
 
 ##
 # Include path configuration
 ##
 SYSINCS := \
     $(JAVA_HOME)/include \
-    $(JAVA_HOME)/include/linux \
-    $(MOZINC) $(MOZINC)/extra
+    $(JAVA_HOME)/include/linux
 
-INCS := $(OBJDIR)
-INCS := $(addprefix -I ,$(INCS)) $(addprefix -isystem ,$(SYSINCS))
+#INCS := $(OBJDIR)
+#INCS := $(addprefix -I ,$(INCS)) $(addprefix -isystem ,$(SYSINCS))
 
 ##
 # Libraries and library path
 ##
-LIBS    = xpcomglue_s
-LIBPATH = -L$(MOZLIB)
-LIBS     := $(addprefix -l,$(LIBS))
+#LIBS    = xpcomglue_s
+#LIBPATH = -L$(MOZLIB)
+#LIBS     := $(addprefix -l,$(LIBS))
 
 # for notes on auto-dependency generation, see
 #   http://make.paulandlesley.org/autodep.html
 # -MP obviates the need for sed hackery
-CFLAGS   := -ggdb -m32 -Os -fPIC -fno-omit-frame-pointer -fno-strict-aliasing -D_REENTRANT -MMD -MP -Wno-system-headers $(CFLAGS)
-LDFLAGS  := -ggdb -m32 -s -fPIC -fno-omit-frame-pointer -fno-strict-aliasing -D_REENTRANT -Wl,-shared-gcc $(LDFLAGS)
+#CFLAGS   := -ggdb -Os -fPIC -fno-omit-frame-pointer -fno-strict-aliasing -D_REENTRANT -MMD -MP -Wno-system-headers $(CFLAGS)
+#LDFLAGS  := -ggdb -s -fPIC -fno-omit-frame-pointer -fno-strict-aliasing -D_REENTRANT -Wl,-shared-gcc $(LDFLAGS)
+CFLAGS = -I$(JAVA_HOME)/include -I$(JAVA_HOME)/include/linux -I$(OBJDIR)  -fPIC `pkg-config --cflags libxul-unstable` -DMOZILLA_INTERNAL_API
+LDFLAGS =  `pkg-config --libs libxul-unstable`
 
 #-------------------------------------------------------------------------------
 # Rules
@@ -134,7 +135,7 @@
 ##
 # Actual output file
 ##
-$(OUT): $(OBJS) $(MOZLIB)/libxpcomglue_s.a
+$(OUT): $(OBJS)
 	@[ -d $(OUTDIR) ] || mkdir -p $(OUTDIR)
 	$(LD) -shared $(LDFLAGS) $(LIBPATH) -o $@ $^ $(LIBS)
 	$(STRIP) --strip-unneeded $@
--- gwt-1.6.0/jni/linux.orig/NativeWrapper.cpp	2008-06-10 21:12:18.000000000 -0400
+++ gwt-1.6.0/jni/linux/NativeWrapper.cpp	2009-02-22 18:04:24.399235658 -0500
@@ -89,7 +89,7 @@
 
   JsRootedValue* jsRootedValue = new JsRootedValue();
   savedJNIEnv->CallVoidMethod(obj, getFieldMeth, fieldName,
-    reinterpret_cast<jint>(jsRootedValue));
+    reinterpret_cast<jlong>(jsRootedValue));
   if (savedJNIEnv->ExceptionCheck()) {
     delete jsRootedValue;
     return 0;
@@ -120,7 +120,7 @@
   }
 
   savedJNIEnv->CallVoidMethod(obj, getFieldMeth, fieldName,
-    reinterpret_cast<jint>(jsRootedValue));
+    reinterpret_cast<jlong>(jsRootedValue));
   if (savedJNIEnv->ExceptionCheck()) {
     return false;
   }
@@ -132,7 +132,7 @@
     JSObject *obj, jsval id, jsval *vp)
 {
   Tracer tracer("gwt_nativewrapper_getProperty");
-  tracer.log("context=%08x, obj=%08x", unsigned(cx), unsigned(obj));
+  tracer.log("context=%08x, obj=%08x", long(cx), long(obj));
   JsRootedValue::ContextManager context(cx);
 
   jclass dispClass;
@@ -177,7 +177,7 @@
 static JSBool JS_DLL_CALLBACK gwt_nativewrapper_setProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   Tracer tracer("gwt_nativewrapper_setProperty");
-  tracer.log("context=%08x", unsigned(cx));
+  tracer.log("context=%08x", long(cx));
   JsRootedValue::ContextManager context(cx);
   jclass dispClass;
   jobject dispObj;
--- gwt-1.6.0/jni/core/gwt-ll.cpp.orig	2009-02-22 18:51:02.872240155 -0500
+++ gwt-1.6.0/jni/core/gwt-ll.cpp	2009-02-22 18:51:15.378366073 -0500
@@ -14,7 +14,7 @@
  * Signature: (Ljava/lang/Object;)I
  */
 JNIEXPORT jint JNICALL Java_com_google_gwt_dev_shell_LowLevel__1newGlobalRefInt(JNIEnv* env, jclass, jobject o) {
-	return reinterpret_cast<int>(env->NewGlobalRef(o));
+	return reinterpret_cast<long>(env->NewGlobalRef(o));
 }
 /*
  * Class:     com_google_gwt_dev_shell_LowLevel
--- gwt-1.6.0/dev/core/src/com/google/gwt/dev/shell/LowLevel.java.orig	2009-02-23 17:17:49.208362054 -0500
+++ gwt-1.6.0/dev/core/src/com/google/gwt/dev/shell/LowLevel.java	2009-02-23 17:18:14.904237241 -0500
@@ -96,7 +96,7 @@
         } catch (IOException e) {
           // ignore problems, failures will occur when the libs try to load
         }
-        System.load(installPath + '/' + System.mapLibraryName(libName));
+        System.load("@LIBDIR@/@NAME@" + '/' + System.mapLibraryName(libName));
       } catch (UnsatisfiedLinkError e) {
         StringBuffer sb = new StringBuffer();
         sb.append("Unable to load required native library '" + libName
--- gwt-1.6.0/distro-source/linux/src/mozilla-hosted-browser.conf.orig	2009-02-23 17:33:19.997361702 -0500
+++ gwt-1.6.0/distro-source/linux/src/mozilla-hosted-browser.conf	2009-02-23 17:35:06.600648457 -0500
@@ -24,12 +24,13 @@
 #
 # However, this version may not run correctly on your system.  If it doesn't,
 # you can try installing a mozilla 1.7.13 built for your system.
-mozilla-1.7.13
+#mozilla-1.7.13
 
 # This is the default mozilla that ships with GWT.
-mozilla-1.7.12
+#mozilla-1.7.12
 
 # See if there are compatible mozilla distributions already installed.
-/usr/lib/mozilla-1.7.13
-/usr/lib/mozilla-1.7.12
-/usr/lib/mozilla
+#/usr/lib/mozilla-1.7.13
+#/usr/lib/mozilla-1.7.12
+#/usr/lib/mozilla
+ at XULRUNNER_PATH@
--- gwt-1.6.0/dev/linux/src/com/google/gwt/dev/shell/moz/MozillaInstall.java.mozilla	2007-06-18 18:12:51.000000000 -0400
+++ gwt-1.6.0/dev/linux/src/com/google/gwt/dev/shell/moz/MozillaInstall.java	2009-02-24 19:33:21.349236326 -0500
@@ -71,7 +71,7 @@
      * mozilla installation. Return immediately if a suitable one is found.
      */
     try {
-      BufferedReader reader = new BufferedReader(new FileReader(installPath
+      BufferedReader reader = new BufferedReader(new FileReader("@SYSCONFDIR@/@NAME@"
           + "/" + CONFIG_FILENAME));
       try { // make sure we close the reader
         String mozillaDir;
@@ -81,7 +81,7 @@
             continue;
           }
           if (!mozillaDir.startsWith("/")) {
-            mozillaDir = installPath + "/" + mozillaDir;
+            mozillaDir = "@LIBDIR@" + "/" + mozillaDir;
           }
           MozillaInstall mozInstall = new MozillaInstall(mozillaDir);
           if (mozInstall.isAcceptable()) {
--- gwt-1.6.0/jni/linux/mozilla-headers.h.mozilla	2007-05-23 14:45:55.000000000 -0400
+++ gwt-1.6.0/jni/linux/mozilla-headers.h	2009-02-24 20:42:39.790237046 -0500
@@ -16,7 +16,7 @@
 
 // include all of the necessary Mozilla headers.
 #include "mozilla-config.h"
-#include "nsIServiceManagerUtils.h"
+#include "nsIServiceManager.h"
 #include "nsComponentManagerUtils.h"
 #include "nsICategoryManager.h"
 #include "nsIScriptNameSpaceManager.h"
@@ -26,5 +26,13 @@
 #include "nsIDOMWindow.h"
 #include "nsIXPConnect.h"
 #include "nsIFactory.h"
-#include "nsCOMPtr.h"
+//#include "nsCOMPtr.h"
 #include "nsAutoPtr.h"
+#include "jsapi.h"
+#include "nsDOMJSUtils.h"
+#include "nsIComponentManager.h"
+#include "nsIComponentRegistrar.h"
+#include "nsXPCOM.h"
+#define NS_REINTERPRET_CAST(a, b) reinterpret_cast<a>(b)
+#include "nsError.h"
+#define NS_FAILED(_nsresult) (NS_UNLIKELY((_nsresult) & 0x80000000))
--- gwt-1.6.0/jni/linux/LowLevelMoz.cpp.mozilla	2008-06-10 21:12:18.000000000 -0400
+++ gwt-1.6.0/jni/linux/LowLevelMoz.cpp	2009-02-25 10:12:40.458236738 -0500
@@ -225,16 +225,19 @@
       NS_REINTERPRET_CAST(nsIScriptGlobalObject*, scriptObjectInt);
   JSObject* scriptWindow =
       reinterpret_cast<JSObject*>(scriptObject->GetGlobalJSObject());
-  nsXPIDLString scriptString;
+  nsXPIDLString scriptString;
   scriptString = jcode.jstr();
 
   nsXPIDLString aRetValue;
   PRBool aIsUndefined;
-  if (NS_FAILED(scriptContext->EvaluateString(scriptString, scriptWindow, 0,
-      jfile.str(), line, 0, aRetValue, &aIsUndefined))) {
+//nsDerivedSafe<nsIScriptContext>::EvaluateString(nsXPIDLString&, JSObject*&, int, const char*, jint&, int, nsXPIDLString&, PRBool*)
+//nsIScriptContext::EvaluateString(const nsAString_internal&, void*, nsIPrincipal*, const char*, PRUint32, PRUint32, nsAString_internal*, PRBool*)
+/*
+  if (NS_FAILED(scriptContext->EvaluateString(scriptString, (void*) scriptWindow, (nsIPrincipal*) 0,
+      (const char*) jfile.str(), (PRUint32) line, (PRUint32) 0, aRetValue, (PRBool*) &aIsUndefined))) {
     tracer.setFail("EvaluateString failed");
     return JNI_FALSE;
-  }
+  }*/
   return JNI_TRUE;
 }
 
@@ -350,16 +353,17 @@
   Tracer tracer("LowLevelMoz._registerExternalFactoryHandler");
 
   char buf[256];
-  sprintf(buf, " jniEnv=%08x, llClass=%08x", (unsigned)env, (unsigned)llClass);
+  sprintf(buf, " jniEnv=%08x, llClass=%08x", (long)env, (long)llClass);
   tracer.log(buf);
-  
+  long *result = new long[1];
+
   // Register "window.external" as our own class
-  if (NS_FAILED(nsComponentManager::RegisterFactory(
+  /*if (NS_FAILED(nsIComponentRegistrar::RegisterFactory(
       kGwtExternalCID, "externalFactory", GWT_EXTERNAL_CONTRACTID,
       new nsRpExternalFactory(), PR_TRUE))) {
     tracer.setFail("RegisterFactory failed");
     return JNI_FALSE;
-  }
+  }*/
 
   nsCOMPtr<nsICategoryManager> categoryManager =
       do_GetService(NS_CATEGORYMANAGER_CONTRACTID);

--- NEW FILE: gwt-junitCreator ---
#!/bin/sh
#
# gwt-junitCreator script
# JPackage Project <http://www.jpackage.org/>

# Source functions library
if [ -f /usr/share/java-utils/java-functions ] ; then
  . /usr/share/java-utils/java-functions
else
  echo "Can't find functions library, aborting"
  exit 1
fi

# Configuration
MAIN_CLASS="com.google.gwt.junit.tools.JUnitCreator"
BASE_FLAGS=""
BASE_OPTIONS=""
BASE_JARS="gwt-user servlet_2_5_api gwt-dev-linux"

# Set parameters
set_jvm
set_classpath $BASE_JARS
set_flags $BASE_FLAGS
set_options $BASE_OPTIONS

# Let's start
run "$@"

Index: gwt-build.patch
===================================================================
RCS file: /home/projects/jpackage/cvs/dist/gwt/devel/gwt-build.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -C 2 -d -r1.1 -r1.2
*** gwt-build.patch	21 Feb 2009 00:30:33 -0000	1.1
--- gwt-build.patch	25 Feb 2009 21:20:49 -0000	1.2
***************
*** 41,95 ****
     </target>
   
- --- gwt-1.6.0.orig/dev/core/src/com/google/gwt/core/ext/linker/impl/SelectionScriptLinker.java	2008-12-11 21:59:42.000000000 -0500
- +++ gwt-1.6.0/dev/core/src/com/google/gwt/core/ext/linker/impl/SelectionScriptLinker.java	2009-02-19 11:35:46.686769138 -0500
- @@ -91,7 +91,7 @@
-        ArtifactSet artifacts) throws UnableToCompleteException {
-      ArtifactSet toReturn = new ArtifactSet(artifacts);
-  
- -    for (CompilationResult compilation : toReturn.find(CompilationResult.class)) {
- +    for (CompilationResult compilation : toReturn.<CompilationResult,CompilationResult>find(CompilationResult.class)) {
-        toReturn.add(doEmitCompilation(logger, context, compilation));
-      }
-  
- @@ -204,7 +204,7 @@
-      // Add external dependencies
-      startPos = selectionScript.indexOf("// __MODULE_STYLES_END__");
-      if (startPos != -1) {
- -      for (StylesheetReference resource : artifacts.find(StylesheetReference.class)) {
- +      for (StylesheetReference resource : artifacts.<StylesheetReference,StylesheetReference>find(StylesheetReference.class)) {
-          String text = generateStylesheetInjector(resource.getSrc());
-          selectionScript.insert(startPos, text);
-          startPos += text.length();
- @@ -213,7 +213,7 @@
-  
-      startPos = selectionScript.indexOf("// __MODULE_SCRIPTS_END__");
-      if (startPos != -1) {
- -      for (ScriptReference resource : artifacts.find(ScriptReference.class)) {
- +      for (ScriptReference resource : artifacts.<ScriptReference,ScriptReference>find(ScriptReference.class)) {
-          String text = generateScriptInjector(resource.getSrc());
-          selectionScript.insert(startPos, text);
-          startPos += text.length();
- --- gwt-1.6.0.orig/dev/core/src/com/google/gwt/core/ext/linker/impl/StandardLinkerContext.java	2008-12-10 21:00:54.000000000 -0500
- +++ gwt-1.6.0/dev/core/src/com/google/gwt/core/ext/linker/impl/StandardLinkerContext.java	2009-02-19 11:35:07.747800735 -0500
- @@ -433,7 +433,7 @@
-      logger = logger.branch(TreeLogger.TRACE, "Linking compilation into "
-          + outputPath.getPath(), null);
-  
- -    for (EmittedArtifact artifact : artifacts.find(EmittedArtifact.class)) {
- +    for (EmittedArtifact artifact : artifacts.<EmittedArtifact,EmittedArtifact>find(EmittedArtifact.class)) {
-        TreeLogger artifactLogger = logger.branch(TreeLogger.DEBUG,
-            "Emitting resource " + artifact.getPartialPath(), null);
-  
- --- gwt-1.6.0.orig/dev/core/src/com/google/gwt/dev/GWTShell.java	2009-01-30 18:17:23.000000000 -0500
- +++ gwt-1.6.0/dev/core/src/com/google/gwt/dev/GWTShell.java	2009-02-19 11:35:07.792766865 -0500
- @@ -202,7 +202,7 @@
-           * Copied from StandardLinkerContext.produceOutputDirectory() for legacy
-           * GWTShellServlet support.
-           */
- -        for (EmittedArtifact artifact : artifacts.find(EmittedArtifact.class)) {
- +        for (EmittedArtifact artifact : artifacts.<EmittedArtifact,EmittedArtifact>find(EmittedArtifact.class)) {
-            if (!artifact.isPrivate()) {
-              File outFile = new File(options.getShellPublicGenDir(module),
-                  artifact.getPartialPath());
  --- gwt-1.6.0.orig/distro-source/linux/build.xml	2009-01-13 14:16:35.000000000 -0500
  +++ gwt-1.6.0/distro-source/linux/build.xml	2009-02-19 12:28:00.468766992 -0500
--- 41,44 ----
***************
*** 137,151 ****
     </target>
   
- --- gwt-1.6.0.orig/user/src/com/google/gwt/user/server/rpc/RPC.java	2007-11-12 14:59:45.000000000 -0500
- +++ gwt-1.6.0/user/src/com/google/gwt/user/server/rpc/RPC.java	2009-02-19 12:14:10.367892682 -0500
- @@ -46,7 +46,7 @@
-   * The following example shows a more advanced way of using this class to create
-   * an adapter between GWT RPC entities and POJOs.
-   * 
- - * {@example com.google.gwt.examples.rpc.server.AdvancedExample#doPost(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)}
- + *
-   */
-  public final class RPC {
-  
  --- gwt-1.6.0/tools/benchmark-viewer/build.xml.orig	2009-02-19 18:38:38.837768899 -0500
  +++ gwt-1.6.0/tools/benchmark-viewer/build.xml	2009-02-19 18:39:04.178893847 -0500
--- 86,89 ----
***************
*** 162,163 ****
--- 100,131 ----
     </target>
   
+ --- gwt-1.6.0/doc/build.xml.build	2009-02-03 13:40:07.000000000 -0500
+ +++ gwt-1.6.0/doc/build.xml	2009-02-24 18:59:16.359805046 -0500
+ @@ -34,6 +34,7 @@
+    </path>
+  
+    <path id="USER_CLASS_PATH">
+ +    <pathelement path="${java.class.path}" />
+      <pathelement location="${gwt.user.jar}" />
+      <pathelement location="${gwt.dev.jar}" />
+      <pathelement location="${gwt.tools.lib}/junit/junit-3.8.1.jar" />
+ @@ -83,6 +84,10 @@
+            <arg value="1.5" />
+            <arg value="-windowtitle" />
+            <arg value="Google Web Toolkit Javadoc" />
+ +          <arg value="-link" />
+ +          <arg value="/usr/share/javadoc/junit" />
+ +          <arg value="-link" />
+ +          <arg value="/usr/share/javadoc/jboss-javaee" />
+            <arg value="-encoding"/>
+            <arg value="UTF-8"/>
+            <arg value="-d" />
+ @@ -120,7 +125,7 @@
+            <arg value="-classpath" />
+            <arg pathref="USER_CLASS_PATH" />
+            <arg value="-sourcepath" />
+ -          <arg path="${gwt.root}/user/super/com/google/gwt/emul" />
+ +          <arg path="${gwt.root}/user/super/com/google/gwt/emul:${gwt.root}/dev/core/super/com/google/gwt/dev/jjs/intrinsic" />
+            <arg value="-packages" />
+            <arg value="${LANG_PKGS}" />
+          </java>

--- NEW FILE: Mozilla.java ---
/*******************************************************************************
 * Copyright (c) 2003, 2008 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *******************************************************************************/
// Modified by Google
package org.eclipse.swt.browser;

import com.google.gwt.dev.shell.moz.LowLevelMoz; // GOOGLE

import java.io.*;
import java.lang.reflect.*;
import java.util.*;
import org.eclipse.swt.*;
[...3205 lines suppressed...]
			case 4: mouseEvent.stateMask |= SWT.BUTTON4; break;
			case 5: mouseEvent.stateMask |= SWT.BUTTON5; break;
		}
	}

	browser.notifyListeners (mouseEvent.type, mouseEvent);
	if (browser.isDisposed ()) return XPCOM.NS_OK;
	if (aDetail[0] == 2 && XPCOM.DOMEVENT_MOUSEDOWN.equals (typeString)) {
		mouseEvent = new Event ();
		mouseEvent.widget = browser;
		mouseEvent.x = aClientX[0]; mouseEvent.y = aClientY[0];
		mouseEvent.stateMask = (aAltKey[0] != 0 ? SWT.ALT : 0) | (aCtrlKey[0] != 0 ? SWT.CTRL : 0) | (aShiftKey[0] != 0 ? SWT.SHIFT : 0) | (aMetaKey[0] != 0 ? SWT.COMMAND : 0);
		mouseEvent.type = SWT.MouseDoubleClick;
		mouseEvent.button = aButton[0] + 1;
		mouseEvent.count = aDetail[0];
		browser.notifyListeners (mouseEvent.type, mouseEvent);	
	}
	return XPCOM.NS_OK;
}
}

--- NEW FILE: gwt-java6.patch ---
--- gwt-1.6.0.orig/dev/core/src/com/google/gwt/core/ext/linker/impl/SelectionScriptLinker.java	2008-12-11 21:59:42.000000000 -0500
+++ gwt-1.6.0/dev/core/src/com/google/gwt/core/ext/linker/impl/SelectionScriptLinker.java	2009-02-19 11:35:46.686769138 -0500
@@ -91,7 +91,7 @@
       ArtifactSet artifacts) throws UnableToCompleteException {
     ArtifactSet toReturn = new ArtifactSet(artifacts);
 
-    for (CompilationResult compilation : toReturn.find(CompilationResult.class)) {
+    for (CompilationResult compilation : toReturn.<CompilationResult,CompilationResult>find(CompilationResult.class)) {
       toReturn.add(doEmitCompilation(logger, context, compilation));
     }
 
@@ -204,7 +204,7 @@
     // Add external dependencies
     startPos = selectionScript.indexOf("// __MODULE_STYLES_END__");
     if (startPos != -1) {
-      for (StylesheetReference resource : artifacts.find(StylesheetReference.class)) {
+      for (StylesheetReference resource : artifacts.<StylesheetReference,StylesheetReference>find(StylesheetReference.class)) {
         String text = generateStylesheetInjector(resource.getSrc());
         selectionScript.insert(startPos, text);
         startPos += text.length();
@@ -213,7 +213,7 @@
 
     startPos = selectionScript.indexOf("// __MODULE_SCRIPTS_END__");
     if (startPos != -1) {
-      for (ScriptReference resource : artifacts.find(ScriptReference.class)) {
+      for (ScriptReference resource : artifacts.<ScriptReference,ScriptReference>find(ScriptReference.class)) {
         String text = generateScriptInjector(resource.getSrc());
         selectionScript.insert(startPos, text);
         startPos += text.length();
--- gwt-1.6.0.orig/dev/core/src/com/google/gwt/core/ext/linker/impl/StandardLinkerContext.java	2008-12-10 21:00:54.000000000 -0500
+++ gwt-1.6.0/dev/core/src/com/google/gwt/core/ext/linker/impl/StandardLinkerContext.java	2009-02-19 11:35:07.747800735 -0500
@@ -433,7 +433,7 @@
     logger = logger.branch(TreeLogger.TRACE, "Linking compilation into "
         + outputPath.getPath(), null);
 
-    for (EmittedArtifact artifact : artifacts.find(EmittedArtifact.class)) {
+    for (EmittedArtifact artifact : artifacts.<EmittedArtifact,EmittedArtifact>find(EmittedArtifact.class)) {
       TreeLogger artifactLogger = logger.branch(TreeLogger.DEBUG,
           "Emitting resource " + artifact.getPartialPath(), null);
 
--- gwt-1.6.0.orig/dev/core/src/com/google/gwt/dev/GWTShell.java	2009-01-30 18:17:23.000000000 -0500
+++ gwt-1.6.0/dev/core/src/com/google/gwt/dev/GWTShell.java	2009-02-19 11:35:07.792766865 -0500
@@ -202,7 +202,7 @@
          * Copied from StandardLinkerContext.produceOutputDirectory() for legacy
          * GWTShellServlet support.
          */
-        for (EmittedArtifact artifact : artifacts.find(EmittedArtifact.class)) {
+        for (EmittedArtifact artifact : artifacts.<EmittedArtifact,EmittedArtifact>find(EmittedArtifact.class)) {
           if (!artifact.isPrivate()) {
             File outFile = new File(options.getShellPublicGenDir(module),
                 artifact.getPartialPath());

Index: sources
===================================================================
RCS file: /home/projects/jpackage/cvs/dist/gwt/devel/sources,v
retrieving revision 1.2
retrieving revision 1.3
diff -C 2 -d -r1.2 -r1.3
*** sources	21 Feb 2009 00:30:33 -0000	1.2
--- sources	25 Feb 2009 21:20:49 -0000	1.3
***************
*** 1,2 ****
- 79796b317af5ce59f6d6f4645b134bf7  gwt-1.6.0-tools.tar.bz2
  d3ab0647296a50f4a8b4a332fa4d8924  gwt-1.6.0.tar.bz2
--- 1 ----

--- NEW FILE: gwt-webAppCreator ---
#!/bin/sh
#
# gwt-webAppCreator script
# JPackage Project <http://www.jpackage.org/>

# Source functions library
if [ -f /usr/share/java-utils/java-functions ] ; then
  . /usr/share/java-utils/java-functions
else
  echo "Can't find functions library, aborting"
  exit 1
fi

# Configuration
MAIN_CLASS="com.google.gwt.user.tools.WebAppCreator"
BASE_FLAGS=""
BASE_OPTIONS=""
BASE_JARS="gwt-user servlet_2_5_api gwt-dev-linux"

# Set parameters
set_jvm
set_classpath $BASE_JARS
set_flags $BASE_FLAGS
set_options $BASE_OPTIONS

# Let's start
run "$@"

Index: gwt.spec
===================================================================
RCS file: /home/projects/jpackage/cvs/dist/gwt/devel/gwt.spec,v
retrieving revision 1.1
retrieving revision 1.2
diff -C 2 -d -r1.1 -r1.2
*** gwt.spec	21 Feb 2009 00:30:33 -0000	1.1
--- gwt.spec	25 Feb 2009 21:20:49 -0000	1.2
***************
*** 50,63 ****
  # svn -q export http://google-web-toolkit.googlecode.com/svn/tags/1.6.0/ gwt-1.6.0 && tar cjf gwt-1.6.0.tar.bz2 gwt-1.6.0
  Source0:        gwt-1.6.0.tar.bz2
- # svn export http://google-web-toolkit.googlecode.com/svn/tools/ tools
- # tar cjf gwt/SOURCES/gwt-1.6.0-tools.tar.bz2 tools/lib/eclipse/org.eclipse.swt.gtk-linux-3.2.1.jar tools/lib/tomcat/catalina-1.0.jar tools/lib/tomcat/naming-resources-1.0.jar tools/lib/tomcat/tomcat-util-5.1.jar
- Source1:        gwt-1.6.0-tools.tar.bz2
  Source2:        http://mirrors.ibiblio.org/pub/mirrors/maven2/com/google/gwt/gwt-dev/1.6.0/gwt-dev-1.6.0.pom
  Source3:        http://mirrors.ibiblio.org/pub/mirrors/maven2/com/google/gwt/gwt-servlet/1.6.0/gwt-servlet-1.6.0.pom
  Source4:        http://mirrors.ibiblio.org/pub/mirrors/maven2/com/google/gwt/gwt-user/1.6.0/gwt-user-1.6.0.pom
  Patch0:         gwt-build.patch
  Requires(post): jpackage-utils >= 0:1.7.3
  Requires(postun): jpackage-utils >= 0:1.7.3
  Requires:       jpackage-utils >= 0:1.7.3
  BuildRequires:  ant
  BuildRequires:  ant-contrib
--- 50,76 ----
  # svn -q export http://google-web-toolkit.googlecode.com/svn/tags/1.6.0/ gwt-1.6.0 && tar cjf gwt-1.6.0.tar.bz2 gwt-1.6.0
  Source0:        gwt-1.6.0.tar.bz2
  Source2:        http://mirrors.ibiblio.org/pub/mirrors/maven2/com/google/gwt/gwt-dev/1.6.0/gwt-dev-1.6.0.pom
  Source3:        http://mirrors.ibiblio.org/pub/mirrors/maven2/com/google/gwt/gwt-servlet/1.6.0/gwt-servlet-1.6.0.pom
  Source4:        http://mirrors.ibiblio.org/pub/mirrors/maven2/com/google/gwt/gwt-user/1.6.0/gwt-user-1.6.0.pom
+ Source5:        Mozilla.java
+ Source6:        WebappClassLoader.java
+ Source7:        gwt-benchmarkViewer
+ Source8:        gwt-i18nCreator
+ Source9:        gwt-junitCreator
+ Source10:       gwt-webAppCreator
  Patch0:         gwt-build.patch
+ Patch1:         gwt-java6.patch
+ Patch2:         gwt-mozilla.patch
+ Patch3:         gwt-tomcat.patch
  Requires(post): jpackage-utils >= 0:1.7.3
  Requires(postun): jpackage-utils >= 0:1.7.3
+ Requires:       ant
+ Requires:       jcommon
+ Requires:       jetty6
+ Requires:       jfreechart
  Requires:       jpackage-utils >= 0:1.7.3
+ Requires:       libswt3-gtk2
+ Requires:       servlet_2_5_api
+ Requires:       tomcat6-lib
  BuildRequires:  ant
  BuildRequires:  ant-contrib
***************
*** 66,69 ****
--- 79,84 ----
  BuildRequires:  jakarta-commons-collections
  BuildRequires:  jakarta-commons-logging
+ BuildRequires:  jboss-javaee-javadoc
+ BuildRequires:  jboss-servlet-2.5-api
  BuildRequires:  jetty6
  BuildRequires:  jfreechart
***************
*** 71,84 ****
  BuildRequires:  jpackage-utils >= 0:1.7.3
  BuildRequires:  junit
! #BuildRequires: libswt3-gtk2
  BuildRequires:  openqa-selenium-rc-java-client-driver
- BuildRequires:  servlet_2_5_api
  BuildRequires:  tapestry
! #BuildRequires: tomcat5-common-lib
! 
  %if %{gcj_support}
  BuildRequires:  java-gcj-compat-devel
- %else
- BuildArch:      noarch
  %endif
  BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root
--- 86,97 ----
  BuildRequires:  jpackage-utils >= 0:1.7.3
  BuildRequires:  junit
! BuildRequires:  junit-javadoc
! BuildRequires:  libswt3-gtk2
  BuildRequires:  openqa-selenium-rc-java-client-driver
  BuildRequires:  tapestry
! BuildRequires:  tomcat6
! BuildRequires:  tomcat6-lib
  %if %{gcj_support}
  BuildRequires:  java-gcj-compat-devel
  %endif
  BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root
***************
*** 110,126 ****
  %prep
  %setup -q
! %{_bindir}/find -type f -name "*.jar" | %{_bindir}/xargs -t %{__rm}
! %setup -q -T -D -a 1
! %patch0 -p1
  %{__mkdir_p} tools
  
  %build
! # [echo] Branding as GWT version 0.0.0, SVN rev 1.6.0 at 4796M
! #export CLASSPATH=$(build-classpath ant-contrib antlr checkstyle ecj jakarta-commons-beanutils jakarta-commons-collections jakarta-commons-logging jetty6/core/jetty6 jetty6/core/jetty6-util jcommon jfreechart junit selenium-java-client-driver servlet_2_5_api tapestry/tapestry tomcat5/catalina tomcat5/naming-resources tomcat5/tomcat-util)
! export CLASSPATH=$(build-classpath ant-contrib antlr checkstyle ecj jakarta-commons-beanutils jakarta-commons-collections jakarta-commons-logging jetty6/core/jetty6 jetty6/core/jetty6-util jcommon jfreechart junit selenium-java-client-driver servlet_2_5_api tapestry/tapestry)
! export CLASSPATH=${CLASSPATH}:`%{_bindir}/find tools/ -type f -name "*.jar" | tr '\n' ':'`
  export OPT_JAR_LIST=:
  export GWT_TOOLS=`pwd`/tools
! %{ant} -Dbuild.sysclasspath=first -Dgwt.version=%{version} -Dgwt.svnrev=@%{svnrev} -Dgwt.svnrev.filename=%{svnrev}
  
  %install
--- 123,167 ----
  %prep
  %setup -q
! %{_bindir}/find -type f \( -name "*.jar" -o -name "*.so" \) | %{_bindir}/xargs -t %{__rm}
! %patch0 -p1 -b .build
! %patch1 -p1 -b .java6
! %patch2 -p1 -b .mozilla
! %patch3 -p1 -b .tomcat
! 
! XULRUNNER_PATH=$(%{_bindir}/dirname $(%{_bindir}/xulrunner --find-gre $(%{_bindir}/xulrunner --gre-version)))
! %{__perl} -pi -e "s|\@XULRUNNER_PATH\@|"${XULRUNNER_PATH}"|g;" \
!               -e "s|\@LIBDIR\@|%{_libdir}|g;" \
!               -e "s|\@NAME\@|%{name}|g;" \
!               -e "s|\@SYSCONFDIR\@|%{_sysconfdir}|g;" \
!   %{SOURCE7} \
!   %{SOURCE8} \
!   %{SOURCE9} \
!   %{SOURCE10} \
!   dev/core/src/com/google/gwt/dev/shell/LowLevel.java \
!   dev/linux/src/com/google/gwt/dev/shell/moz/MozillaInstall.java \
!   distro-source/linux/src/mozilla-hosted-browser.conf
! 
! %{__rm} dev/linux/src/org/eclipse/swt/browser/Browser.java
! %{__rm} dev/linux/src/org/eclipse/swt/internal/Library.java
! %{__cp} -p %{SOURCE5} dev/linux/src/org/eclipse/swt/browser/Mozilla.java
! 
! %{__rm} dev/core/src/com/google/gwt/dev/shell/tomcat/CatalinaLoggerAdapter.java
! %{__rm} dev/core/src/org/apache/catalina/loader/WebappClassLoader.java
! %{__cp} -p %{SOURCE6} dev/core/src/org/apache/catalina/loader/WebappClassLoader.java
! 
  %{__mkdir_p} tools
  
  %build
! SWT_JAR=$(build-classpath swt 2>/dev/null)
! export CLASSPATH=$(build-classpath ant-contrib antlr checkstyle ecj jakarta-commons-beanutils jakarta-commons-collections jakarta-commons-logging jetty6/core/jetty6 jetty6/core/jetty6-util jcommon jfreechart junit selenium-java-client-driver servlet_2_5_api tapestry/tapestry tomcat6/catalina tomcat6/naming-resources tomcat6/tomcat-util):${SWT_JAR}:%{_datadir}/tomcat6/bin/tomcat-juli.jar
! export CLASSPATH=${CLASSPATH}:`%{_bindir}/find $(pwd)/tools/ -type f -name "*.jar" | tr '\n' ':'`
  export OPT_JAR_LIST=:
  export GWT_TOOLS=`pwd`/tools
! export GWT_VERSION=%{version}
! %{ant} -Dbuild.sysclasspath=first -Dgwt.svnrev=@%{svnrev} -Dgwt.svnrev.filename=%{svnrev}
! 
! pushd jni/linux
! %{__make} clean all
! popd
  
  %install
***************
*** 131,134 ****
--- 172,178 ----
  
  pushd gwt-linux-%{version}
+ 
+ %{__cp} -p ../build/jni/linux/libgwt-ll.so libgwt-ll.so
+ 
  # jar
  %{__mkdir_p} %{buildroot}%{_javadir}/%{name}
***************
*** 138,149 ****
      %{__ln_s} %{name}/${newjar}-%{version}.jar %{buildroot}%{_javadir}/%{name}-${newjar}-%{version}.jar
  done
- (cd %{buildroot}%{_javadir}/%{name} && %{__ln_s} dev-linux-%{version}.jar dev-%{version}.jar)
- (cd %{buildroot}%{_javadir} && %{__ln_s} %{name}/dev-%{version}.jar %{name}-dev-%{version}.jar)
  (cd %{buildroot}%{_javadir} && for jar in *-%{version}*; do %{__ln_s} ${jar} `echo $jar| sed  "s|-%{version}||g"`; done)
  (cd %{buildroot}%{_javadir}/%{name} && for jar in *-%{version}*; do %{__ln_s} ${jar} `echo $jar| sed  "s|-%{version}||g"`; done)
  
  # jni
! #%%{__mkdir_p} %{buildroot}%{_libdir}
! #%%{__cp} -p libgwt-ll.so %{buildroot}%{_libdir}/libgwt-ll.so
  
  # javadoc
--- 182,191 ----
      %{__ln_s} %{name}/${newjar}-%{version}.jar %{buildroot}%{_javadir}/%{name}-${newjar}-%{version}.jar
  done
  (cd %{buildroot}%{_javadir} && for jar in *-%{version}*; do %{__ln_s} ${jar} `echo $jar| sed  "s|-%{version}||g"`; done)
  (cd %{buildroot}%{_javadir}/%{name} && for jar in *-%{version}*; do %{__ln_s} ${jar} `echo $jar| sed  "s|-%{version}||g"`; done)
  
  # jni
! %{__mkdir_p} %{buildroot}%{_libdir}/%{name}
! %{__cp} -p libgwt-ll.so %{buildroot}%{_libdir}/%{name}/libgwt-ll.so
  
  # javadoc
***************
*** 153,173 ****
  
  # demo
! %{__mkdir} %{buildroot}%{_datadir}/%{name}-%{version}
! %{__cp} -pr samples/ %{buildroot}%{_datadir}/%{name}-%{version}/
! %{__cp} -p mozilla-hosted-browser.conf %{buildroot}%{_datadir}/%{name}-%{version}/
! %{__ln_s} %{name}-%{version} %{buildroot}%{_datadir}/%{name}
  
  # bin
  %{__mkdir_p} %{buildroot}%{_bindir}
! for script in benchmarkViewer i18nCreator junitCreator webAppCreator; do %{__cp} -p ${script} %{buildroot}%{_bindir}/%{name}-${script}; done
  popd
  
  # maven
  %{__mkdir_p} %{buildroot}%{_datadir}/maven2/poms
! %{__cp} -p %{SOURCE2} $RPM_BUILD_ROOT%{_datadir}/maven2/poms/JPP.%{name}-dev.pom
! %add_to_maven_depmap com.google.gwt gwt-dev %{version} JPP/%{name} dev
! %{__cp} -p %{SOURCE3} $RPM_BUILD_ROOT%{_datadir}/maven2/poms/JPP.%{name}-servlet.pom
  %add_to_maven_depmap com.google.gwt gwt-servlet %{version} JPP/%{name} servlet
! %{__cp} -p %{SOURCE4} $RPM_BUILD_ROOT%{_datadir}/maven2/poms/JPP.%{name}-user.pom
  %add_to_maven_depmap com.google.gwt gwt-user %{version} JPP/%{name} user
  
--- 195,223 ----
  
  # demo
! %{__mkdir} %{buildroot}%{_datadir}/%{name}
! %{__cp} -pr samples/ %{buildroot}%{_datadir}/%{name}/
! %{__mkdir_p} %{buildroot}%{_sysconfdir}/%{name}
! %{__cp} -p mozilla-hosted-browser.conf %{buildroot}%{_sysconfdir}/%{name}/mozilla-hosted-browser.conf
  
  # bin
  %{__mkdir_p} %{buildroot}%{_bindir}
! %{__cp} -p %{SOURCE7} %{buildroot}%{_bindir}/%{name}-benchmarkViewer
! %{__perl} -pi -e 's|\@LIBDIR\@|%{_libdir}|g' %{buildroot}%{_bindir}/%{name}-benchmarkViewer
! %{__cp} -p %{SOURCE8} %{buildroot}%{_bindir}/%{name}-i18nCreator
! %{__cp} -p %{SOURCE9} %{buildroot}%{_bindir}/%{name}-junitCreator
! %{__cp} -p %{SOURCE10} %{buildroot}%{_bindir}/%{name}-webAppCreator
! %if 0
! for script in benchmarkViewer i18nCreator junitCreator webAppCreator; do %{__cp} -p ${script} %{buildroot}%{_datadir}/%{name}/${script}; done
! %endif
  popd
  
  # maven
  %{__mkdir_p} %{buildroot}%{_datadir}/maven2/poms
! %{__cp} -p %{SOURCE2} %{buildroot}%{_datadir}/maven2/poms/JPP.%{name}-dev-linux.pom
! %{__perl} -pi -e 's/gwt-dev/gwt-dev-linux/g' %{buildroot}%{_datadir}/maven2/poms/JPP.%{name}-dev-linux.pom
! %add_to_maven_depmap com.google.gwt gwt-dev-linux %{version} JPP/%{name} dev-linux
! %{__cp} -p %{SOURCE3} %{buildroot}%{_datadir}/maven2/poms/JPP.%{name}-servlet.pom
  %add_to_maven_depmap com.google.gwt gwt-servlet %{version} JPP/%{name} servlet
! %{__cp} -p %{SOURCE4} %{buildroot}%{_datadir}/maven2/poms/JPP.%{name}-user.pom
  %add_to_maven_depmap com.google.gwt gwt-user %{version} JPP/%{name} user
  
***************
*** 208,213 ****
  %{_javadir}/%{name}-benchmark-viewer-%{version}.jar
  %{_javadir}/%{name}-benchmark-viewer.jar
- %{_javadir}/%{name}-dev-%{version}.jar
- %{_javadir}/%{name}-dev.jar
  %{_javadir}/%{name}-dev-linux-%{version}.jar
  %{_javadir}/%{name}-dev-linux.jar
--- 258,261 ----
***************
*** 220,225 ****
  %{_javadir}/%{name}/benchmark-viewer-%{version}.jar
  %{_javadir}/%{name}/benchmark-viewer.jar
- %{_javadir}/%{name}/dev-%{version}.jar
- %{_javadir}/%{name}/dev.jar
  %{_javadir}/%{name}/dev-linux-%{version}.jar
  %{_javadir}/%{name}/dev-linux.jar
--- 268,271 ----
***************
*** 228,233 ****
  %{_javadir}/%{name}/user-%{version}.jar
  %{_javadir}/%{name}/user.jar
! #%%attr(-,root,root) %{_libdir}/libgwt-ll.so
! %{_datadir}/maven2/poms/JPP.%{name}-dev.pom
  %{_datadir}/maven2/poms/JPP.%{name}-servlet.pom
  %{_datadir}/maven2/poms/JPP.%{name}-user.pom
--- 274,280 ----
  %{_javadir}/%{name}/user-%{version}.jar
  %{_javadir}/%{name}/user.jar
! %dir %{_libdir}/%{name}
! %attr(-,root,root) %{_libdir}/%{name}/libgwt-ll.so
! %{_datadir}/maven2/poms/JPP.%{name}-dev-linux.pom
  %{_datadir}/maven2/poms/JPP.%{name}-servlet.pom
  %{_datadir}/maven2/poms/JPP.%{name}-user.pom
***************
*** 237,240 ****
--- 284,289 ----
  %attr(-,root,root) %{_libdir}/gcj/%{name}/*
  %endif
+ %dir %{_sysconfdir}/%{name}
+ %config(noreplace) %{_sysconfdir}/%{name}/mozilla-hosted-browser.conf
  
  %files javadoc
***************
*** 245,250 ****
  %files demo
  %defattr(0644,root,root,0755)
! %{_datadir}/%{name}-%{version}
! %{_datadir}/%{name}
  
  %changelog
--- 294,298 ----
  %files demo
  %defattr(0644,root,root,0755)
! %{_datadir}/%{name}/samples
  
  %changelog




More information about the JPackage-commits mailing list