Bug 398946 - Remove JS_STATIC_DLL_CALLBACK and JS_DLL_CALLBACK from the tree; r=(benjamin + bent.mozilla)
authorArpad Borsos <arpad.borsos@googlemail.com>
Sun, 07 Sep 2008 00:21:43 +0200
changeset 18907 e71240d4b28c3c520a3faa951c946c3f7d7cb924
parent 18906 c60ed53702dd722506b81d4365be8deb8789d527
child 18908 b4ccb313bbb78130fe6d36a9db7aa672a5256d17
push idunknown
push userunknown
push dateunknown
bugs398946
milestone1.9.1b1pre
Bug 398946 - Remove JS_STATIC_DLL_CALLBACK and JS_DLL_CALLBACK from the tree; r=(benjamin + bent.mozilla)
caps/include/nsScriptSecurityManager.h
caps/src/nsJSPrincipals.cpp
caps/src/nsScriptSecurityManager.cpp
content/xbl/src/nsXBLBinding.cpp
content/xbl/src/nsXBLDocumentInfo.cpp
dom/src/base/nsDOMClassInfo.cpp
dom/src/base/nsDOMClassInfo.h
dom/src/base/nsJSEnvironment.cpp
dom/src/base/nsJSEnvironment.h
dom/src/json/nsJSON.cpp
dom/src/threads/nsDOMThreadService.cpp
dom/src/threads/nsDOMWorkerThread.cpp
extensions/jssh/nsJSSh.cpp
extensions/pref/autoconfig/src/nsJSConfigTriggers.cpp
js/jsd/jsd.h
js/jsd/jsd_atom.c
js/jsd/jsd_high.c
js/jsd/jsd_hook.c
js/jsd/jsd_obj.c
js/jsd/jsd_scpt.c
js/jsd/jsd_step.c
js/jsd/jsd_xpc.cpp
js/jsd/jsdebug.h
js/src/js.cpp
js/src/jsapi.cpp
js/src/jsapi.h
js/src/jsatom.cpp
js/src/jscntxt.cpp
js/src/jscntxt.h
js/src/jsdbgapi.cpp
js/src/jsdbgapi.h
js/src/jsdhash.h
js/src/jsfun.cpp
js/src/jsgc.cpp
js/src/jshash.h
js/src/jsify.pl
js/src/jsobj.cpp
js/src/jsparse.cpp
js/src/jsprvtd.h
js/src/jspubtd.h
js/src/jsscope.cpp
js/src/jsscript.cpp
js/src/jsstr.cpp
js/src/jstypes.h
js/src/jsxml.cpp
js/src/jsxml.h
js/src/liveconnect/README.html
js/src/liveconnect/jsj_JSObject.c
js/src/liveconnect/jsj_JavaArray.c
js/src/liveconnect/jsj_JavaClass.c
js/src/liveconnect/jsj_JavaMember.c
js/src/liveconnect/jsj_JavaObject.c
js/src/liveconnect/jsj_JavaPackage.c
js/src/liveconnect/jsj_class.c
js/src/liveconnect/jsj_hash.h
js/src/liveconnect/jsj_private.h
js/src/liveconnect/jsj_simpleapi.c
js/src/liveconnect/jsj_utils.c
js/src/plify_jsdhash.sed
js/src/prmjtime.cpp
js/src/xpconnect/loader/mozJSComponentLoader.cpp
js/src/xpconnect/loader/mozJSSubScriptLoader.cpp
js/src/xpconnect/shell/xpcshell.cpp
js/src/xpconnect/src/XPCCrossOriginWrapper.cpp
js/src/xpconnect/src/XPCDispObject.cpp
js/src/xpconnect/src/XPCDispParamPropJSClass.cpp
js/src/xpconnect/src/XPCDispPrivate.h
js/src/xpconnect/src/XPCDispTearOff.cpp
js/src/xpconnect/src/XPCIDispatchExtension.cpp
js/src/xpconnect/src/XPCNativeWrapper.cpp
js/src/xpconnect/src/XPCSafeJSObjectWrapper.cpp
js/src/xpconnect/src/XPCWrapper.cpp
js/src/xpconnect/src/nsXPConnect.cpp
js/src/xpconnect/src/xpccomponents.cpp
js/src/xpconnect/src/xpcconvert.cpp
js/src/xpconnect/src/xpcdebug.cpp
js/src/xpconnect/src/xpcjsruntime.cpp
js/src/xpconnect/src/xpcmaps.cpp
js/src/xpconnect/src/xpcmaps.h
js/src/xpconnect/src/xpcprivate.h
js/src/xpconnect/src/xpcstring.cpp
js/src/xpconnect/src/xpcthreadcontext.cpp
js/src/xpconnect/src/xpcwrappedjsclass.cpp
js/src/xpconnect/src/xpcwrappednativejsops.cpp
js/src/xpconnect/src/xpcwrappednativescope.cpp
js/src/xpconnect/tests/TestXPC.cpp
js/src/xpconnect/tools/src/nsXPCToolsCompiler.cpp
js/src/xpconnect/tools/src/nsXPCToolsProfiler.cpp
modules/oji/src/lcglue.cpp
modules/plugin/base/src/nsJSNPRuntime.cpp
xpinstall/src/nsJSInstallTriggerGlobal.cpp
--- a/caps/include/nsScriptSecurityManager.h
+++ b/caps/include/nsScriptSecurityManager.h
@@ -418,17 +418,17 @@ public:
     }
 
 private:
 
     // GetScriptSecurityManager is the only call that can make one
     nsScriptSecurityManager();
     virtual ~nsScriptSecurityManager();
 
-    static JSBool JS_DLL_CALLBACK
+    static JSBool
     CheckObjectAccess(JSContext *cx, JSObject *obj,
                       jsval id, JSAccessMode mode,
                       jsval *vp);
 
     // Returns null if a principal cannot be found; generally callers
     // should error out at that point.
     static nsIPrincipal*
     doGetObjectPrincipal(JSObject *obj
--- a/caps/src/nsJSPrincipals.cpp
+++ b/caps/src/nsJSPrincipals.cpp
@@ -44,41 +44,41 @@
 #include "nsCOMPtr.h"
 #include "jsapi.h"
 #include "jsxdrapi.h"
 #include "nsIJSRuntimeService.h"
 #include "nsIServiceManager.h"
 #include "nsMemory.h"
 #include "nsStringBuffer.h"
 
-JS_STATIC_DLL_CALLBACK(void *)
+static void *
 nsGetPrincipalArray(JSContext *cx, JSPrincipals *prin)
 {
     return nsnull;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 nsGlobalPrivilegesEnabled(JSContext *cx, JSPrincipals *jsprin)
 {
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 nsJSPrincipalsSubsume(JSPrincipals *jsprin, JSPrincipals *other)
 {
     nsJSPrincipals *nsjsprin = static_cast<nsJSPrincipals *>(jsprin);
     nsJSPrincipals *nsother  = static_cast<nsJSPrincipals *>(other);
 
     JSBool result;
     nsresult rv = nsjsprin->nsIPrincipalPtr->Subsumes(nsother->nsIPrincipalPtr,
                                                       &result);
     return NS_SUCCEEDED(rv) && result;
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 nsDestroyJSPrincipals(JSContext *cx, struct JSPrincipals *jsprin)
 {
     nsJSPrincipals *nsjsprin = static_cast<nsJSPrincipals *>(jsprin);
 
     // We need to destroy the nsIPrincipal. We'll do this by adding
     // to the refcount and calling release
 
     // Note that we don't want to use NS_IF_RELEASE because it will try
@@ -94,17 +94,17 @@ nsDestroyJSPrincipals(JSContext *cx, str
 #else
     nsjsprin->refcount++;
 #endif
     nsjsprin->nsIPrincipalPtr->Release();
     // The nsIPrincipal that we release owns the JSPrincipal struct,
     // so we don't need to worry about "codebase"
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 nsTranscodeJSPrincipals(JSXDRState *xdr, JSPrincipals **jsprinp)
 {
     nsresult rv;
 
     if (xdr->mode == JSXDR_ENCODE) {
         nsIObjectOutputStream *stream =
             reinterpret_cast<nsIObjectOutputStream*>(xdr->userdata);
 
--- a/caps/src/nsScriptSecurityManager.cpp
+++ b/caps/src/nsScriptSecurityManager.cpp
@@ -446,17 +446,17 @@ NS_IMPL_ISUPPORTS5(nsScriptSecurityManag
                    nsIChannelEventSink,
                    nsIObserver)
 
 ///////////////////////////////////////////////////
 // Methods implementing nsIScriptSecurityManager //
 ///////////////////////////////////////////////////
 
 ///////////////// Security Checks /////////////////
-JSBool JS_DLL_CALLBACK
+JSBool
 nsScriptSecurityManager::CheckObjectAccess(JSContext *cx, JSObject *obj,
                                            jsval id, JSAccessMode mode,
                                            jsval *vp)
 {
     // Get the security manager
     nsScriptSecurityManager *ssm =
         nsScriptSecurityManager::GetScriptSecurityManager();
 
--- a/content/xbl/src/nsXBLBinding.cpp
+++ b/content/xbl/src/nsXBLBinding.cpp
@@ -108,28 +108,28 @@
 #include "nsJSUtils.h"
 
 // Helper classes
 
 /***********************************************************************/
 //
 // The JS class for XBLBinding
 //
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XBLFinalize(JSContext *cx, JSObject *obj)
 {
   nsIXBLDocumentInfo* docInfo =
     static_cast<nsIXBLDocumentInfo*>(::JS_GetPrivate(cx, obj));
   NS_RELEASE(docInfo);
   
   nsXBLJSClass* c = static_cast<nsXBLJSClass*>(::JS_GET_CLASS(cx, obj));
   c->Drop();
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XBLResolve(JSContext *cx, JSObject *obj, jsval id, uintN flags,
            JSObject **objp)
 {
   // Note: if we get here, that means that the implementation for some binding
   // was installed, which means that AllowScripts() tested true.  Hence no need
   // to do checks like that here.
   
   // Default to not resolving things.
--- a/content/xbl/src/nsXBLDocumentInfo.cpp
+++ b/content/xbl/src/nsXBLDocumentInfo.cpp
@@ -212,17 +212,17 @@ NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(
   NS_INTERFACE_MAP_ENTRY(nsIScriptGlobalObject)
   NS_INTERFACE_MAP_ENTRY(nsIScriptObjectPrincipal)
   NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIScriptGlobalObject)
 NS_INTERFACE_MAP_END
 
 NS_IMPL_CYCLE_COLLECTING_ADDREF_AMBIGUOUS(nsXBLDocGlobalObject, nsIScriptGlobalObject)
 NS_IMPL_CYCLE_COLLECTING_RELEASE_AMBIGUOUS(nsXBLDocGlobalObject, nsIScriptGlobalObject)
 
-void JS_DLL_CALLBACK
+void
 XBL_ProtoErrorReporter(JSContext *cx,
                        const char *message,
                        JSErrorReport *report)
 {
   // Make an nsIScriptError and populate it with information from
   // this error.
   nsCOMPtr<nsIScriptError>
     errorObject(do_CreateInstance("@mozilla.org/scripterror;1"));
--- a/dom/src/base/nsDOMClassInfo.cpp
+++ b/dom/src/base/nsDOMClassInfo.cpp
@@ -4342,17 +4342,17 @@ static JSClass sGlobalScopePolluterClass
   nsWindowSH::GlobalScopePolluterGetProperty,
   nsWindowSH::SecurityCheckOnSetProp, JS_EnumerateStub,
   (JSResolveOp)nsWindowSH::GlobalScopePolluterNewResolve, JS_ConvertStub,
   nsHTMLDocumentSH::ReleaseDocument
 };
 
 
 // static
-JSBool JS_DLL_CALLBACK
+JSBool
 nsWindowSH::GlobalScopePolluterGetProperty(JSContext *cx, JSObject *obj,
                                            jsval id, jsval *vp)
 {
   // Someone is accessing a element by referencing its name/id in the
   // global scope, do a security check to make sure that's ok.
 
   nsresult rv =
     sSecMan->CheckPropertyAccess(cx, ::JS_GetGlobalForObject(cx, obj),
@@ -4369,17 +4369,17 @@ nsWindowSH::GlobalScopePolluterGetProper
   // Print a warning on the console so developers have a chance to
   // catch and fix these mistakes.
   PrintWarningOnConsole(cx, "GlobalScopeElementReference");
 
   return JS_TRUE;
 }
 
 // static
-JSBool JS_DLL_CALLBACK
+JSBool
 nsWindowSH::SecurityCheckOnSetProp(JSContext *cx, JSObject *obj, jsval id,
                                    jsval *vp)
 {
   // Someone is accessing a element by referencing its name/id in the
   // global scope, do a security check to make sure that's ok.
 
   nsresult rv =
     sSecMan->CheckPropertyAccess(cx, ::JS_GetGlobalForObject(cx, obj),
@@ -4387,17 +4387,17 @@ nsWindowSH::SecurityCheckOnSetProp(JSCon
                                  nsIXPCSecurityManager::ACCESS_SET_PROPERTY);
 
   // If !NS_SUCCEEDED(rv) the security check failed. The security
   // manager set a JS exception for us.
   return NS_SUCCEEDED(rv);
 }
 
 // static
-JSBool JS_DLL_CALLBACK
+JSBool
 nsWindowSH::GlobalScopePolluterNewResolve(JSContext *cx, JSObject *obj,
                                           jsval id, uintN flags,
                                           JSObject **objp)
 {
   if (flags & (JSRESOLVE_ASSIGNING | JSRESOLVE_DECLARING |
                JSRESOLVE_CLASSNAME | JSRESOLVE_QUALIFIED) ||
       !JSVAL_IS_STRING(id)) {
     // Nothing to do here if we're either assigning or declaring,
@@ -5821,17 +5821,17 @@ nsWindowSH::GlobalResolve(nsGlobalWindow
     *did_resolve = PR_TRUE;
   }
 
   return rv;
 }
 
 // Native code for window._content getter, this simply maps
 // window._content to window.content for backwards compatibility only.
-static JSBool JS_DLL_CALLBACK
+static JSBool
 ContentWindowGetter(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                     jsval *rval)
 {
   return ::JS_GetProperty(cx, obj, "content", rval);
 }
 
 NS_IMETHODIMP
 nsWindowSH::NewResolve(nsIXPConnectWrappedNative *wrapper, JSContext *cx,
@@ -7025,17 +7025,17 @@ nsEventReceiverSH::ReallyIsEventName(jsv
             id == sOnselect_id       ||
             id == sOnsubmit_id);
   }
 
   return PR_FALSE;
 }
 
 // static
-JSBool JS_DLL_CALLBACK
+JSBool
 nsEventReceiverSH::AddEventListenerHelper(JSContext *cx, JSObject *obj,
                                           uintN argc, jsval *argv, jsval *rval)
 {
   if (argc < 3 || argc > 4) {
     ThrowJSException(cx, NS_ERROR_XPC_NOT_ENOUGH_ARGS);
 
     return JS_FALSE;
   }
@@ -8011,17 +8011,17 @@ nsHTMLDocumentSH::ResolveImpl(JSContext 
   // JSVAL_TO_STRING() here.
   JSString *str = JS_ValueToString(cx, id);
   NS_ENSURE_TRUE(str, NS_ERROR_UNEXPECTED);
 
   return doc->ResolveName(nsDependentJSString(str), nsnull, result);
 }
 
 // static
-JSBool JS_DLL_CALLBACK
+JSBool
 nsHTMLDocumentSH::DocumentOpen(JSContext *cx, JSObject *obj, uintN argc,
                                jsval *argv, jsval *rval)
 {
   if (argc > 2) {
     JSObject *global = ::JS_GetGlobalForObject(cx, obj);
 
     // DOM0 quirk that makes document.open() call window.open() if
     // called with 3 or more arguments.
@@ -8171,17 +8171,17 @@ nsHTMLDocumentSH::GetDocumentAllNodeList
     nsDOMClassInfo::ThrowJSException(cx, rv);
 
     return JS_FALSE;
   }
 
   return *nodeList != nsnull;
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 nsHTMLDocumentSH::DocumentAllGetProperty(JSContext *cx, JSObject *obj,
                                          jsval id, jsval *vp)
 {
   // document.all.item and .namedItem get their value in the
   // newResolve hook, so nothing to do for those properties here. And
   // we need to return early to prevent <div id="item"> from shadowing
   // document.all.item(), etc.
   if (id == sItem_id || id == sNamedItem_id) {
@@ -8255,17 +8255,17 @@ nsHTMLDocumentSH::DocumentAllGetProperty
     }
   } else {
     *vp = JSVAL_VOID;
   }
 
   return JS_TRUE;
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 nsHTMLDocumentSH::DocumentAllNewResolve(JSContext *cx, JSObject *obj, jsval id,
                                         uintN flags, JSObject **objp)
 {
   if (flags & JSRESOLVE_ASSIGNING) {
     // Nothing to do here if we're assigning
 
     return JS_TRUE;
   }
@@ -8331,25 +8331,25 @@ nsHTMLDocumentSH::DocumentAllNewResolve(
   }
 
   return ok;
 }
 
 // Finalize hook used by document related JS objects, but also by
 // sGlobalScopePolluterClass!
 
-void JS_DLL_CALLBACK
+void
 nsHTMLDocumentSH::ReleaseDocument(JSContext *cx, JSObject *obj)
 {
   nsIHTMLDocument *doc = (nsIHTMLDocument *)::JS_GetPrivate(cx, obj);
 
   NS_IF_RELEASE(doc);
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 nsHTMLDocumentSH::CallToGetPropMapper(JSContext *cx, JSObject *obj, uintN argc,
                                       jsval *argv, jsval *rval)
 {
   // Handle document.all("foo") style access to document.all.
 
   if (argc != 1) {
     // XXX: Should throw NS_ERROR_XPC_NOT_ENOUGH_ARGS for argc < 1,
     // and create a new NS_ERROR_XPC_TOO_MANY_ARGS for argc > 1? IE
@@ -8390,17 +8390,17 @@ GetDocumentAllHelper(JSContext *cx, JSOb
 {
   while (obj && JS_GET_CLASS(cx, obj) != &sHTMLDocumentAllHelperClass) {
     obj = ::JS_GetPrototype(cx, obj);
   }
 
   return obj;
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 nsHTMLDocumentSH::DocumentAllHelperGetProperty(JSContext *cx, JSObject *obj,
                                                jsval id, jsval *vp)
 {
   if (id != nsDOMClassInfo::sAll_id) {
     return JS_TRUE;
   }
 
   JSObject *helper = GetDocumentAllHelper(cx, obj);
@@ -8456,17 +8456,17 @@ nsHTMLDocumentSH::DocumentAllHelperGetPr
 
       *vp = OBJECT_TO_JSVAL(all);
     }
   }
 
   return JS_TRUE;
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 nsHTMLDocumentSH::DocumentAllHelperNewResolve(JSContext *cx, JSObject *obj,
                                               jsval id, uintN flags,
                                               JSObject **objp)
 {
   if (id == nsDOMClassInfo::sAll_id) {
     // document.all is resolved for the first time. Define it.
     JSObject *helper = GetDocumentAllHelper(cx, obj);
 
@@ -8479,17 +8479,17 @@ nsHTMLDocumentSH::DocumentAllHelperNewRe
       *objp = helper;
     }
   }
 
   return JS_TRUE;
 }
 
 
-JSBool JS_DLL_CALLBACK
+JSBool
 nsHTMLDocumentSH::DocumentAllTagsNewResolve(JSContext *cx, JSObject *obj,
                                             jsval id, uintN flags,
                                             JSObject **objp)
 {
   if (JSVAL_IS_STRING(id)) {
     nsIHTMLDocument *doc = (nsIHTMLDocument *)::JS_GetPrivate(cx, obj);
 
     JSString *str = JSVAL_TO_STRING(id);
@@ -8690,17 +8690,17 @@ nsHTMLDocumentSH::GetProperty(nsIXPConne
   }
 
   return nsDocumentSH::GetProperty(wrapper, cx, obj, id, vp, _retval);
 }
 
 // HTMLElement helper
 
 // static
-JSBool JS_DLL_CALLBACK
+JSBool
 nsHTMLElementSH::ScrollIntoView(JSContext *cx, JSObject *obj, uintN argc,
                                 jsval *argv, jsval *rval)
 {
   nsCOMPtr<nsIXPConnectWrappedNative> wrapper;
 
   nsresult rv =
     sXPConnect->GetWrappedNativeOfJSObject(cx, obj, getter_AddRefs(wrapper));
   if (NS_FAILED(rv)) {
@@ -9707,17 +9707,17 @@ nsHTMLOptionsCollectionSH::NewResolve(ns
     *objp = obj;
     
     return fnc ? NS_OK : NS_ERROR_UNEXPECTED;
   }
 
   return nsHTMLCollectionSH::NewResolve(wrapper, cx, obj, id, flags, objp, _retval);
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 nsHTMLOptionsCollectionSH::Add(JSContext *cx, JSObject *obj, uintN argc,
                                jsval *argv, jsval *rval)
 {
   *rval = JSVAL_VOID;
 
   nsCOMPtr<nsIXPConnectWrappedNative> wrapper;
   nsresult rv =
     sXPConnect->GetWrappedNativeOfJSObject(cx, obj, getter_AddRefs(wrapper));
--- a/dom/src/base/nsDOMClassInfo.h
+++ b/dom/src/base/nsDOMClassInfo.h
@@ -360,20 +360,18 @@ protected:
 
     if (str[0] == 'o' && str[1] == 'n') {
       return ReallyIsEventName(id, str[2]);
     }
 
     return PR_FALSE;
   }
 
-  static JSBool JS_DLL_CALLBACK AddEventListenerHelper(JSContext *cx,
-                                                       JSObject *obj,
-                                                       uintN argc, jsval *argv,
-                                                       jsval *rval);
+  static JSBool AddEventListenerHelper(JSContext *cx, JSObject *obj,
+                                       uintN argc, jsval *argv, jsval *rval);
 
   nsresult RegisterCompileHandler(nsIXPConnectWrappedNative *wrapper,
                                   JSContext *cx, JSObject *obj, jsval id,
                                   PRBool compile, PRBool remove,
                                   PRBool *did_define);
 
 public:
   NS_IMETHOD NewResolve(nsIXPConnectWrappedNative *wrapper, JSContext *cx,
@@ -449,28 +447,23 @@ public:
                       JSObject *obj);
   NS_IMETHOD Equality(nsIXPConnectWrappedNative *wrapper, JSContext * cx,
                       JSObject * obj, jsval val, PRBool *bp);
   NS_IMETHOD OuterObject(nsIXPConnectWrappedNative *wrapper, JSContext * cx,
                          JSObject * obj, JSObject * *_retval);
   NS_IMETHOD InnerObject(nsIXPConnectWrappedNative *wrapper, JSContext * cx,
                          JSObject * obj, JSObject * *_retval);
 
-  static JSBool JS_DLL_CALLBACK GlobalScopePolluterNewResolve(JSContext *cx,
-                                                              JSObject *obj,
-                                                              jsval id,
-                                                              uintN flags,
-                                                              JSObject **objp);
-  static JSBool JS_DLL_CALLBACK GlobalScopePolluterGetProperty(JSContext *cx,
-                                                               JSObject *obj,
-                                                               jsval id,
-                                                               jsval *vp);
-  static JSBool JS_DLL_CALLBACK SecurityCheckOnSetProp(JSContext *cx,
-                                                       JSObject *obj, jsval id,
-                                                       jsval *vp);
+  static JSBool GlobalScopePolluterNewResolve(JSContext *cx, JSObject *obj,
+                                              jsval id, uintN flags,
+                                              JSObject **objp);
+  static JSBool GlobalScopePolluterGetProperty(JSContext *cx, JSObject *obj,
+                                               jsval id, jsval *vp);
+  static JSBool SecurityCheckOnSetProp(JSContext *cx, JSObject *obj, jsval id,
+                                       jsval *vp);
   static void InvalidateGlobalScopePolluter(JSContext *cx, JSObject *obj);
   static nsresult InstallGlobalScopePolluter(JSContext *cx, JSObject *obj,
                                              nsIHTMLDocument *doc);
 
   static nsIClassInfo *doCreate(nsDOMClassInfoData* aData)
   {
     return new nsWindowSH(aData);
   }
@@ -840,49 +833,38 @@ protected:
 
   virtual ~nsHTMLDocumentSH()
   {
   }
 
   static nsresult ResolveImpl(JSContext *cx,
                               nsIXPConnectWrappedNative *wrapper, jsval id,
                               nsISupports **result);
-  static JSBool JS_DLL_CALLBACK DocumentOpen(JSContext *cx, JSObject *obj,
-                                             uintN argc, jsval *argv,
-                                             jsval *rval);
+  static JSBool DocumentOpen(JSContext *cx, JSObject *obj, uintN argc,
+                             jsval *argv, jsval *rval);
   static JSBool GetDocumentAllNodeList(JSContext *cx, JSObject *obj,
                                        nsIDOMDocument *doc,
                                        nsIDOMNodeList **nodeList);
 
 public:
-  static JSBool JS_DLL_CALLBACK DocumentAllGetProperty(JSContext *cx,
-                                                       JSObject *obj, jsval id,
-                                                       jsval *vp);
-  static JSBool JS_DLL_CALLBACK DocumentAllNewResolve(JSContext *cx,
-                                                      JSObject *obj, jsval id,
-                                                      uintN flags,
-                                                      JSObject **objp);
-  static void JS_DLL_CALLBACK ReleaseDocument(JSContext *cx, JSObject *obj);
-  static JSBool JS_DLL_CALLBACK CallToGetPropMapper(JSContext *cx,
-                                                    JSObject *obj, uintN argc,
-                                                    jsval *argv, jsval *rval);
-  static JSBool JS_DLL_CALLBACK DocumentAllHelperGetProperty(JSContext *cx,
-                                                             JSObject *obj,
-                                                             jsval id,
-                                                             jsval *vp);
-  static JSBool JS_DLL_CALLBACK DocumentAllHelperNewResolve(JSContext *cx,
-                                                            JSObject *obj,
-                                                            jsval id,
-                                                            uintN flags,
-                                                            JSObject **objp);
-  static JSBool JS_DLL_CALLBACK DocumentAllTagsNewResolve(JSContext *cx,
-                                                          JSObject *obj,
-                                                          jsval id,
-                                                          uintN flags,
-                                                          JSObject **objp);
+  static JSBool DocumentAllGetProperty(JSContext *cx, JSObject *obj, jsval id,
+                                       jsval *vp);
+  static JSBool DocumentAllNewResolve(JSContext *cx, JSObject *obj, jsval id,
+                                      uintN flags, JSObject **objp);
+  static void ReleaseDocument(JSContext *cx, JSObject *obj);
+  static JSBool CallToGetPropMapper(JSContext *cx, JSObject *obj, uintN argc,
+                                    jsval *argv, jsval *rval);
+  static JSBool DocumentAllHelperGetProperty(JSContext *cx, JSObject *obj,
+                                             jsval id, jsval *vp);
+  static JSBool DocumentAllHelperNewResolve(JSContext *cx, JSObject *obj,
+                                            jsval id, uintN flags,
+                                            JSObject **objp);
+  static JSBool DocumentAllTagsNewResolve(JSContext *cx, JSObject *obj,
+                                          jsval id, uintN flags,
+                                          JSObject **objp);
 
   NS_IMETHOD NewResolve(nsIXPConnectWrappedNative *wrapper, JSContext *cx,
                         JSObject *obj, jsval id, PRUint32 flags,
                         JSObject **objp, PRBool *_retval);
   NS_IMETHOD GetProperty(nsIXPConnectWrappedNative *wrapper, JSContext *cx,
                          JSObject *obj, jsval id, jsval *vp, PRBool *_retval);
 
   static nsIClassInfo *doCreate(nsDOMClassInfoData* aData)
@@ -900,19 +882,18 @@ protected:
   nsHTMLElementSH(nsDOMClassInfoData* aData) : nsElementSH(aData)
   {
   }
 
   virtual ~nsHTMLElementSH()
   {
   }
 
-  static JSBool JS_DLL_CALLBACK ScrollIntoView(JSContext *cx, JSObject *obj,
-                                               uintN argc, jsval *argv,
-                                               jsval *rval);
+  static JSBool ScrollIntoView(JSContext *cx, JSObject *obj, uintN argc,
+                               jsval *argv, jsval *rval);
 
 public:
   NS_IMETHOD NewResolve(nsIXPConnectWrappedNative *wrapper, JSContext *cx,
                         JSObject *obj, jsval id, PRUint32 flags,
                         JSObject **objp, PRBool *_retval);
 
   static nsIClassInfo *doCreate(nsDOMClassInfoData* aData)
   {
@@ -1048,18 +1029,18 @@ protected:
     : nsHTMLCollectionSH(aData)
   {
   }
 
   virtual ~nsHTMLOptionsCollectionSH()
   {
   }
 
-  static JSBool JS_DLL_CALLBACK Add(JSContext *cx, JSObject *obj, uintN argc,
-                                    jsval *argv, jsval *rval);
+  static JSBool Add(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
+                    jsval *rval);
 
 public:
   NS_IMETHOD SetProperty(nsIXPConnectWrappedNative *wrapper, JSContext *cx,
                          JSObject *obj, jsval id, jsval *vp, PRBool *_retval);
   NS_IMETHOD NewResolve(nsIXPConnectWrappedNative *wrapper, JSContext *cx,
                         JSObject *obj, jsval id, PRUint32 flags,
                         JSObject **objp, PRBool *_retval);
   
--- a/dom/src/base/nsJSEnvironment.cpp
+++ b/dom/src/base/nsJSEnvironment.cpp
@@ -413,17 +413,17 @@ NS_HandleScriptError(nsIScriptGlobalObje
   }
   return called;
 }
 
 // NOTE: This function could be refactored to use the above.  The only reason
 // it has not been done is that the code below only fills the error event
 // after it has a good nsPresContext - whereas using the above function
 // would involve always filling it.  Is that a concern?
-void JS_DLL_CALLBACK
+void
 NS_ScriptErrorReporter(JSContext *cx,
                        const char *message,
                        JSErrorReport *report)
 {
   // XXX this means we are not going to get error reports on non DOM contexts
   nsIScriptContext *context = nsJSUtils::GetDynamicScriptContext(cx);
 
   nsEventStatus status = nsEventStatus_eIgnore;
@@ -601,17 +601,17 @@ NS_ScriptErrorReporter(JSContext *cx,
             (report->linebuf &&
              report->linebuf[strlen(report->linebuf)-1] != '\n')
             ? "\n"
             : ""));
   }
 #endif
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 LocaleToUnicode(JSContext *cx, char *src, jsval *rval)
 {
   nsresult rv;
 
   if (!gDecoder) {
     // use app default locale
     nsCOMPtr<nsILocaleService> localeService =
       do_GetService(NS_LOCALESERVICE_CONTRACTID, &rv);
@@ -694,29 +694,29 @@ ChangeCase(JSContext *cx, JSString *src,
     return JS_FALSE;
   }
 
   *rval = STRING_TO_JSVAL(ucstr);
 
   return JS_TRUE;
 }
 
-static JSBool JS_DLL_CALLBACK
+static JSBool
 LocaleToUpperCase(JSContext *cx, JSString *src, jsval *rval)
 {
   return ChangeCase(cx, src, rval, ToUpperCase);
 }
 
-static JSBool JS_DLL_CALLBACK
+static JSBool
 LocaleToLowerCase(JSContext *cx, JSString *src, jsval *rval)
 {
   return ChangeCase(cx, src, rval, ToLowerCase);
 }
 
-static JSBool JS_DLL_CALLBACK
+static JSBool
 LocaleCompare(JSContext *cx, JSString *src1, JSString *src2, jsval *rval)
 {
   nsresult rv;
 
   if (!gCollation) {
     nsCOMPtr<nsILocaleService> localeService =
       do_GetService(NS_LOCALESERVICE_CONTRACTID, &rv);
 
@@ -865,17 +865,17 @@ GetPromptFromContext(nsJSContext* ctx)
   NS_ENSURE_TRUE(ireq, nsnull);
 
   // Get the nsIPrompt interface from the docshell
   nsIPrompt* prompt;
   ireq->GetInterface(NS_GET_IID(nsIPrompt), (void**)&prompt);
   return prompt;
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 nsJSContext::DOMOperationCallback(JSContext *cx)
 {
   nsresult rv;
 
   // Get the native context
   nsJSContext *ctx = static_cast<nsJSContext *>(::JS_GetContextPrivate(cx));
 
   if (!ctx) {
@@ -2879,28 +2879,28 @@ nsJSContext::FindXPCNativeWrapperClass(n
 
 static JSPropertySpec OptionsProperties[] = {
   {"strict",    (int8)JSOPTION_STRICT,   JSPROP_ENUMERATE | JSPROP_PERMANENT},
   {"werror",    (int8)JSOPTION_WERROR,   JSPROP_ENUMERATE | JSPROP_PERMANENT},
   {"relimit",   (int8)JSOPTION_RELIMIT,  JSPROP_ENUMERATE | JSPROP_PERMANENT},
   {0}
 };
 
-static JSBool JS_DLL_CALLBACK
+static JSBool
 GetOptionsProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   if (JSVAL_IS_INT(id)) {
     uint32 optbit = (uint32) JSVAL_TO_INT(id);
     if ((optbit & (optbit - 1)) == 0 && optbit <= JSOPTION_WERROR)
       *vp = (JS_GetOptions(cx) & optbit) ? JSVAL_TRUE : JSVAL_FALSE;
   }
   return JS_TRUE;
 }
 
-static JSBool JS_DLL_CALLBACK
+static JSBool
 SetOptionsProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   if (JSVAL_IS_INT(id)) {
     uint32 optbit = (uint32) JSVAL_TO_INT(id);
 
     // Don't let options other than strict, werror, or relimit be set -- it
     // would be bad if web page script could clear
     // JSOPTION_PRIVATE_IS_NSISUPPORTS!
@@ -3569,17 +3569,17 @@ nsJSContext::FireGCTimer(PRBool aLoadInP
                                                NS_GC_DELAY,
                              nsITimer::TYPE_ONE_SHOT);
 
   sLoadInProgressGCTimer = aLoadInProgress;
 
   first = PR_FALSE;
 }
 
-static JSBool JS_DLL_CALLBACK
+static JSBool
 DOMGCCallback(JSContext *cx, JSGCStatus status)
 {
   JSBool result = gOldJSGCCallback ? gOldJSGCCallback(cx, status) : JS_TRUE;
 
   if (status == JSGC_BEGIN && !NS_IsMainThread())
     return JS_FALSE;
 
   return result;
@@ -3725,17 +3725,17 @@ MaxScriptRunTimePrefChangedCallback(cons
 static int PR_CALLBACK
 ReportAllJSExceptionsPrefChangedCallback(const char* aPrefName, void* aClosure)
 {
   PRBool reportAll = nsContentUtils::GetBoolPref(aPrefName, PR_FALSE);
   nsContentUtils::XPConnect()->SetReportAllJSExceptions(reportAll);
   return 0;
 }
 
-JS_STATIC_DLL_CALLBACK(JSPrincipals *)
+static JSPrincipals *
 ObjectPrincipalFinder(JSContext *cx, JSObject *obj)
 {
   if (!sSecurityManager)
     return nsnull;
 
   nsCOMPtr<nsIPrincipal> principal;
   nsresult rv =
     sSecurityManager->GetObjectPrincipal(cx, obj,
--- a/dom/src/base/nsJSEnvironment.h
+++ b/dom/src/base/nsJSEnvironment.h
@@ -289,17 +289,17 @@ private:
   // global object wrapper while the nsJSContext is alive. This cuts
   // down on the number of rooting and unrooting calls XPConnect has
   // to make when the global object is touched in JS.
 
   nsCOMPtr<nsISupports> mGlobalWrapperRef;
 
   static int PR_CALLBACK JSOptionChangedCallback(const char *pref, void *data);
 
-  static JSBool JS_DLL_CALLBACK DOMOperationCallback(JSContext *cx);
+  static JSBool DOMOperationCallback(JSContext *cx);
 };
 
 class nsIJSRuntimeService;
 
 class nsJSRuntime : public nsIScriptRuntime
 {
 public:
   // let people who can see us use our runtime for convenience.
@@ -352,11 +352,11 @@ public:
 };
 
 NS_DEFINE_STATIC_IID_ACCESSOR(nsIJSArgArray, NS_IJSARGARRAY_IID)
 
 /* factory functions */
 nsresult NS_CreateJSRuntime(nsIScriptRuntime **aRuntime);
 
 /* prototypes */
-void JS_DLL_CALLBACK NS_ScriptErrorReporter(JSContext *cx, const char *message, JSErrorReport *report);
+void NS_ScriptErrorReporter(JSContext *cx, const char *message, JSErrorReport *report);
 
 #endif /* nsJSEnvironment_h___ */
--- a/dom/src/json/nsJSON.cpp
+++ b/dom/src/json/nsJSON.cpp
@@ -719,17 +719,17 @@ NS_NewJSON(nsISupports* aOuter, REFNSIID
 
   NS_ADDREF(json);
   *aResult = json;
 
   return NS_OK;
 }
 
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 trace_json_stack(JSTracer *trc, JSTempValueRooter *tvr)
 {
   nsJSONObjectStack *tmp = static_cast<nsJSONObjectStack *>(tvr);
 
   for (PRUint32 i = 0; i < tmp->Length(); ++i) {
     JS_CALL_OBJECT_TRACER(trc, tmp->ElementAt(i),
                           "JSON decoder stack member");
   }
--- a/dom/src/threads/nsDOMThreadService.cpp
+++ b/dom/src/threads/nsDOMThreadService.cpp
@@ -371,17 +371,17 @@ protected:
   // Protected by mMonitor
   nsDeque mRunnables;
 };
 
 /*******************************************************************************
  * JS environment function and callbacks
  */
 
-JSBool JS_DLL_CALLBACK
+JSBool
 DOMWorkerOperationCallback(JSContext* aCx)
 {
   nsDOMWorkerThread* worker = (nsDOMWorkerThread*)JS_GetContextPrivate(aCx);
 
   // Want a strong ref here to make sure that the monitor we wait on won't go
   // away.
   nsRefPtr<nsDOMWorkerPool> pool;
 
@@ -447,17 +447,17 @@ DOMWorkerOperationCallback(JSContext* aC
     // Start the counter over.
     worker->mCallbackCount = 0;
   }
 
   // Continue execution.
   return JS_TRUE;
 }
 
-void JS_DLL_CALLBACK
+void
 DOMWorkerErrorReporter(JSContext* aCx,
                        const char* aMessage,
                        JSErrorReport* aReport)
 {
   NS_ASSERTION(!NS_IsMainThread(), "Huh?!");
 
   nsDOMWorkerThread* worker = (nsDOMWorkerThread*)JS_GetContextPrivate(aCx);
 
--- a/dom/src/threads/nsDOMWorkerThread.cpp
+++ b/dom/src/threads/nsDOMWorkerThread.cpp
@@ -95,17 +95,17 @@ public:
                             jsval* aArgv, jsval* aRval);
 
 private:
   // Internal helper for SetTimeout and SetInterval.
   static JSBool MakeTimeout(JSContext* aCx, JSObject* aObj, uintN aArgc,
                             jsval* aArgv, jsval* aRval, PRBool aIsInterval);
 };
 
-JSBool JS_DLL_CALLBACK
+JSBool
 nsDOMWorkerFunctions::Dump(JSContext* aCx,
                            JSObject* /* aObj */,
                            uintN aArgc,
                            jsval* aArgv,
                            jsval* /* aRval */)
 {
   // XXX Expose this to the JS console? Only if that DOM pref is set?
 
@@ -113,31 +113,31 @@ nsDOMWorkerFunctions::Dump(JSContext* aC
   if (aArgc && (str = JS_ValueToString(aCx, aArgv[0])) && str) {
     nsDependentJSString string(str);
     fputs(NS_ConvertUTF16toUTF8(nsDependentJSString(str)).get(), stderr);
     fflush(stderr);
   }
   return JS_TRUE;
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 nsDOMWorkerFunctions::DebugDump(JSContext* aCx,
                                 JSObject* aObj,
                                 uintN aArgc,
                                 jsval* aArgv,
                                 jsval* aRval)
 {
 #ifdef DEBUG
   return nsDOMWorkerFunctions::Dump(aCx, aObj, aArgc, aArgv, aRval);
 #else
   return JS_TRUE;
 #endif
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 nsDOMWorkerFunctions::PostMessage(JSContext* aCx,
                                   JSObject* /* aObj */,
                                   uintN aArgc,
                                   jsval* aArgv,
                                   jsval* /* aRval */)
 {
   nsDOMWorkerThread* worker =
     static_cast<nsDOMWorkerThread*>(JS_GetContextPrivate(aCx));
@@ -159,17 +159,17 @@ nsDOMWorkerFunctions::PostMessage(JSCont
   else {
     rv = pool->PostMessageInternal(EmptyString(), worker);
   }
   NS_ENSURE_SUCCESS(rv, JS_FALSE);
 
   return JS_TRUE;
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 nsDOMWorkerFunctions::MakeTimeout(JSContext* aCx,
                                   JSObject* /* aObj */,
                                   uintN aArgc,
                                   jsval* aArgv,
                                   jsval* aRval,
                                   PRBool aIsInterval)
 {
   nsDOMWorkerThread* worker =
@@ -190,17 +190,17 @@ nsDOMWorkerFunctions::MakeTimeout(JSCont
   NS_ENSURE_SUCCESS(rv, JS_FALSE);
 
   timeout.forget();
 
   *aRval = INT_TO_JSVAL(id);
   return JS_TRUE;
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 nsDOMWorkerFunctions::KillTimeout(JSContext* aCx,
                                   JSObject* /* aObj */,
                                   uintN aArgc,
                                   jsval* aArgv,
                                   jsval* /* aRval */)
 {
   nsDOMWorkerThread* worker =
     static_cast<nsDOMWorkerThread*>(JS_GetContextPrivate(aCx));
--- a/extensions/jssh/nsJSSh.cpp
+++ b/extensions/jssh/nsJSSh.cpp
@@ -106,17 +106,17 @@ PRBool GetJSShGlobal(JSContext *cx, JSOb
   nsCOMPtr<nsISupports> native;
   wrapper->GetNative(getter_AddRefs(native));
   nsCOMPtr<nsIJSSh> jssh = do_QueryInterface(native);
   NS_ASSERTION(jssh, "no jssh global");
   *shell = static_cast<nsJSSh*>((nsIJSSh*)(jssh.get()));
   return PR_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 my_ErrorReporter(JSContext *cx, const char *message, JSErrorReport *report)
 {
   // xxx getting the global obj from the cx. will that give us grief?
   JSObject* obj = JS_GetGlobalObject(cx);
   nsJSSh* shell;
   if (!GetJSShGlobal(cx, obj, &shell)) return;
 
   // XXX use JSErrorReport for better info
@@ -127,17 +127,17 @@ my_ErrorReporter(JSContext *cx, const ch
       char buf[80];
       sprintf(buf, "[%d]", strlen(message));
       shell->mOutput->Write(buf, strlen(buf), &bytesWritten);
     }
     shell->mOutput->Write(message, strlen(message), &bytesWritten);
   }
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Print(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   nsJSSh* shell;
   if (!GetJSShGlobal(cx, obj, &shell)) return JS_FALSE;
 
   JSAutoRequest ar(cx);
 
   PRUint32 bytesWritten;
@@ -163,32 +163,32 @@ Print(JSContext *cx, JSObject *obj, uint
        printf("%s", JS_GetStringBytes(str)); // use cout if no output stream given.
 #ifdef DEBUG
 //        printf("%s", JS_GetStringBytes(str));
 #endif
    }
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Quit(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   nsJSSh* shell;
   if (!GetJSShGlobal(cx, obj, &shell)) return JS_FALSE;
 
   PRUint32 bytesWritten;
 
   if (shell->mOutput)
     shell->mOutput->Write(gGoodbye, strlen(gGoodbye), &bytesWritten);
   shell->mQuit = PR_TRUE;
   
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Load(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   nsJSSh* shell;
 
   JSAutoRequest ar(cx);
 
   if (!GetJSShGlobal(cx, obj, &shell)) return JS_FALSE;
 
@@ -198,28 +198,28 @@ Load(JSContext *cx, JSObject *obj, uintN
     //argv[i] = STRING_TO_JSVAL(str);
     const char *url = JS_GetStringBytes(str);
     if (!shell->LoadURL(url, rval))
       return JS_FALSE;
   }
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 FlushEventQueue(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   nsJSSh* shell;
   if (!GetJSShGlobal(cx, obj, &shell)) return JS_FALSE;
 
   NS_ProcessPendingEvents(nsnull);
            
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Suspend(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   nsJSSh* shell;
   if (!GetJSShGlobal(cx, obj, &shell)) return JS_FALSE;
 
   nsCOMPtr<nsIThread> thread = do_GetCurrentThread();
 
   PR_AtomicIncrement(&shell->mSuspendCount);
@@ -227,28 +227,28 @@ Suspend(JSContext *cx, JSObject *obj, ui
   while (shell->mSuspendCount) {
     LOG(("|"));
     NS_ProcessNextEvent(thread);
   }
            
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Resume(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   nsJSSh* shell;
   if (!GetJSShGlobal(cx, obj, &shell)) return JS_FALSE;
 
   PR_AtomicDecrement(&shell->mSuspendCount);
   
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 AddressOf(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   if (argc!=1) return JS_FALSE;
 
   JSAutoRequest ar(cx);
 
   // xxx If argv[0] is not an obj already, we'll get a transient
   // address from JS_ValueToObject. Maybe we should throw an exception
@@ -261,17 +261,17 @@ AddressOf(JSContext *cx, JSObject *obj, 
   
   char buf[80];
   sprintf(buf, "%p", arg_obj);
   JSString *str = JS_NewStringCopyZ(cx, buf);
   *rval = STRING_TO_JSVAL(str);
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 SetProtocol(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   if (argc!=1) return JS_FALSE;
   nsJSSh* shell;
   if (!GetJSShGlobal(cx, obj, &shell)) return JS_FALSE;
 
   JSAutoRequest ar(cx);
 
@@ -294,30 +294,30 @@ SetProtocol(JSContext *cx, JSObject *obj
     shell->mPrompt = NS_LITERAL_CSTRING("\n");
     shell->mProtocol = protocol;
   }
   else return JS_FALSE;
   
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 GetProtocol(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   nsJSSh* shell;
   if (!GetJSShGlobal(cx, obj, &shell)) return JS_FALSE;
 
   JSAutoRequest ar(cx);
 
   JSString *str = JS_NewStringCopyZ(cx, shell->mProtocol.get());
   *rval = STRING_TO_JSVAL(str);
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 SetContextObj(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   nsJSSh* shell;
   if (!GetJSShGlobal(cx, obj, &shell)) return JS_FALSE;
 
   JSAutoRequest ar(cx);
 
   if (argc!=1) return JS_FALSE;
@@ -333,28 +333,28 @@ SetContextObj(JSContext *cx, JSObject *o
   shell->mContextObj = arg_obj;
   
   if (shell->mContextObj != shell->mGlobal)
     JS_AddRoot(cx, &(shell->mContextObj));
   
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 DebugBreak(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   nsJSSh* shell;
   if (!GetJSShGlobal(cx, obj, &shell)) return JS_FALSE;
 
   NS_BREAK();
   
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 GetInputStream(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   nsJSSh* shell;
   if (!GetJSShGlobal(cx, obj, &shell)) return JS_FALSE;
 
   JSAutoRequest ar(cx);
 
   nsCOMPtr<nsIXPConnect> xpc = do_GetService(nsIXPConnect::GetCID());
@@ -376,17 +376,17 @@ GetInputStream(JSContext *cx, JSObject *
   wrapper->GetJSObject(&wrapper_jsobj);
   NS_ASSERTION(wrapper_jsobj, "could not get jsobject of wrapped native");
 
   *rval = OBJECT_TO_JSVAL(wrapper_jsobj);
   
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 GetOutputStream(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   nsJSSh* shell;
   if (!GetJSShGlobal(cx, obj, &shell)) return JS_FALSE;
 
   JSAutoRequest ar(cx);
 
   nsCOMPtr<nsIXPConnect> xpc = do_GetService(nsIXPConnect::GetCID());
--- a/extensions/pref/autoconfig/src/nsJSConfigTriggers.cpp
+++ b/extensions/pref/autoconfig/src/nsJSConfigTriggers.cpp
@@ -108,17 +108,17 @@ static  JSContext *autoconfig_cx = nsnul
 static  JSObject *autoconfig_glob;
 
 static JSClass global_class = {
     "autoconfig_global", 0,
     JS_PropertyStub,  JS_PropertyStub,  JS_PropertyStub,  JS_PropertyStub,
     JS_EnumerateStub, JS_ResolveStub,   JS_ConvertStub,   JS_FinalizeStub
 };
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 autoConfigErrorReporter(JSContext *cx, const char *message, 
                         JSErrorReport *report)
 {
     NS_ERROR(message);
     PR_LOG(MCD, PR_LOG_DEBUG, ("JS error in js from MCD server: %s\n", message));
 } 
 
 nsresult CentralizedAdminPrefManagerInit()
--- a/js/jsd/jsd.h
+++ b/js/jsd/jsd.h
@@ -367,17 +367,17 @@ jsd_SetErrorReporter(JSDContext*       j
                      JSD_ErrorReporter reporter,
                      void*             callerdata);
 
 extern JSBool
 jsd_GetErrorReporter(JSDContext*        jsdc,
                      JSD_ErrorReporter* reporter,
                      void**             callerdata);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 jsd_DebugErrorHook(JSContext *cx, const char *message,
                    JSErrorReport *report, void *closure);
 
 /***************************************************************************/
 /* Script functions */
 
 extern JSBool
 jsd_InitScriptManager(JSDContext *jsdc);
@@ -462,26 +462,26 @@ extern JSBool
 jsd_GetScriptHook(JSDContext* jsdc, JSD_ScriptHookProc* hook, void** callerdata);
 
 extern jsuword
 jsd_GetClosestPC(JSDContext* jsdc, JSDScript* jsdscript, uintN line);
 
 extern uintN
 jsd_GetClosestLine(JSDContext* jsdc, JSDScript* jsdscript, jsuword pc);
 
-extern void JS_DLL_CALLBACK
+extern void
 jsd_NewScriptHookProc(
                 JSContext   *cx,
                 const char  *filename,      /* URL this script loads from */
                 uintN       lineno,         /* line where this script starts */
                 JSScript    *script,
                 JSFunction  *fun,
                 void*       callerdata);
 
-extern void JS_DLL_CALLBACK
+extern void
 jsd_DestroyScriptHookProc(
                 JSContext   *cx,
                 JSScript    *script,
                 void*       callerdata);
 
 /* Script execution hook functions */
 
 extern JSBool
@@ -629,21 +629,21 @@ jsd_CallCallHook (JSDContext*      jsdc,
 
 extern JSBool
 jsd_SetThrowHook(JSDContext*           jsdc,
                  JSD_ExecutionHookProc hook,
                  void*                 callerdata);
 extern JSBool
 jsd_ClearThrowHook(JSDContext* jsdc);
 
-extern JSTrapStatus JS_DLL_CALLBACK
+extern JSTrapStatus
 jsd_DebuggerHandler(JSContext *cx, JSScript *script, jsbytecode *pc,
                     jsval *rval, void *closure);
 
-extern JSTrapStatus JS_DLL_CALLBACK
+extern JSTrapStatus
 jsd_ThrowHandler(JSContext *cx, JSScript *script, jsbytecode *pc,
                  jsval *rval, void *closure);
 
 extern JSBool
 jsd_SetFunctionHook(JSDContext*      jsdc,
                     JSD_CallHookProc hook,
                     void*            callerdata);
 
@@ -1004,34 +1004,34 @@ extern uintN
 jsd_GetPropertyFlags(JSDContext* jsdc, JSDProperty* jsdprop);
 
 extern uintN
 jsd_GetPropertyVarArgSlot(JSDContext* jsdc, JSDProperty* jsdprop);
 
 /**************************************************/
 /* Stepping Functions */
 
-extern void * JS_DLL_CALLBACK
+extern void *
 jsd_FunctionCallHook(JSContext *cx, JSStackFrame *fp, JSBool before,
                      JSBool *ok, void *closure);
 
-extern void * JS_DLL_CALLBACK
+extern void *
 jsd_TopLevelCallHook(JSContext *cx, JSStackFrame *fp, JSBool before,
                      JSBool *ok, void *closure);
 
 /**************************************************/
 /* Object Functions */
 
 extern JSBool
 jsd_InitObjectManager(JSDContext* jsdc);
 
 extern void
 jsd_DestroyObjectManager(JSDContext* jsdc);
 
-extern void JS_DLL_CALLBACK
+extern void
 jsd_ObjectHook(JSContext *cx, JSObject *obj, JSBool isNew, void *closure);
 
 extern void
 jsd_Constructing(JSDContext* jsdc, JSContext *cx, JSObject *obj,
                  JSStackFrame *fp);
 
 extern JSDObject*
 jsd_IterateObjects(JSDContext* jsdc, JSDObject** iterp);
@@ -1112,17 +1112,17 @@ jsdlw_RawToProcessedLineNumber(JSDContex
 
 extern JSBool
 jsdlw_ProcessedToRawLineNumber(JSDContext* jsdc, JSDScript* jsdscript,
                                uintN lineIn, uintN* lineOut);
 
 
 #if 0
 /* our hook proc for LiveWire app start/stop */
-extern void JS_DLL_CALLBACK
+extern void
 jsdlw_AppHookProc(LWDBGApp* app,
                   JSBool created,
                   void *callerdata);
 #endif
 
 
 #endif
 /***************************************************************************/
--- a/js/jsd/jsd_atom.c
+++ b/js/jsd/jsd_atom.c
@@ -62,37 +62,37 @@ static void
     jsd_DropAtom(jsdc, atom0);
     jsd_DropAtom(jsdc, atom1);
     jsd_DropAtom(jsdc, atom2);
     jsd_DropAtom(jsdc, atom3);
     jsd_DropAtom(jsdc, atom4);
 }        
 #endif    
 
-JS_STATIC_DLL_CALLBACK(intN)
+static intN
 _atom_smasher(JSHashEntry *he, intN i, void *arg)
 {
     JS_ASSERT(he);
     JS_ASSERT(he->value);
     JS_ASSERT(((JSDAtom*)(he->value))->str);
 
     free(((JSDAtom*)(he->value))->str);
     free(he->value);
     he->value = NULL;
     he->key   = NULL;
     return HT_ENUMERATE_NEXT;
 }
 
-JS_STATIC_DLL_CALLBACK(intN)
+static intN
 _compareAtomKeys(const void *v1, const void *v2)
 {
     return 0 == strcmp((const char*)v1, (const char*)v2);
 }        
 
-JS_STATIC_DLL_CALLBACK(intN)
+static intN
 _compareAtoms(const void *v1, const void *v2)
 {
     return 0 == strcmp(((JSDAtom*)v1)->str, ((JSDAtom*)v2)->str);
 }        
 
 
 JSBool
 jsd_CreateAtomTable(JSDContext* jsdc)
--- a/js/jsd/jsd_high.c
+++ b/js/jsd/jsd_high.c
@@ -319,17 +319,17 @@ jsd_JSDContextForJSContext(JSContext* co
             jsdc = iter;
             break;
         }
     }
     JSD_UNLOCK();
     return jsdc;
 }    
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 jsd_DebugErrorHook(JSContext *cx, const char *message,
                    JSErrorReport *report, void *closure)
 {
     JSDContext* jsdc = (JSDContext*) closure;
     JSD_ErrorReporter errorReporter;
     void*             errorReporterData;
     
     if( ! jsdc )
--- a/js/jsd/jsd_hook.c
+++ b/js/jsd/jsd_hook.c
@@ -36,17 +36,17 @@
  * ***** END LICENSE BLOCK ***** */
 
 /*
  * JavaScript Debugging support - Hook support
  */
 
 #include "jsd.h"
 
-JSTrapStatus JS_DLL_CALLBACK
+JSTrapStatus
 jsd_InterruptHandler(JSContext *cx, JSScript *script, jsbytecode *pc, jsval *rval,
                      void *closure)
 {
     JSDScript*      jsdscript;
     JSDContext*     jsdc = (JSDContext*) closure;
     JSD_ExecutionHookProc hook;
     void*                 hookData;
 
@@ -75,17 +75,17 @@ jsd_InterruptHandler(JSContext *cx, JSSc
     if( ! jsdlw_UserCodeAtPC(jsdc, jsdscript, (jsuword)pc) )
         return JSTRAP_CONTINUE;
 #endif
 
     return jsd_CallExecutionHook(jsdc, cx, JSD_HOOK_INTERRUPTED,
                                  hook, hookData, rval);
 }
 
-JSTrapStatus JS_DLL_CALLBACK
+JSTrapStatus
 jsd_DebuggerHandler(JSContext *cx, JSScript *script, jsbytecode *pc,
                     jsval *rval, void *closure)
 {
     JSDScript*      jsdscript;
     JSDContext*     jsdc = (JSDContext*) closure;
     JSD_ExecutionHookProc hook;
     void*                 hookData;
 
@@ -109,17 +109,17 @@ jsd_DebuggerHandler(JSContext *cx, JSScr
     if( ! jsdscript )
         return JSTRAP_CONTINUE;
 
     return jsd_CallExecutionHook(jsdc, cx, JSD_HOOK_DEBUGGER_KEYWORD,
                                  hook, hookData, rval);
 }
 
 
-JSTrapStatus JS_DLL_CALLBACK
+JSTrapStatus
 jsd_ThrowHandler(JSContext *cx, JSScript *script, jsbytecode *pc,
                  jsval *rval, void *closure)
 {
     JSDScript*      jsdscript;
     JSDContext*     jsdc = (JSDContext*) closure;
     JSD_ExecutionHookProc hook;
     void*                 hookData;
 
--- a/js/jsd/jsd_obj.c
+++ b/js/jsd/jsd_obj.c
@@ -151,17 +151,17 @@ static JSDObject*
 
                 break;
             }
         }
     }
     return jsdobj;
 }
 
-void JS_DLL_CALLBACK
+void
 jsd_ObjectHook(JSContext *cx, JSObject *obj, JSBool isNew, void *closure)
 {
     JSDObject* jsdobj;
     JSDContext* jsdc = (JSDContext*) closure;
 
     if( ! jsdc || ! jsdc->inited )
         return;
 
@@ -215,17 +215,17 @@ jsd_Constructing(JSDContext* jsdc, JSCon
             }
             jsdobj->ctorLineno = JS_GetScriptBaseLineNumber(cx, script);
         }
     }
     TRACEOBJ(jsdc, jsdobj, 3);
     JSD_UNLOCK_OBJECTS(jsdc);
 }
 
-JS_STATIC_DLL_CALLBACK(JSHashNumber)
+static JSHashNumber
 _hash_root(const void *key)
 {
     return ((JSHashNumber) key) >> 2; /* help lame MSVC1.5 on Win16 */
 }
 
 JSBool
 jsd_InitObjectManager(JSDContext* jsdc)
 {
--- a/js/jsd/jsd_scpt.c
+++ b/js/jsd/jsd_scpt.c
@@ -211,41 +211,41 @@ static void
     
     OutputDebugString( "*** JSDScriptDump\n" );
     while( NULL != (jsdscript = jsd_IterateScripts(jsdc, &iterp)) )
         _dumpJSDScript( jsdc, jsdscript, "  script: " );
 }
 #endif /* JSD_DUMP */
 
 /***************************************************************************/
-JS_STATIC_DLL_CALLBACK(JSHashNumber)
+static JSHashNumber
 jsd_hash_script(const void *key)
 {
     return ((JSHashNumber) key) >> 2; /* help lame MSVC1.5 on Win16 */
 }
 
-JS_STATIC_DLL_CALLBACK(void *)
+static void *
 jsd_alloc_script_table(void *priv, size_t size)
 {
     return malloc(size);
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 jsd_free_script_table(void *priv, void *item)
 {
     free(item);
 }
 
-JS_STATIC_DLL_CALLBACK(JSHashEntry *)
+static JSHashEntry *
 jsd_alloc_script_entry(void *priv, const void *item)
 {
     return (JSHashEntry*) malloc(sizeof(JSHashEntry));
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 jsd_free_script_entry(void *priv, JSHashEntry *he, uintN flag)
 {
     if (flag == HT_FREE_ENTRY)
     {
         _destroyJSDScript((JSDContext*) priv, (JSDScript*) he->value);
         free(he);
     }
 }
@@ -539,17 +539,17 @@ jsd_GetScriptHook(JSDContext* jsdc, JSD_
     if( callerdata )
         *callerdata = jsdc->scriptHookData;
     JSD_UNLOCK();
     return JS_TRUE;
 }    
 
 /***************************************************************************/
 
-void JS_DLL_CALLBACK
+void
 jsd_NewScriptHookProc( 
                 JSContext   *cx,
                 const char  *filename,      /* URL this script loads from */
                 uintN       lineno,         /* line where this script starts */
                 JSScript    *script,
                 JSFunction  *fun,                
                 void*       callerdata )
 {
@@ -586,17 +586,17 @@ jsd_NewScriptHookProc(
     hook = jsdc->scriptHook;
     hookData = jsdc->scriptHookData;
     JSD_UNLOCK();
 
     if( hook )
         hook(jsdc, jsdscript, JS_TRUE, hookData);
 }                
 
-void JS_DLL_CALLBACK
+void
 jsd_DestroyScriptHookProc( 
                 JSContext   *cx,
                 JSScript    *script,
                 void*       callerdata )
 {
     JSDScript* jsdscript = NULL;
     JSDContext* jsdc = (JSDContext*) callerdata;
     JSD_ScriptHookProc      hook;
@@ -686,17 +686,17 @@ static JSBool
             return JS_TRUE;
         }
     }
     JSD_UNLOCK_SCRIPTS(jsdc);
     return JS_FALSE;
 }
 
 
-JSTrapStatus JS_DLL_CALLBACK
+JSTrapStatus
 jsd_TrapHandler(JSContext *cx, JSScript *script, jsbytecode *pc, jsval *rval,
                 void *closure)
 {
     JSDExecHook* jsdhook = (JSDExecHook*) JSVAL_TO_PRIVATE(((jsval)closure));
     JSD_ExecutionHookProc hook;
     void* hookData;
     JSDContext*  jsdc;
     JSDScript* jsdscript;
--- a/js/jsd/jsd_step.c
+++ b/js/jsd/jsd_step.c
@@ -261,17 +261,17 @@ JSBool
     _interpreterTrace(jsdc, cx, fp, before);
     return JS_TRUE;
 #else
     return hookresult;
 #endif
 
 }
 
-void * JS_DLL_CALLBACK
+void *
 jsd_FunctionCallHook(JSContext *cx, JSStackFrame *fp, JSBool before,
                      JSBool *ok, void *closure)
 {
     JSDContext*       jsdc;
     JSD_CallHookProc  hook;
     void*             hookData;
 
     jsdc = (JSDContext*) closure;
@@ -287,17 +287,17 @@ jsd_FunctionCallHook(JSContext *cx, JSSt
                    hook, hookData))
     {
         return closure;
     }
     
     return NULL;
 }
 
-void * JS_DLL_CALLBACK
+void *
 jsd_TopLevelCallHook(JSContext *cx, JSStackFrame *fp, JSBool before,
                      JSBool *ok, void *closure)
 {
     JSDContext*       jsdc;
     JSD_CallHookProc  hook;
     void*             hookData;
 
     jsdc = (JSDContext*) closure;
--- a/js/jsd/jsd_xpc.cpp
+++ b/js/jsd/jsd_xpc.cpp
@@ -103,17 +103,17 @@
 #define NS_CATMAN_CTRID   "@mozilla.org/categorymanager;1"
 #define NS_JSRT_CTRID     "@mozilla.org/js/xpc/RuntimeService;1"
 
 #define AUTOREG_CATEGORY  "xpcom-autoregistration"
 #define APPSTART_CATEGORY "app-startup"
 #define JSD_AUTOREG_ENTRY "JSDebugger Startup Observer"
 #define JSD_STARTUP_ENTRY "JSDebugger Startup Observer"
 
-JS_STATIC_DLL_CALLBACK (JSBool)
+static JSBool
 jsds_GCCallbackProc (JSContext *cx, JSGCStatus status);
 
 /*******************************************************************************
  * global vars
  ******************************************************************************/
 
 const char implementationString[] = "Mozilla JavaScript Debugger Service";
 
@@ -456,17 +456,17 @@ jsds_FilterHook (JSDContext *jsdc, JSDTh
     return PR_TRUE;
     
 }
 
 /*******************************************************************************
  * c callbacks
  *******************************************************************************/
 
-JS_STATIC_DLL_CALLBACK (void)
+static void
 jsds_NotifyPendingDeadScripts (JSContext *cx)
 {
 #ifdef CAUTIOUS_SCRIPTHOOK
     JSRuntime *rt = JS_GetRuntime(cx);
 #endif
     jsdService *jsds = gJsds;
 
     nsCOMPtr<jsdIScriptHook> hook;
@@ -508,17 +508,17 @@ jsds_NotifyPendingDeadScripts (JSContext
     }
 
     if (jsds) {
         jsds->UnPause(nsnull);
         NS_RELEASE(jsds);
     }
 }
 
-JS_STATIC_DLL_CALLBACK (JSBool)
+static JSBool
 jsds_GCCallbackProc (JSContext *cx, JSGCStatus status)
 {
 #ifdef DEBUG_verbose
     printf ("new gc status is %i\n", status);
 #endif
     if (status == JSGC_END) {
         /* just to guard against reentering. */
         gGCStatus = JSGC_BEGIN;
@@ -528,17 +528,17 @@ jsds_GCCallbackProc (JSContext *cx, JSGC
 
     gGCStatus = status;
     if (gLastGCProc)
         return gLastGCProc (cx, status);
     
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK (uintN)
+static uintN
 jsds_ErrorHookProc (JSDContext *jsdc, JSContext *cx, const char *message,
                     JSErrorReport *report, void *callerdata)
 {
     static PRBool running = PR_FALSE;
 
     nsCOMPtr<jsdIErrorHook> hook;
     gJsds->GetErrorHook(getter_AddRefs(hook));
     if (!hook)
@@ -585,17 +585,17 @@ jsds_ErrorHookProc (JSDContext *jsdc, JS
     
     running = PR_FALSE;
     if (!rval)
         return JSD_ERROR_REPORTER_DEBUG;
     
     return JSD_ERROR_REPORTER_PASS_ALONG;
 }
 
-JS_STATIC_DLL_CALLBACK (JSBool)
+static JSBool
 jsds_CallHookProc (JSDContext* jsdc, JSDThreadState* jsdthreadstate,
                    uintN type, void* callerdata)
 {
     nsCOMPtr<jsdICallHook> hook;
 
     switch (type)
     {
         case JSD_HOOK_TOPLEVEL_START:
@@ -625,17 +625,17 @@ jsds_CallHookProc (JSDContext* jsdc, JSD
     gJsds->Pause(nsnull);
     hook->OnCall(frame, type);    
     gJsds->UnPause(nsnull);
     jsdStackFrame::InvalidateAll();
 
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK (PRUint32)
+static PRUint32
 jsds_ExecutionHookProc (JSDContext* jsdc, JSDThreadState* jsdthreadstate,
                         uintN type, void* callerdata, jsval* rval)
 {
     nsCOMPtr<jsdIExecutionHook> hook(0);
     PRUint32 hook_rv = JSD_HOOK_RETURN_CONTINUE;
     nsCOMPtr<jsdIValue> js_rv;
 
     switch (type)
@@ -701,17 +701,17 @@ jsds_ExecutionHookProc (JSDContext* jsdc
             if (NS_SUCCEEDED(js_rv->GetJSDValue (&jsdv)))
                 *rval = JSD_GetValueWrappedJSVal(jsdc, jsdv);
         }
     }
     
     return hook_rv;
 }
 
-JS_STATIC_DLL_CALLBACK (void)
+static void
 jsds_ScriptHookProc (JSDContext* jsdc, JSDScript* jsdscript, JSBool creating,
                      void* callerdata)
 {
 #ifdef CAUTIOUS_SCRIPTHOOK
     JSContext *cx = JSD_GetDefaultJSContext(jsdc);
     JSRuntime *rt = JS_GetRuntime(cx);
 #endif
 
--- a/js/jsd/jsdebug.h
+++ b/js/jsd/jsdebug.h
@@ -103,17 +103,17 @@ typedef struct JSDObject         JSDObje
 
 /*
 * This callback allows JSD to inform the embedding when JSD has been
 * turned on or off. This is especially useful in the Java-based debugging
 * system used in mozilla because the debugger applet controls starting
 * up the JSD system.
 */
 typedef void
-(* JS_DLL_CALLBACK JSD_SetContextProc)(JSDContext* jsdc, void* user);
+(* JSD_SetContextProc)(JSDContext* jsdc, void* user);
 
 /* This struct could have more fields in future versions */
 typedef struct
 {
     uintN              size;       /* size of this struct (init before use)*/
     JSD_SetContextProc setContext;
 } JSD_UserCallbacks;
 
@@ -429,20 +429,20 @@ JSD_GetScriptLineExtent(JSDContext* jsdc
 
 /*
 * Declaration of callback for notification of script creation and destruction.
 * 'creating' is JS_TRUE if creating new script, JS_FALSE if destroying existing
 * script (callback called just before actual destruction).
 * 'callerdata' is what was passed to JSD_SetScriptHook to set the hook.
 */
 typedef void
-(* JS_DLL_CALLBACK JSD_ScriptHookProc)(JSDContext* jsdc,
-                                       JSDScript*  jsdscript,
-                                       JSBool      creating,
-                                       void*       callerdata);
+(* JSD_ScriptHookProc)(JSDContext* jsdc,
+                       JSDScript*  jsdscript,
+                       JSBool      creating,
+                       void*       callerdata);
 
 /*
 * Set a hook to be called when scripts are created or destroyed (loaded or
 * unloaded).
 * 'callerdata' can be whatever you want it to be.
 */
 extern JSD_PUBLIC_API(JSBool)
 JSD_SetScriptHook(JSDContext* jsdc, JSD_ScriptHookProc hook, void* callerdata);
@@ -708,39 +708,39 @@ JSD_AddFullSourceText(JSDContext* jsdc,
 #define JSD_HOOK_RETURN_RET_WITH_VAL    3
 #define JSD_HOOK_RETURN_THROW_WITH_VAL  4
 #define JSD_HOOK_RETURN_CONTINUE_THROW  5
 
 /*
 * Implement a callback of this form in order to hook execution.
 */
 typedef uintN
-(* JS_DLL_CALLBACK JSD_ExecutionHookProc)(JSDContext*     jsdc,
-                                          JSDThreadState* jsdthreadstate,
-                                          uintN           type,
-                                          void*           callerdata,
-                                          jsval*          rval);
+(* JSD_ExecutionHookProc)(JSDContext*     jsdc,
+                          JSDThreadState* jsdthreadstate,
+                          uintN           type,
+                          void*           callerdata,
+                          jsval*          rval);
 
 /* possible 'type' params for JSD_CallHookProc */
 #define JSD_HOOK_TOPLEVEL_START  0   /* about to evaluate top level script */
 #define JSD_HOOK_TOPLEVEL_END    1   /* done evaluting top level script    */
 #define JSD_HOOK_FUNCTION_CALL   2   /* about to call a function           */
 #define JSD_HOOK_FUNCTION_RETURN 3   /* done calling function              */
 
 /*
 * Implement a callback of this form in order to hook function call/returns.
 * Return JS_TRUE from a TOPLEVEL_START or FUNCTION_CALL type call hook if you
 * want to hear about the TOPLEVEL_END or FUNCTION_RETURN too.  Return value is
 * ignored to TOPLEVEL_END and FUNCTION_RETURN type hooks.
 */
 typedef JSBool
-(* JS_DLL_CALLBACK JSD_CallHookProc)(JSDContext*     jsdc,
-                                     JSDThreadState* jsdthreadstate,
-                                     uintN           type,
-                                     void*           callerdata);
+(* JSD_CallHookProc)(JSDContext*     jsdc,
+                     JSDThreadState* jsdthreadstate,
+                     uintN           type,
+                     void*           callerdata);
 
 /*
 * Set Hook to be called whenever the given pc is about to be executed --
 * i.e. for 'trap' or 'breakpoint'
 */
 extern JSD_PUBLIC_API(JSBool)
 JSD_SetExecutionHook(JSDContext*           jsdc,
                      JSDScript*            jsdscript,
@@ -1045,21 +1045,21 @@ JSD_SetException(JSDContext* jsdc, JSDTh
 #define JSD_ERROR_REPORTER_RETURN       1 /* don't pass to error reporter */
 #define JSD_ERROR_REPORTER_DEBUG        2 /* force call to DebugBreakHook */
 #define JSD_ERROR_REPORTER_CLEAR_RETURN 3 /* clear exception and don't pass */
 
 /*
 * Implement a callback of this form in order to hook the ErrorReporter
 */
 typedef uintN
-(* JS_DLL_CALLBACK JSD_ErrorReporter)(JSDContext*     jsdc,
-                                      JSContext*      cx,
-                                      const char*     message,
-                                      JSErrorReport*  report,
-                                      void*           callerdata);
+(* JSD_ErrorReporter)(JSDContext*     jsdc,
+                      JSContext*      cx,
+                      const char*     message,
+                      JSErrorReport*  report,
+                      void*           callerdata);
 
 /* Set ErrorReporter hook */
 extern JSD_PUBLIC_API(JSBool)
 JSD_SetErrorReporter(JSDContext*       jsdc,
                      JSD_ErrorReporter reporter,
                      void*             callerdata);
 
 /* Get Current ErrorReporter hook */
--- a/js/src/js.cpp
+++ b/js/src/js.cpp
@@ -2116,17 +2116,17 @@ static JSObject *
 split_create_outer(JSContext *cx);
 
 static JSObject *
 split_create_inner(JSContext *cx, JSObject *outer);
 
 static ComplexObject *
 split_get_private(JSContext *cx, JSObject *obj);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 split_addProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
     ComplexObject *cpx;
     jsid asId;
 
     cpx = split_get_private(cx, obj);
     if (!cpx)
         return JS_TRUE;
@@ -2135,17 +2135,17 @@ split_addProperty(JSContext *cx, JSObjec
         if (!JS_ValueToId(cx, *vp, &asId))
             return JS_FALSE;
         return OBJ_DEFINE_PROPERTY(cx, cpx->inner, asId, *vp, NULL, NULL,
                                    JSPROP_ENUMERATE, NULL);
     }
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 split_getProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
     ComplexObject *cpx;
 
     cpx = split_get_private(cx, obj);
     if (!cpx)
         return JS_TRUE;
     if (!cpx->isInner && cpx->inner) {
@@ -2159,17 +2159,17 @@ split_getProperty(JSContext *cx, JSObjec
         if (JSVAL_IS_INT(id))
             return JS_GetElement(cx, cpx->inner, JSVAL_TO_INT(id), vp);
         return JS_TRUE;
     }
 
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 split_setProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
     ComplexObject *cpx;
 
     cpx = split_get_private(cx, obj);
     if (!cpx)
         return JS_TRUE;
     if (!cpx->isInner && cpx->inner) {
@@ -2183,17 +2183,17 @@ split_setProperty(JSContext *cx, JSObjec
         if (JSVAL_IS_INT(id))
             return JS_SetElement(cx, cpx->inner, JSVAL_TO_INT(id), vp);
         return JS_TRUE;
     }
 
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 split_delProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
     ComplexObject *cpx;
     jsid asId;
 
     cpx = split_get_private(cx, obj);
     if (!cpx)
         return JS_TRUE;
@@ -2201,17 +2201,17 @@ split_delProperty(JSContext *cx, JSObjec
         /* Make sure to define this property on the inner object. */
         if (!JS_ValueToId(cx, *vp, &asId))
             return JS_FALSE;
         return OBJ_DELETE_PROPERTY(cx, cpx->inner, asId, vp);
     }
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 split_enumerate(JSContext *cx, JSObject *obj, JSIterateOp enum_op,
                   jsval *statep, jsid *idp)
 {
     ComplexObject *cpx;
     JSObject *iterator;
 
     switch (enum_op) {
       case JSENUMERATE_INIT:
@@ -2242,17 +2242,17 @@ split_enumerate(JSContext *cx, JSObject 
         /* Let GC at our iterator object. */
         *statep = JSVAL_NULL;
         break;
     }
 
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 split_resolve(JSContext *cx, JSObject *obj, jsval id, uintN flags,
                 JSObject **objp)
 {
     ComplexObject *cpx;
 
     cpx = split_get_private(cx, obj);
     if (!cpx)
         return JS_TRUE;
@@ -2284,47 +2284,47 @@ split_resolve(JSContext *cx, JSObject *o
         }
     }
 #endif
 
     /* XXX For additional realism, let's resolve some random property here. */
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 split_finalize(JSContext *cx, JSObject *obj)
 {
     JS_free(cx, JS_GetPrivate(cx, obj));
 }
 
-JS_STATIC_DLL_CALLBACK(uint32)
+static uint32
 split_mark(JSContext *cx, JSObject *obj, void *arg)
 {
     ComplexObject *cpx;
 
     cpx = (ComplexObject *) JS_GetPrivate(cx, obj);
 
     if (!cpx->isInner && cpx->inner) {
         /* Mark the inner object. */
         JS_MarkGCThing(cx, cpx->inner, "ComplexObject.inner", arg);
     }
 
     return 0;
 }
 
-JS_STATIC_DLL_CALLBACK(JSObject *)
+static JSObject *
 split_outerObject(JSContext *cx, JSObject *obj)
 {
     ComplexObject *cpx;
 
     cpx = (ComplexObject *) JS_GetPrivate(cx, obj);
     return cpx->isInner ? cpx->outer : obj;
 }
 
-JS_STATIC_DLL_CALLBACK(JSObject *)
+static JSObject *
 split_innerObject(JSContext *cx, JSObject *obj)
 {
     ComplexObject *cpx;
 
     cpx = (ComplexObject *) JS_GetPrivate(cx, obj);
     if (cpx->frozen) {
         JS_ASSERT(!cpx->isInner);
         return obj;
--- a/js/src/jsapi.cpp
+++ b/js/src/jsapi.cpp
@@ -4306,17 +4306,17 @@ JS_GetFunctionArity(JSFunction *fun)
 
 JS_PUBLIC_API(JSBool)
 JS_ObjectIsFunction(JSContext *cx, JSObject *obj)
 {
     return OBJ_GET_CLASS(cx, obj) == &js_FunctionClass;
 }
 
 JS_BEGIN_EXTERN_C
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 js_generic_fast_native_method_dispatcher(JSContext *cx, uintN argc, jsval *vp)
 {
     jsval fsv;
     JSFunctionSpec *fs;
     JSObject *tmp;
 
     if (!JS_GetReservedSlot(cx, JSVAL_TO_OBJECT(*vp), 0, &fsv))
         return JS_FALSE;
@@ -4359,17 +4359,17 @@ js_generic_fast_native_method_dispatcher
      * object.
      */
     if (argc != 0)
         --argc;
 
     return ((JSFastNative) fs->call)(cx, argc, vp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 js_generic_native_method_dispatcher(JSContext *cx, JSObject *obj,
                                     uintN argc, jsval *argv, jsval *rval)
 {
     jsval fsv;
     JSFunctionSpec *fs;
     JSObject *tmp;
 
     if (!JS_GetReservedSlot(cx, JSVAL_TO_OBJECT(argv[-2]), 0, &fsv))
--- a/js/src/jsapi.h
+++ b/js/src/jsapi.h
@@ -886,17 +886,17 @@ JS_DumpNamedRoots(JSRuntime *rt,
  *
  * JS_MapGCRoots returns the count of roots that were successfully mapped.
  */
 #define JS_MAP_GCROOT_NEXT      0       /* continue mapping entries */
 #define JS_MAP_GCROOT_STOP      1       /* stop mapping entries */
 #define JS_MAP_GCROOT_REMOVE    2       /* remove and free the current entry */
 
 typedef intN
-(* JS_DLL_CALLBACK JSGCRootMapFun)(void *rp, const char *name, void *data);
+(* JSGCRootMapFun)(void *rp, const char *name, void *data);
 
 extern JS_PUBLIC_API(uint32)
 JS_MapGCRoots(JSRuntime *rt, JSGCRootMapFun map, void *data);
 
 extern JS_PUBLIC_API(JSBool)
 JS_LockGCThing(JSContext *cx, void *thing);
 
 extern JS_PUBLIC_API(JSBool)
@@ -1804,24 +1804,24 @@ JS_SetReservedSlot(JSContext *cx, JSObje
 
 /*
  * Security protocol.
  */
 struct JSPrincipals {
     char *codebase;
 
     /* XXX unspecified and unused by Mozilla code -- can we remove these? */
-    void * (* JS_DLL_CALLBACK getPrincipalArray)(JSContext *cx, JSPrincipals *);
-    JSBool (* JS_DLL_CALLBACK globalPrivilegesEnabled)(JSContext *cx, JSPrincipals *);
+    void * (* getPrincipalArray)(JSContext *cx, JSPrincipals *);
+    JSBool (* globalPrivilegesEnabled)(JSContext *cx, JSPrincipals *);
 
     /* Don't call "destroy"; use reference counting macros below. */
     jsrefcount refcount;
 
-    void   (* JS_DLL_CALLBACK destroy)(JSContext *cx, JSPrincipals *);
-    JSBool (* JS_DLL_CALLBACK subsume)(JSPrincipals *, JSPrincipals *);
+    void   (* destroy)(JSContext *cx, JSPrincipals *);
+    JSBool (* subsume)(JSPrincipals *, JSPrincipals *);
 };
 
 #ifdef JS_THREADSAFE
 #define JSPRINCIPALS_HOLD(cx, principals)   JS_HoldPrincipals(cx,principals)
 #define JSPRINCIPALS_DROP(cx, principals)   JS_DropPrincipals(cx,principals)
 
 extern JS_PUBLIC_API(jsrefcount)
 JS_HoldPrincipals(JSContext *cx, JSPrincipals *principals);
--- a/js/src/jsatom.cpp
+++ b/js/src/jsatom.cpp
@@ -236,26 +236,26 @@ JS_STATIC_ASSERT(ATOM_ENTRY_FLAG_MASK < 
     ((uintN)((entry)->keyAndFlags & ATOM_ENTRY_FLAG_MASK))
 #define INIT_ATOM_ENTRY(entry, key)                                           \
     ((void)((entry)->keyAndFlags = (jsuword)(key)))
 #define ADD_ATOM_ENTRY_FLAGS(entry, flags)                                    \
     ((void)((entry)->keyAndFlags |= (jsuword)(flags)))
 #define CLEAR_ATOM_ENTRY_FLAGS(entry, flags)                                  \
     ((void)((entry)->keyAndFlags &= ~(jsuword)(flags)))
 
-JS_STATIC_DLL_CALLBACK(JSDHashNumber)
+static JSDHashNumber
 HashDouble(JSDHashTable *table, const void *key);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 MatchDouble(JSDHashTable *table, const JSDHashEntryHdr *hdr, const void *key);
 
-JS_STATIC_DLL_CALLBACK(JSDHashNumber)
+static JSDHashNumber
 HashString(JSDHashTable *table, const void *key);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 MatchString(JSDHashTable *table, const JSDHashEntryHdr *hdr, const void *key);
 
 static const JSDHashTableOps DoubleHashOps = {
     JS_DHashAllocTable,
     JS_DHashFreeTable,
     HashDouble,
     MatchDouble,
     JS_DHashMoveEntryStub,
@@ -275,34 +275,34 @@ static const JSDHashTableOps StringHashO
     NULL
 };
 
 #define IS_DOUBLE_TABLE(table)      ((table)->ops == &DoubleHashOps)
 #define IS_STRING_TABLE(table)      ((table)->ops == &StringHashOps)
 
 #define IS_INITIALIZED_STATE(state) IS_DOUBLE_TABLE(&(state)->doubleAtoms)
 
-JS_STATIC_DLL_CALLBACK(JSDHashNumber)
+static JSDHashNumber
 HashDouble(JSDHashTable *table, const void *key)
 {
     jsdouble d;
 
     JS_ASSERT(IS_DOUBLE_TABLE(table));
     d = *(jsdouble *)key;
     return JSDOUBLE_HI32(d) ^ JSDOUBLE_LO32(d);
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashNumber)
+static JSDHashNumber
 HashString(JSDHashTable *table, const void *key)
 {
     JS_ASSERT(IS_STRING_TABLE(table));
     return js_HashString((JSString *)key);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 MatchDouble(JSDHashTable *table, const JSDHashEntryHdr *hdr, const void *key)
 {
     JSAtomHashEntry *entry = TO_ATOM_ENTRY(hdr);
     jsdouble d1, d2;
 
     JS_ASSERT(IS_DOUBLE_TABLE(table));
     if (entry->keyAndFlags == 0) {
         /* See comments in MatchString. */
@@ -316,17 +316,17 @@ MatchDouble(JSDHashTable *table, const J
 #if defined(XP_WIN)
     /* XXX MSVC miscompiles such that (NaN == 0) */
     if (JSDOUBLE_IS_NaN(d2))
         return JS_FALSE;
 #endif
     return d1 == d2;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 MatchString(JSDHashTable *table, const JSDHashEntryHdr *hdr, const void *key)
 {
     JSAtomHashEntry *entry = TO_ATOM_ENTRY(hdr);
 
     JS_ASSERT(IS_STRING_TABLE(table));
     if (entry->keyAndFlags == 0) {
         /*
          * This happens when js_AtomizeString adds a new hash entry and
@@ -385,17 +385,17 @@ js_InitAtomState(JSRuntime *rt)
 
 #ifdef JS_THREADSAFE
     js_InitLock(&state->lock);
 #endif
     JS_ASSERT(IS_INITIALIZED_STATE(state));
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 js_string_uninterner(JSDHashTable *table, JSDHashEntryHdr *hdr,
                      uint32 number, void *arg)
 {
     JSAtomHashEntry *entry = TO_ATOM_ENTRY(hdr);
     JSRuntime *rt = (JSRuntime *)arg;
     JSString *str;
 
     /*
@@ -451,17 +451,17 @@ js_InitCommonAtoms(JSContext *cx)
             return JS_FALSE;
     }
     JS_ASSERT((uint8 *)atoms - (uint8 *)state == LAZY_ATOM_OFFSET_START);
     memset(atoms, 0, ATOM_OFFSET_LIMIT - LAZY_ATOM_OFFSET_START);
 
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 js_atom_unpinner(JSDHashTable *table, JSDHashEntryHdr *hdr,
                  uint32 number, void *arg)
 {
     JS_ASSERT(IS_STRING_TABLE(table));
     CLEAR_ATOM_ENTRY_FLAGS(TO_ATOM_ENTRY(hdr), ATOM_PINNED);
     return JS_DHASH_NEXT;
 }
 
@@ -472,34 +472,34 @@ js_FinishCommonAtoms(JSContext *cx)
 
     JS_DHashTableEnumerate(&state->stringAtoms, js_atom_unpinner, NULL);
 #ifdef DEBUG
     memset(COMMON_ATOMS_START(state), JS_FREE_PATTERN,
            ATOM_OFFSET_LIMIT - ATOM_OFFSET_START);
 #endif
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 js_locked_atom_tracer(JSDHashTable *table, JSDHashEntryHdr *hdr,
                       uint32 number, void *arg)
 {
     JSAtomHashEntry *entry = TO_ATOM_ENTRY(hdr);
     JSTracer *trc = (JSTracer *)arg;
 
     if (entry->keyAndFlags == 0) {
         /* Ignore uninitialized entries during tracing. */
         return JS_DHASH_NEXT;
     }
     JS_SET_TRACING_INDEX(trc, "locked_atom", (size_t)number);
     JS_CallTracer(trc, ATOM_ENTRY_KEY(entry),
                   IS_STRING_TABLE(table) ? JSTRACE_STRING : JSTRACE_DOUBLE);
     return JS_DHASH_NEXT;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 js_pinned_atom_tracer(JSDHashTable *table, JSDHashEntryHdr *hdr,
                         uint32 number, void *arg)
 {
     JSAtomHashEntry *entry = TO_ATOM_ENTRY(hdr);
     JSTracer *trc = (JSTracer *)arg;
     uintN flags = ATOM_ENTRY_FLAGS(entry);
 
     JS_ASSERT(IS_STRING_TABLE(table));
@@ -523,17 +523,17 @@ js_TraceAtomState(JSTracer *trc, JSBool 
     if (allAtoms) {
         JS_DHashTableEnumerate(&state->doubleAtoms, js_locked_atom_tracer, trc);
         JS_DHashTableEnumerate(&state->stringAtoms, js_locked_atom_tracer, trc);
     } else {
         JS_DHashTableEnumerate(&state->stringAtoms, js_pinned_atom_tracer, trc);
     }
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 js_atom_sweeper(JSDHashTable *table, JSDHashEntryHdr *hdr,
                 uint32 number, void *arg)
 {
     JSAtomHashEntry *entry = TO_ATOM_ENTRY(hdr);
     JSContext *cx = (JSContext *)arg;
 
     /* Remove uninitialized entries.  */
     if (entry->keyAndFlags == 0)
@@ -827,17 +827,17 @@ js_ValueToStringId(JSContext *cx, jsval 
     if (!atom)
         return JS_FALSE;
     *idp = ATOM_TO_JSID(atom);
     return JS_TRUE;
 }
 
 #ifdef DEBUG
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 atom_dumper(JSDHashTable *table, JSDHashEntryHdr *hdr,
             uint32 number, void *arg)
 {
     JSAtomHashEntry *entry = TO_ATOM_ENTRY(hdr);
     FILE *fp = (FILE *)arg;
     void *key;
     uintN flags;
 
@@ -881,55 +881,55 @@ js_DumpAtoms(JSContext *cx, FILE *fp)
 #ifdef JS_DHASHMETER
     JS_DHashTableDumpMeter(&state->doubleAtoms, atom_dumper, fp);
 #endif
     putc('\n', fp);
 }
 
 #endif
 
-JS_STATIC_DLL_CALLBACK(JSHashNumber)
+static JSHashNumber
 js_hash_atom_ptr(const void *key)
 {
     const JSAtom *atom = (const JSAtom *) key;
     return ATOM_HASH(atom);
 }
 
-JS_STATIC_DLL_CALLBACK(void *)
+static void *
 js_alloc_temp_space(void *priv, size_t size)
 {
     JSContext *cx = (JSContext *) priv;
     void *space;
 
     JS_ARENA_ALLOCATE(space, &cx->tempPool, size);
     if (!space)
         js_ReportOutOfScriptQuota(cx);
     return space;
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 js_free_temp_space(void *priv, void *item)
 {
 }
 
-JS_STATIC_DLL_CALLBACK(JSHashEntry *)
+static JSHashEntry *
 js_alloc_temp_entry(void *priv, const void *key)
 {
     JSContext *cx = (JSContext *) priv;
     JSAtomListElement *ale;
 
     JS_ARENA_ALLOCATE_TYPE(ale, JSAtomListElement, &cx->tempPool);
     if (!ale) {
         js_ReportOutOfScriptQuota(cx);
         return NULL;
     }
     return &ale->entry;
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 js_free_temp_entry(void *priv, JSHashEntry *he, uintN flag)
 {
 }
 
 static JSHashAllocOps temp_alloc_ops = {
     js_alloc_temp_space,    js_free_temp_space,
     js_alloc_temp_entry,    js_free_temp_entry
 };
@@ -991,17 +991,17 @@ js_IndexAtom(JSContext *cx, JSAtom *atom
                 return NULL;
         }
 
         ALE_SET_INDEX(ale, al->count++);
     }
     return ale;
 }
 
-JS_STATIC_DLL_CALLBACK(intN)
+static intN
 js_map_atom(JSHashEntry *he, intN i, void *arg)
 {
     JSAtomListElement *ale = (JSAtomListElement *)he;
     JSAtom **vector = (JSAtom **) arg;
 
     vector[ALE_INDEX(ale)] = ALE_ATOM(ale);
     return HT_ENUMERATE_NEXT;
 }
--- a/js/src/jscntxt.cpp
+++ b/js/src/jscntxt.cpp
@@ -77,17 +77,17 @@
  * index value is visible and shared by all threads, but the data associated
  * with it is private to each thread.
  */
 static PRUintn threadTPIndex;
 static JSBool  tpIndexInited = JS_FALSE;
 
 JS_BEGIN_EXTERN_C
 JSBool
-js_InitThreadPrivateIndex(void (JS_DLL_CALLBACK *ptr)(void *))
+js_InitThreadPrivateIndex(void (*ptr)(void *))
 {
     PRStatus status;
 
     if (tpIndexInited)
         return JS_TRUE;
 
     status = PR_NewThreadPrivateIndex(&threadTPIndex, ptr);
 
@@ -96,17 +96,17 @@ js_InitThreadPrivateIndex(void (JS_DLL_C
     return status == PR_SUCCESS;
 }
 JS_END_EXTERN_C
 
 /*
  * Callback function to delete a JSThread info when the thread that owns it
  * is destroyed.
  */
-void JS_DLL_CALLBACK
+void
 js_ThreadDestructorCB(void *ptr)
 {
     JSThread *thread = (JSThread *)ptr;
 
     if (!thread)
         return;
 
     /*
@@ -516,17 +516,17 @@ js_ContextIterator(JSRuntime *rt, JSBool
     if (&cx->links == &rt->contextList)
         cx = NULL;
     *iterp = cx;
     if (unlocked)
         JS_UNLOCK_GC(rt);
     return cx;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashNumber)
+static JSDHashNumber
 resolving_HashKey(JSDHashTable *table, const void *ptr)
 {
     const JSResolvingKey *key = (const JSResolvingKey *)ptr;
 
     return ((JSDHashNumber)JS_PTR_TO_UINT32(key->obj) >> JSVAL_TAGBITS) ^ key->id;
 }
 
 JS_PUBLIC_API(JSBool)
--- a/js/src/jscntxt.h
+++ b/js/src/jscntxt.h
@@ -188,17 +188,17 @@ struct JSThread {
     JSScript            *scriptsToGC;
 };
 
 #define JS_GSN_CACHE(cx)        ((cx)->thread->gsnCache)
 #define JS_PROPERTY_CACHE(cx)   ((cx)->thread->propertyCache)
 #define JS_TRACE_MONITOR(cx)    ((cx)->thread->traceMonitor)
 #define JS_SCRIPTS_TO_GC(cx)    ((cx)->thread->scriptsToGC)
 
-extern void JS_DLL_CALLBACK
+extern void
 js_ThreadDestructorCB(void *ptr);
 
 extern JSBool
 js_SetContextThread(JSContext *cx);
 
 extern void
 js_ClearContextThread(JSContext *cx);
 
@@ -961,17 +961,17 @@ class JSAutoTempValueRooter
                                          JSVERSION_NUMBER(cx) >= JSVERSION_1_6)
 
 /*
  * Initialize a library-wide thread private data index, and remember that it
  * has already been done, so that it happens only once ever.  Returns true on
  * success.
  */
 extern JSBool
-js_InitThreadPrivateIndex(void (JS_DLL_CALLBACK *ptr)(void *));
+js_InitThreadPrivateIndex(void (*ptr)(void *));
 
 /*
  * Common subroutine of JS_SetVersion and js_SetVersion, to update per-context
  * data that depends on version.
  */
 extern void
 js_OnVersionChange(JSContext *cx);
 
--- a/js/src/jsdbgapi.cpp
+++ b/js/src/jsdbgapi.cpp
@@ -525,17 +525,17 @@ js_GetWatchedSetter(JSRuntime *rt, JSSco
             break;
         }
     }
     if (scope)
         DBG_UNLOCK(rt);
     return setter;
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 js_watch_set(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
     JSRuntime *rt;
     JSWatchPoint *wp;
     JSScopeProperty *sprop;
     jsval propid, userid;
     JSScope *scope;
     JSBool ok;
@@ -669,17 +669,17 @@ js_watch_set(JSContext *cx, JSObject *ob
             DBG_LOCK(rt);
             return DropWatchPointAndUnlock(cx, wp, JSWP_HELD) && ok;
         }
     }
     DBG_UNLOCK(rt);
     return JS_TRUE;
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 js_watch_set_wrapper(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                      jsval *rval)
 {
     JSObject *funobj;
     JSFunction *wrapper;
     jsval userid;
 
     funobj = JSVAL_TO_OBJECT(argv[-2]);
--- a/js/src/jsdbgapi.h
+++ b/js/src/jsdbgapi.h
@@ -115,20 +115,20 @@ js_FindWatchPoint(JSRuntime *rt, JSScope
 
 /*
  * NB: callers outside of jsdbgapi.c must pass non-null scope.
  */
 extern JSPropertyOp
 js_GetWatchedSetter(JSRuntime *rt, JSScope *scope,
                     const JSScopeProperty *sprop);
 
-extern JSBool JS_DLL_CALLBACK
+extern JSBool
 js_watch_set(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-extern JSBool JS_DLL_CALLBACK
+extern JSBool
 js_watch_set_wrapper(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                      jsval *rval);
 
 extern JSPropertyOp
 js_WrapWatchedSetter(JSContext *cx, jsid id, uintN attrs, JSPropertyOp setter);
 
 #endif /* JS_HAS_OBJ_WATCHPOINT */
 
--- a/js/src/jsdhash.h
+++ b/js/src/jsdhash.h
@@ -233,76 +233,72 @@ struct JSDHashTable {
 #define JS_DHASH_TABLE_SIZE(table)  JS_BIT(JS_DHASH_BITS - (table)->hashShift)
 
 /*
  * Table space at entryStore is allocated and freed using these callbacks.
  * The allocator should return null on error only (not if called with nbytes
  * equal to 0; but note that jsdhash.c code will never call with 0 nbytes).
  */
 typedef void *
-(* JS_DLL_CALLBACK JSDHashAllocTable)(JSDHashTable *table, uint32 nbytes);
+(* JSDHashAllocTable)(JSDHashTable *table, uint32 nbytes);
 
 typedef void
-(* JS_DLL_CALLBACK JSDHashFreeTable) (JSDHashTable *table, void *ptr);
+(* JSDHashFreeTable) (JSDHashTable *table, void *ptr);
 
 /*
  * Compute the hash code for a given key to be looked up, added, or removed
  * from table.  A hash code may have any JSDHashNumber value.
  */
 typedef JSDHashNumber
-(* JS_DLL_CALLBACK JSDHashHashKey)   (JSDHashTable *table, const void *key);
+(* JSDHashHashKey)   (JSDHashTable *table, const void *key);
 
 /*
  * Compare the key identifying entry in table with the provided key parameter.
  * Return JS_TRUE if keys match, JS_FALSE otherwise.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSDHashMatchEntry)(JSDHashTable *table,
-                                      const JSDHashEntryHdr *entry,
-                                      const void *key);
+(* JSDHashMatchEntry)(JSDHashTable *table, const JSDHashEntryHdr *entry,
+                      const void *key);
 
 /*
  * Copy the data starting at from to the new entry storage at to.  Do not add
  * reference counts for any strong references in the entry, however, as this
  * is a "move" operation: the old entry storage at from will be freed without
  * any reference-decrementing callback shortly.
  */
 typedef void
-(* JS_DLL_CALLBACK JSDHashMoveEntry)(JSDHashTable *table,
-                                     const JSDHashEntryHdr *from,
-                                     JSDHashEntryHdr *to);
+(* JSDHashMoveEntry)(JSDHashTable *table, const JSDHashEntryHdr *from,
+                     JSDHashEntryHdr *to);
 
 /*
  * Clear the entry and drop any strong references it holds.  This callback is
  * invoked during a JS_DHASH_REMOVE operation (see below for operation codes),
  * but only if the given key is found in the table.
  */
 typedef void
-(* JS_DLL_CALLBACK JSDHashClearEntry)(JSDHashTable *table,
-                                      JSDHashEntryHdr *entry);
+(* JSDHashClearEntry)(JSDHashTable *table, JSDHashEntryHdr *entry);
 
 /*
  * Called when a table (whether allocated dynamically by itself, or nested in
  * a larger structure, or allocated on the stack) is finished.  This callback
  * allows table->ops-specific code to finalize table->data.
  */
 typedef void
-(* JS_DLL_CALLBACK JSDHashFinalize)  (JSDHashTable *table);
+(* JSDHashFinalize)  (JSDHashTable *table);
 
 /*
  * Initialize a new entry, apart from keyHash.  This function is called when
  * JS_DHashTableOperate's JS_DHASH_ADD case finds no existing entry for the
  * given key, and must add a new one.  At that point, entry->keyHash is not
  * set yet, to avoid claiming the last free entry in a severely overloaded
  * table.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSDHashInitEntry)(JSDHashTable *table,
-                                     JSDHashEntryHdr *entry,
-                                     const void *key);
+(* JSDHashInitEntry)(JSDHashTable *table, JSDHashEntryHdr *entry,
+                     const void *key);
 
 /*
  * Finally, the "vtable" structure for JSDHashTable.  The first eight hooks
  * must be provided by implementations; they're called unconditionally by the
  * generic jsdhash.c code.  Hooks after these may be null.
  *
  * Summary of allocation-related hook usage with C++ placement new emphasis:
  *  allocTable          Allocate raw bytes with malloc, no ctors run.
@@ -569,18 +565,18 @@ JS_DHashTableRawRemove(JSDHashTable *tab
  * If your enumerator wants to remove certain entries, but set aside pointers
  * to other entries that it retains, it can use JS_DHashTableRawRemove on the
  * entries to be removed, returning JS_DHASH_NEXT to skip them.  Likewise, if
  * you want to remove entries, but for some reason you do not want entryStore
  * to be shrunk or compressed, you can call JS_DHashTableRawRemove safely on
  * the entry being enumerated, rather than returning JS_DHASH_REMOVE.
  */
 typedef JSDHashOperator
-(* JS_DLL_CALLBACK JSDHashEnumerator)(JSDHashTable *table, JSDHashEntryHdr *hdr,
-                                      uint32 number, void *arg);
+(* JSDHashEnumerator)(JSDHashTable *table, JSDHashEntryHdr *hdr, uint32 number,
+                      void *arg);
 
 extern JS_PUBLIC_API(uint32)
 JS_DHashTableEnumerate(JSDHashTable *table, JSDHashEnumerator etor, void *arg);
 
 #ifdef JS_DHASHMETER
 #include <stdio.h>
 
 extern JS_PUBLIC_API(void)
--- a/js/src/jsfun.cpp
+++ b/js/src/jsfun.cpp
@@ -2524,17 +2524,17 @@ typedef struct JSLocalNameEnumeratorArgs
     JSFunction      *fun;
     jsuword         *names;
 #ifdef DEBUG
     uintN           nCopiedArgs;
     uintN           nCopiedVars;
 #endif
 } JSLocalNameEnumeratorArgs;
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 get_local_names_enumerator(JSDHashTable *table, JSDHashEntryHdr *hdr,
                            uint32 number, void *arg)
 {
     JSLocalNameHashEntry *entry;
     JSLocalNameEnumeratorArgs *args;
     uint i;
     jsuword constFlag;
 
@@ -2604,17 +2604,17 @@ js_GetLocalNameArray(JSContext *cx, JSFu
 #if !JS_HAS_DESTRUCTURING
     JS_ASSERT(args.nCopiedArgs == fun->nargs);
 #endif
     JS_ASSERT(args.nCopiedVars == fun->u.i.nvars);
 
     return names;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 trace_local_names_enumerator(JSDHashTable *table, JSDHashEntryHdr *hdr,
                              uint32 number, void *arg)
 {
     JSLocalNameHashEntry *entry;
     JSTracer *trc;
 
     entry = (JSLocalNameHashEntry *) hdr;
     JS_ASSERT(entry->name);
--- a/js/src/jsgc.cpp
+++ b/js/src/jsgc.cpp
@@ -1505,17 +1505,17 @@ js_RemoveRoot(JSRuntime *rt, void *rp)
     (void) JS_DHashTableOperate(&rt->gcRootsHash, rp, JS_DHASH_REMOVE);
     rt->gcPoke = JS_TRUE;
     JS_UNLOCK_GC(rt);
     return JS_TRUE;
 }
 
 #ifdef DEBUG
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 js_root_printer(JSDHashTable *table, JSDHashEntryHdr *hdr, uint32 i, void *arg)
 {
     uint32 *leakedroots = (uint32 *)arg;
     JSGCRootHashEntry *rhe = (JSGCRootHashEntry *)hdr;
 
     (*leakedroots)++;
     fprintf(stderr,
             "JS engine warning: leaking GC root \'%s\' at %p\n",
@@ -1549,17 +1549,17 @@ CheckLeakedRoots(JSRuntime *rt)
     }
 }
 
 typedef struct NamedRootDumpArgs {
     void (*dump)(const char *name, void *rp, void *data);
     void *data;
 } NamedRootDumpArgs;
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 js_named_root_dumper(JSDHashTable *table, JSDHashEntryHdr *hdr, uint32 number,
                      void *arg)
 {
     NamedRootDumpArgs *args = (NamedRootDumpArgs *) arg;
     JSGCRootHashEntry *rhe = (JSGCRootHashEntry *)hdr;
 
     if (rhe->name)
         args->dump(rhe->name, rhe->root, args->data);
@@ -1582,17 +1582,17 @@ JS_END_EXTERN_C
 
 #endif /* DEBUG */
 
 typedef struct GCRootMapArgs {
     JSGCRootMapFun map;
     void *data;
 } GCRootMapArgs;
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 js_gcroot_mapper(JSDHashTable *table, JSDHashEntryHdr *hdr, uint32 number,
                  void *arg)
 {
     GCRootMapArgs *args = (GCRootMapArgs *) arg;
     JSGCRootHashEntry *rhe = (JSGCRootHashEntry *)hdr;
     intN mapflags;
     int op;
 
@@ -2589,17 +2589,17 @@ js_CallValueTracerIfGCThing(JSTracer *tr
         thing = JSVAL_TO_OBJECT(v);
         kind = js_GetGCThingTraceKind(thing);
     } else {
         return;
     }
     JS_CallTracer(trc, thing, kind);
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 gc_root_traversal(JSDHashTable *table, JSDHashEntryHdr *hdr, uint32 num,
                   void *arg)
 {
     JSGCRootHashEntry *rhe = (JSGCRootHashEntry *)hdr;
     JSTracer *trc = (JSTracer *)arg;
     jsval *rp = (jsval *)rhe->root;
     jsval v = *rp;
 
@@ -2648,17 +2648,17 @@ gc_root_traversal(JSDHashTable *table, J
 #endif
         JS_SET_TRACING_NAME(trc, rhe->name ? rhe->name : "root");
         js_CallValueTracerIfGCThing(trc, v);
     }
 
     return JS_DHASH_NEXT;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 gc_lock_traversal(JSDHashTable *table, JSDHashEntryHdr *hdr, uint32 num,
                   void *arg)
 {
     JSGCLockHashEntry *lhe = (JSGCLockHashEntry *)hdr;
     void *thing = (void *)lhe->thing;
     JSTracer *trc = (JSTracer *)arg;
     uint32 traceKind;
 
--- a/js/src/jshash.h
+++ b/js/src/jshash.h
@@ -51,19 +51,19 @@ JS_BEGIN_EXTERN_C
 
 typedef uint32 JSHashNumber;
 typedef struct JSHashEntry JSHashEntry;
 typedef struct JSHashTable JSHashTable;
 
 #define JS_HASH_BITS 32
 #define JS_GOLDEN_RATIO 0x9E3779B9U
 
-typedef JSHashNumber (* JS_DLL_CALLBACK JSHashFunction)(const void *key);
-typedef intN (* JS_DLL_CALLBACK JSHashComparator)(const void *v1, const void *v2);
-typedef intN (* JS_DLL_CALLBACK JSHashEnumerator)(JSHashEntry *he, intN i, void *arg);
+typedef JSHashNumber (* JSHashFunction)(const void *key);
+typedef intN (* JSHashComparator)(const void *v1, const void *v2);
+typedef intN (* JSHashEnumerator)(JSHashEntry *he, intN i, void *arg);
 
 /* Flag bits in JSHashEnumerator's return value */
 #define HT_ENUMERATE_NEXT       0       /* continue enumerating entries */
 #define HT_ENUMERATE_STOP       1       /* stop enumerating entries */
 #define HT_ENUMERATE_REMOVE     2       /* remove and free the current entry */
 
 typedef struct JSHashAllocOps {
     void *              (*allocTable)(void *pool, size_t size);
--- a/js/src/jsify.pl
+++ b/js/src/jsify.pl
@@ -413,18 +413,16 @@ sub convert_includes {
     return $line;
 }
 
 sub convert_declarations {
     ($line) = @_;
     $line =~ s/PR_EXTERN/JS_EXTERN_API/g;
     $line =~ s/PR_IMPLEMENT_DATA/JS_EXPORT_DATA/g;
     $line =~ s/PR_IMPLEMENT/JS_EXPORT_API/g;
-    $line =~ s/PR_CALLBACK/JS_DLL_CALLBACK/g;
-    $line =~ s/PR_STATIC_CALLBACK/JS_STATIC_DLL_CALLBACK/g;
     $line =~ s/PR_IMPORT/JS_IMPORT/g;
     $line =~ s/PR_PUBLIC_API/JS_EXPORT_API/g;
     $line =~ s/PR_PUBLIC_DATA/JS_EXPORT_DATA/g;
     return $line;
 }    
 
 sub convert_long_long_macros {
     ($line) = @_;
--- a/js/src/jsobj.cpp
+++ b/js/src/jsobj.cpp
@@ -322,17 +322,17 @@ js_SetProtoOrParent(JSContext *cx, JSObj
 #endif
                                  );
         }
         return JS_FALSE;
     }
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSHashNumber)
+static JSHashNumber
 js_hash_object(const void *key)
 {
     return (JSHashNumber)JS_PTR_TO_UINT32(key) >> JSVAL_TAGBITS;
 }
 
 static JSHashEntry *
 MarkSharpObjects(JSContext *cx, JSObject *obj, JSIdArray **idap)
 {
@@ -565,17 +565,17 @@ js_LeaveSharpObject(JSContext *cx, JSIdA
         ida = *idap;
         if (ida) {
             JS_DestroyIdArray(cx, ida);
             *idap = NULL;
         }
     }
 }
 
-JS_STATIC_DLL_CALLBACK(intN)
+static intN
 gc_sharp_table_entry_marker(JSHashEntry *he, intN i, void *arg)
 {
     JS_CALL_OBJECT_TRACER((JSTracer *)arg, (JSObject *)he->key,
                           "sharp table entry");
     return JS_DHASH_NEXT;
 }
 
 void
@@ -2672,17 +2672,17 @@ earlybad:
     if (JAVASCRIPT_OBJECT_CREATE_DONE_ENABLED())
         jsdtrace_object_create_done(cx->fp, clasp);
 #endif
     return NULL;
 }
 
 JS_BEGIN_EXTERN_C
 
-JS_STATIC_DLL_CALLBACK(JSObject *)
+static JSObject *
 js_InitNullClass(JSContext *cx, JSObject *obj)
 {
     JS_ASSERT(0);
     return NULL;
 }
 
 #define JS_PROTO(name,code,init) extern JSObject *init(JSContext *, JSObject *);
 #include "jsproto.tbl"
--- a/js/src/jsparse.cpp
+++ b/js/src/jsparse.cpp
@@ -1846,29 +1846,29 @@ typedef struct FindPropValEntry {
 } FindPropValEntry;
 
 #define ASSERT_VALID_PROPERTY_KEY(pnkey)                                      \
     JS_ASSERT((pnkey)->pn_arity == PN_NULLARY &&                              \
               ((pnkey)->pn_type == TOK_NUMBER ||                              \
                (pnkey)->pn_type == TOK_STRING ||                              \
                (pnkey)->pn_type == TOK_NAME))
 
-JS_STATIC_DLL_CALLBACK(JSDHashNumber)
+static JSDHashNumber
 HashFindPropValKey(JSDHashTable *table, const void *key)
 {
     const JSParseNode *pnkey = (const JSParseNode *)key;
 
     ASSERT_VALID_PROPERTY_KEY(pnkey);
     return (pnkey->pn_type == TOK_NUMBER)
            ? (JSDHashNumber) (JSDOUBLE_HI32(pnkey->pn_dval) ^
                               JSDOUBLE_LO32(pnkey->pn_dval))
            : ATOM_HASH(pnkey->pn_atom);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 MatchFindPropValEntry(JSDHashTable *table,
                       const JSDHashEntryHdr *entry,
                       const void *key)
 {
     const FindPropValEntry *fpve = (const FindPropValEntry *)entry;
     const JSParseNode *pnkey = (const JSParseNode *)key;
 
     ASSERT_VALID_PROPERTY_KEY(pnkey);
--- a/js/src/jsprvtd.h
+++ b/js/src/jsprvtd.h
@@ -133,42 +133,41 @@ typedef enum JSTrapStatus {
     JSTRAP_ERROR,
     JSTRAP_CONTINUE,
     JSTRAP_RETURN,
     JSTRAP_THROW,
     JSTRAP_LIMIT
 } JSTrapStatus;
 
 typedef JSTrapStatus
-(* JS_DLL_CALLBACK JSTrapHandler)(JSContext *cx, JSScript *script,
-                                  jsbytecode *pc, jsval *rval, void *closure);
+(* JSTrapHandler)(JSContext *cx, JSScript *script, jsbytecode *pc, jsval *rval,
+                  void *closure);
 
 typedef JSBool
-(* JS_DLL_CALLBACK JSWatchPointHandler)(JSContext *cx, JSObject *obj, jsval id,
-                                        jsval old, jsval *newp, void *closure);
+(* JSWatchPointHandler)(JSContext *cx, JSObject *obj, jsval id, jsval old,
+                        jsval *newp, void *closure);
 
 /* called just after script creation */
 typedef void
-(* JS_DLL_CALLBACK JSNewScriptHook)(JSContext  *cx,
-                                    const char *filename,  /* URL of script */
-                                    uintN      lineno,     /* first line */
-                                    JSScript   *script,
-                                    JSFunction *fun,
-                                    void       *callerdata);
+(* JSNewScriptHook)(JSContext  *cx,
+                    const char *filename,  /* URL of script */
+                    uintN      lineno,     /* first line */
+                    JSScript   *script,
+                    JSFunction *fun,
+                    void       *callerdata);
 
 /* called just before script destruction */
 typedef void
-(* JS_DLL_CALLBACK JSDestroyScriptHook)(JSContext *cx,
-                                        JSScript  *script,
-                                        void      *callerdata);
+(* JSDestroyScriptHook)(JSContext *cx,
+                        JSScript  *script,
+                        void      *callerdata);
 
 typedef void
-(* JS_DLL_CALLBACK JSSourceHandler)(const char *filename, uintN lineno,
-                                    jschar *str, size_t length,
-                                    void **listenerTSData, void *closure);
+(* JSSourceHandler)(const char *filename, uintN lineno, jschar *str,
+                    size_t length, void **listenerTSData, void *closure);
 
 /*
  * This hook captures high level script execution and function calls (JS or
  * native).  It is used by JS_SetExecuteHook to hook top level scripts and by
  * JS_SetCallHook to hook function calls.  It will get called twice per script
  * or function call: just before execution begins and just after it finishes.
  * In both cases the 'current' frame is that of the executing code.
  *
@@ -186,26 +185,25 @@ typedef void
  * invocation. Alternately, the 'before' could just return the same value as
  * in 'closure' to cause the 'after' invocation to be called with the same
  * 'closure' value as the 'before'.
  *
  * Returning NULL in the 'before' hook will cause the 'after' hook *not* to
  * be called.
  */
 typedef void *
-(* JS_DLL_CALLBACK JSInterpreterHook)(JSContext *cx, JSStackFrame *fp, JSBool before,
-                                      JSBool *ok, void *closure);
+(* JSInterpreterHook)(JSContext *cx, JSStackFrame *fp, JSBool before,
+                      JSBool *ok, void *closure);
 
 typedef void
-(* JS_DLL_CALLBACK JSObjectHook)(JSContext *cx, JSObject *obj, JSBool isNew,
-                                 void *closure);
+(* JSObjectHook)(JSContext *cx, JSObject *obj, JSBool isNew, void *closure);
 
 typedef JSBool
-(* JS_DLL_CALLBACK JSDebugErrorHook)(JSContext *cx, const char *message,
-                                     JSErrorReport *report, void *closure);
+(* JSDebugErrorHook)(JSContext *cx, const char *message, JSErrorReport *report,
+                     void *closure);
 
 typedef struct JSDebugHooks {
     JSTrapHandler       interruptHandler;
     void                *interruptHandlerData;
     JSNewScriptHook     newScriptHook;
     void                *newScriptHookData;
     JSDestroyScriptHook destroyScriptHook;
     void                *destroyScriptHookData;
@@ -225,17 +223,17 @@ typedef struct JSDebugHooks {
     void                *debugErrorHookData;
 } JSDebugHooks;
 
 /*
  * Type definitions for temporary GC roots that register with GC local C
  * variables. See jscntxt.h for details.
  */
 typedef void
-(* JS_DLL_CALLBACK JSTempValueTrace)(JSTracer *trc, JSTempValueRooter *tvr);
+(* JSTempValueTrace)(JSTracer *trc, JSTempValueRooter *tvr);
 
 typedef union JSTempValueUnion {
     jsval               value;
     JSObject            *object;
     JSString            *string;
     JSXML               *xml;
     JSTempValueTrace    trace;
     JSScopeProperty     *sprop;
--- a/js/src/jspubtd.h
+++ b/js/src/jspubtd.h
@@ -160,18 +160,17 @@ typedef struct JSSecurityCallbacks JSSec
 /*
  * Add, delete, get or set a property named by id in obj.  Note the jsval id
  * type -- id may be a string (Unicode property identifier) or an int (element
  * index).  The *vp out parameter, on success, is the new property value after
  * an add, get, or set.  After a successful delete, *vp is JSVAL_FALSE iff
  * obj[id] can't be deleted (because it's permanent).
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSPropertyOp)(JSContext *cx, JSObject *obj, jsval id,
-                                 jsval *vp);
+(* JSPropertyOp)(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
 /*
  * This function type is used for callbacks that enumerate the properties of
  * a JSObject.  The behavior depends on the value of enum_op:
  *
  *  JSENUMERATE_INIT
  *    A new, opaque iterator state should be allocated and stored in *statep.
  *    (You can use PRIVATE_TO_JSVAL() to tag the pointer to be stored).
@@ -191,41 +190,40 @@ typedef JSBool
  *  JSENUMERATE_DESTROY
  *    Destroy the opaque iterator state previously allocated in *statep by a
  *    call to this function when enum_op was JSENUMERATE_INIT.
  *
  * The return value is used to indicate success, with a value of JS_FALSE
  * indicating failure.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSNewEnumerateOp)(JSContext *cx, JSObject *obj,
-                                     JSIterateOp enum_op,
-                                     jsval *statep, jsid *idp);
+(* JSNewEnumerateOp)(JSContext *cx, JSObject *obj, JSIterateOp enum_op,
+                     jsval *statep, jsid *idp);
 
 /*
  * The old-style JSClass.enumerate op should define all lazy properties not
  * yet reflected in obj.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSEnumerateOp)(JSContext *cx, JSObject *obj);
+(* JSEnumerateOp)(JSContext *cx, JSObject *obj);
 
 /*
  * Resolve a lazy property named by id in obj by defining it directly in obj.
  * Lazy properties are those reflected from some peer native property space
  * (e.g., the DOM attributes for a given node reflected as obj) on demand.
  *
  * JS looks for a property in an object, and if not found, tries to resolve
  * the given id.  If resolve succeeds, the engine looks again in case resolve
  * defined obj[id].  If no such property exists directly in obj, the process
  * is repeated with obj's prototype, etc.
  *
  * NB: JSNewResolveOp provides a cheaper way to resolve lazy properties.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSResolveOp)(JSContext *cx, JSObject *obj, jsval id);
+(* JSResolveOp)(JSContext *cx, JSObject *obj, jsval id);
 
 /*
  * Like JSResolveOp, but flags provide contextual information as follows:
  *
  *  JSRESOLVE_QUALIFIED   a qualified property id: obj.id or obj[id], not id
  *  JSRESOLVE_ASSIGNING   obj[id] is on the left-hand side of an assignment
  *  JSRESOLVE_DETECTING   'if (o.p)...' or similar detection opcode sequence
  *  JSRESOLVE_DECLARING   var, const, or function prolog declaration opcode
@@ -247,41 +245,40 @@ typedef JSBool
  * When using JSCLASS_NEW_RESOLVE_GETS_START, the resolve hook must therefore
  * null *objp to signify "not resolved".  With only JSCLASS_NEW_RESOLVE and no
  * JSCLASS_NEW_RESOLVE_GETS_START, the hook can assume *objp is null on entry.
  * This is not good practice, but enough existing hook implementations count
  * on it that we can't break compatibility by passing the starting object in
  * *objp without a new JSClass flag.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSNewResolveOp)(JSContext *cx, JSObject *obj, jsval id,
-                                   uintN flags, JSObject **objp);
+(* JSNewResolveOp)(JSContext *cx, JSObject *obj, jsval id, uintN flags,
+                   JSObject **objp);
 
 /*
  * Convert obj to the given type, returning true with the resulting value in
  * *vp on success, and returning false on error or exception.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSConvertOp)(JSContext *cx, JSObject *obj, JSType type,
-                                jsval *vp);
+(* JSConvertOp)(JSContext *cx, JSObject *obj, JSType type, jsval *vp);
 
 /*
  * Finalize obj, which the garbage collector has determined to be unreachable
  * from other live objects or from GC roots.  Obviously, finalizers must never
  * store a reference to obj.
  */
 typedef void
-(* JS_DLL_CALLBACK JSFinalizeOp)(JSContext *cx, JSObject *obj);
+(* JSFinalizeOp)(JSContext *cx, JSObject *obj);
 
 /*
  * Used by JS_AddExternalStringFinalizer and JS_RemoveExternalStringFinalizer
  * to extend and reduce the set of string types finalized by the GC.
  */
 typedef void
-(* JS_DLL_CALLBACK JSStringFinalizeOp)(JSContext *cx, JSString *str);
+(* JSStringFinalizeOp)(JSContext *cx, JSString *str);
 
 /*
  * The signature for JSClass.getObjectOps, used by JS_NewObject's internals
  * to discover the set of high-level object operations to use for new objects
  * of the given class.  All native objects have a JSClass, which is stored as
  * a private (int-tagged) pointer in obj slots. In contrast, all native and
  * host objects have a JSObjectMap at obj->map, which may be shared among a
  * number of objects, and which contains the JSObjectOps *ops pointer used to
@@ -298,57 +295,56 @@ typedef void
  * need to implement the larger JSObjectOps, and can share the common JSScope
  * code and data used by the native (js_ObjectOps, see jsobj.c) ops.
  *
  * Further extension to preserve API compatibility: if this function returns
  * a pointer to JSXMLObjectOps.base, not to JSObjectOps, then the engine calls
  * extended hooks needed for E4X.
  */
 typedef JSObjectOps *
-(* JS_DLL_CALLBACK JSGetObjectOps)(JSContext *cx, JSClass *clasp);
+(* JSGetObjectOps)(JSContext *cx, JSClass *clasp);
 
 /*
  * JSClass.checkAccess type: check whether obj[id] may be accessed per mode,
  * returning false on error/exception, true on success with obj[id]'s last-got
  * value in *vp, and its attributes in *attrsp.  As for JSPropertyOp above, id
  * is either a string or an int jsval.
  *
  * See JSCheckAccessIdOp, below, for the JSObjectOps counterpart, which takes
  * a jsid (a tagged int or aligned, unique identifier pointer) rather than a
  * jsval.  The native js_ObjectOps.checkAccess simply forwards to the object's
  * clasp->checkAccess, so that both JSClass and JSObjectOps implementors may
  * specialize access checks.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSCheckAccessOp)(JSContext *cx, JSObject *obj, jsval id,
-                                    JSAccessMode mode, jsval *vp);
+(* JSCheckAccessOp)(JSContext *cx, JSObject *obj, jsval id, JSAccessMode mode,
+                    jsval *vp);
 
 /*
  * Encode or decode an object, given an XDR state record representing external
  * data.  See jsxdrapi.h.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSXDRObjectOp)(JSXDRState *xdr, JSObject **objp);
+(* JSXDRObjectOp)(JSXDRState *xdr, JSObject **objp);
 
 /*
  * Check whether v is an instance of obj.  Return false on error or exception,
  * true on success with JS_TRUE in *bp if v is an instance of obj, JS_FALSE in
  * *bp otherwise.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSHasInstanceOp)(JSContext *cx, JSObject *obj, jsval v,
-                                    JSBool *bp);
+(* JSHasInstanceOp)(JSContext *cx, JSObject *obj, jsval v, JSBool *bp);
 
 /*
  * Deprecated function type for JSClass.mark. All new code should define
  * JSTraceOp instead to ensure the traversal of traceable things stored in
  * the native structures.
  */
 typedef uint32
-(* JS_DLL_CALLBACK JSMarkOp)(JSContext *cx, JSObject *obj, void *arg);
+(* JSMarkOp)(JSContext *cx, JSObject *obj, void *arg);
 
 /*
  * Function type for trace operation of the class called to enumerate all
  * traceable things reachable from obj's private data structure. For each such
  * thing, a trace implementation must call
  *
  *    JS_CallTracer(trc, thing, kind);
  *
@@ -363,17 +359,17 @@ typedef uint32
  * marking its native structures.
  *
  * To define the tracer for a JSClass, the implementation must add
  * JSCLASS_MARK_IS_TRACE to class flags and use JS_CLASS_TRACE(method)
  * macro below to convert JSTraceOp to JSMarkOp when initializing or
  * assigning JSClass.mark field.
  */
 typedef void
-(* JS_DLL_CALLBACK JSTraceOp)(JSTracer *trc, JSObject *obj);
+(* JSTraceOp)(JSTracer *trc, JSObject *obj);
 
 #if defined __GNUC__ && __GNUC__ >= 4 && !defined __cplusplus
 # define JS_CLASS_TRACE(method)                                               \
     (__builtin_types_compatible_p(JSTraceOp, __typeof(&(method)))             \
      ? (JSMarkOp)(method)                                                     \
      : js_WrongTypeForClassTracer)
 
 extern JSMarkOp js_WrongTypeForClassTracer;
@@ -390,42 +386,41 @@ extern JSMarkOp js_WrongTypeForClassTrac
  * prepared to deal with cycles in the traversal graph.
  *
  * kind argument is one of JSTRACE_OBJECT, JSTRACE_DOUBLE, JSTRACE_STRING or
  * a tag denoting internal implementation-specific traversal kind. In the
  * latter case the only operations on thing that the callback can do is to call
  * JS_TraceChildren or DEBUG-only JS_PrintTraceThingInfo.
  */
 typedef void
-(* JS_DLL_CALLBACK JSTraceCallback)(JSTracer *trc, void *thing, uint32 kind);
+(* JSTraceCallback)(JSTracer *trc, void *thing, uint32 kind);
 
 /*
  * DEBUG only callback that JSTraceOp implementation can provide to return
  * a string describing the reference traced with JS_CallTracer.
  */
 #ifdef DEBUG
 typedef void
-(* JS_DLL_CALLBACK JSTraceNamePrinter)(JSTracer *trc, char *buf,
-                                       size_t bufsize);
+(* JSTraceNamePrinter)(JSTracer *trc, char *buf, size_t bufsize);
 #endif
 
 /*
  * The optional JSClass.reserveSlots hook allows a class to make computed
  * per-instance object slots reservations, in addition to or instead of using
  * JSCLASS_HAS_RESERVED_SLOTS(n) in the JSClass.flags initializer to reserve
  * a constant-per-class number of slots.  Implementations of this hook should
  * return the number of slots to reserve, not including any reserved by using
  * JSCLASS_HAS_RESERVED_SLOTS(n) in JSClass.flags.
  *
  * NB: called with obj locked by the JSObjectOps-specific mutual exclusion
  * mechanism appropriate for obj, so don't nest other operations that might
  * also lock obj.
  */
 typedef uint32
-(* JS_DLL_CALLBACK JSReserveSlotsOp)(JSContext *cx, JSObject *obj);
+(* JSReserveSlotsOp)(JSContext *cx, JSObject *obj);
 
 /* JSObjectOps function pointer typedefs. */
 
 /*
  * Create a new subclass of JSObjectMap (see jsobj.h), with the nrefs and ops
  * members initialized from the same-named parameters, and with the nslots and
  * freeslot members initialized according to ops and clasp.  Return null on
  * error, non-null on success.
@@ -433,26 +428,25 @@ typedef uint32
  * JSObjectMaps are reference-counted by generic code in the engine.  Usually,
  * the nrefs parameter to JSObjectOps.newObjectMap will be 1, to count the ref
  * returned to the caller on success.  After a successful construction, some
  * number of js_HoldObjectMap and js_DropObjectMap calls ensue.  When nrefs
  * reaches 0 due to a js_DropObjectMap call, JSObjectOps.destroyObjectMap will
  * be called to dispose of the map.
  */
 typedef JSObjectMap *
-(* JS_DLL_CALLBACK JSNewObjectMapOp)(JSContext *cx, jsrefcount nrefs,
-                                     JSObjectOps *ops, JSClass *clasp,
-                                     JSObject *obj);
+(* JSNewObjectMapOp)(JSContext *cx, jsrefcount nrefs, JSObjectOps *ops,
+                     JSClass *clasp, JSObject *obj);
 
 /*
  * Generic type for an infallible JSObjectMap operation, used currently by
  * JSObjectOps.destroyObjectMap.
  */
 typedef void
-(* JS_DLL_CALLBACK JSObjectMapOp)(JSContext *cx, JSObjectMap *map);
+(* JSObjectMapOp)(JSContext *cx, JSObjectMap *map);
 
 /*
  * Look for id in obj and its prototype chain, returning false on error or
  * exception, true on success.  On success, return null in *propp if id was
  * not found.  If id was found, return the first object searching from obj
  * along its prototype chain in which id names a direct property in *objp, and
  * return a non-null, opaque property pointer in *propp.
  *
@@ -462,155 +456,143 @@ typedef void
  * successful lookup must be dropped via JSObjectOps.dropProperty.
  *
  * NB: successful return with non-null *propp means the implementation may
  * have locked *objp and added a reference count associated with *propp, so
  * callers should not risk deadlock by nesting or interleaving other lookups
  * or any obj-bearing ops before dropping *propp.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSLookupPropOp)(JSContext *cx, JSObject *obj, jsid id,
-                                   JSObject **objp, JSProperty **propp);
+(* JSLookupPropOp)(JSContext *cx, JSObject *obj, jsid id, JSObject **objp,
+                   JSProperty **propp);
 
 /*
  * Define obj[id], a direct property of obj named id, having the given initial
  * value, with the specified getter, setter, and attributes.  If the propp out
  * param is non-null, *propp on successful return contains an opaque property
  * pointer usable as a speedup hint with JSAttributesOp.  But note that propp
  * may be null, indicating that the caller is not interested in recovering an
  * opaque pointer to the newly-defined property.
  *
  * If propp is non-null and JSDefinePropOp succeeds, its caller must be sure
  * to drop *propp using JSObjectOps.dropProperty in short order, just as with
  * JSLookupPropOp.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSDefinePropOp)(JSContext *cx, JSObject *obj,
-                                   jsid id, jsval value,
-                                   JSPropertyOp getter, JSPropertyOp setter,
-                                   uintN attrs, JSProperty **propp);
+(* JSDefinePropOp)(JSContext *cx, JSObject *obj, jsid id, jsval value,
+                   JSPropertyOp getter, JSPropertyOp setter, uintN attrs,
+                   JSProperty **propp);
 
 /*
  * Get, set, or delete obj[id], returning false on error or exception, true
  * on success.  If getting or setting, the new value is returned in *vp on
  * success.  If deleting without error, *vp will be JSVAL_FALSE if obj[id] is
  * permanent, and JSVAL_TRUE if id named a direct property of obj that was in
  * fact deleted, or if id names no direct property of obj (id could name a
  * prototype property, or no property in obj or its prototype chain).
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSPropertyIdOp)(JSContext *cx, JSObject *obj, jsid id,
-                                   jsval *vp);
+(* JSPropertyIdOp)(JSContext *cx, JSObject *obj, jsid id, jsval *vp);
 
 /*
  * Get or set attributes of the property obj[id].  Return false on error or
  * exception, true with current attributes in *attrsp.  If prop is non-null,
  * it must come from the *propp out parameter of a prior JSDefinePropOp or
  * JSLookupPropOp call.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSAttributesOp)(JSContext *cx, JSObject *obj, jsid id,
-                                   JSProperty *prop, uintN *attrsp);
+(* JSAttributesOp)(JSContext *cx, JSObject *obj, jsid id, JSProperty *prop,
+                   uintN *attrsp);
 
 /*
  * JSObjectOps.checkAccess type: check whether obj[id] may be accessed per
  * mode, returning false on error/exception, true on success with obj[id]'s
  * last-got value in *vp, and its attributes in *attrsp.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSCheckAccessIdOp)(JSContext *cx, JSObject *obj, jsid id,
-                                      JSAccessMode mode, jsval *vp,
-                                      uintN *attrsp);
+(* JSCheckAccessIdOp)(JSContext *cx, JSObject *obj, jsid id, JSAccessMode mode,
+                      jsval *vp, uintN *attrsp);
 
 /*
  * A generic type for functions mapping an object to another object, or null
  * if an error or exception was thrown on cx.  Used by JSObjectOps.thisObject
  * at present.
  */
 typedef JSObject *
-(* JS_DLL_CALLBACK JSObjectOp)(JSContext *cx, JSObject *obj);
+(* JSObjectOp)(JSContext *cx, JSObject *obj);
 
 /*
  * Hook that creates an iterator object for a given object. Returns the
  * iterator object or null if an error or exception was thrown on cx.
  */
 typedef JSObject *
-(* JS_DLL_CALLBACK JSIteratorOp)(JSContext *cx, JSObject *obj,
-                                 JSBool keysonly);
+(* JSIteratorOp)(JSContext *cx, JSObject *obj, JSBool keysonly);
 
 /*
  * A generic type for functions taking a context, object, and property, with
  * no return value.  Used by JSObjectOps.dropProperty currently (see above,
  * JSDefinePropOp and JSLookupPropOp, for the object-locking protocol in which
  * dropProperty participates).
  */
 typedef void
-(* JS_DLL_CALLBACK JSPropertyRefOp)(JSContext *cx, JSObject *obj,
-                                    JSProperty *prop);
+(* JSPropertyRefOp)(JSContext *cx, JSObject *obj, JSProperty *prop);
 
 /*
  * Function pointer type for JSObjectOps.setProto and JSObjectOps.setParent.
  * These hooks must check for cycles without deadlocking, and otherwise take
  * special steps. See jsobj.c and jsgc.c for details.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSSetObjectSlotOp)(JSContext *cx, JSObject *obj,
-                                      uint32 slot, JSObject *pobj);
+(* JSSetObjectSlotOp)(JSContext *cx, JSObject *obj, uint32 slot,
+                      JSObject *pobj);
 
 /*
  * Get and set a required slot, one that should already have been allocated.
  * These operations are infallible, so required slots must be pre-allocated,
  * or implementations must suppress out-of-memory errors.  The native ops
  * (js_ObjectOps, see jsobj.c) access slots reserved by including a call to
  * the JSCLASS_HAS_RESERVED_SLOTS(n) macro in the JSClass.flags initializer.
  *
  * NB: the slot parameter is a zero-based index into obj slots, unlike the
  * index parameter to the JS_GetReservedSlot and JS_SetReservedSlot API entry
  * points, which is a zero-based index into the JSCLASS_RESERVED_SLOTS(clasp)
  * reserved slots that come after the initial well-known slots: proto, parent,
  * class, and optionally, the private data slot.
  */
 typedef jsval
-(* JS_DLL_CALLBACK JSGetRequiredSlotOp)(JSContext *cx, JSObject *obj,
-                                        uint32 slot);
+(* JSGetRequiredSlotOp)(JSContext *cx, JSObject *obj, uint32 slot);
 
 typedef JSBool
-(* JS_DLL_CALLBACK JSSetRequiredSlotOp)(JSContext *cx, JSObject *obj,
-                                        uint32 slot, jsval v);
+(* JSSetRequiredSlotOp)(JSContext *cx, JSObject *obj, uint32 slot, jsval v);
 
 typedef JSObject *
-(* JS_DLL_CALLBACK JSGetMethodOp)(JSContext *cx, JSObject *obj, jsid id,
-                                  jsval *vp);
+(* JSGetMethodOp)(JSContext *cx, JSObject *obj, jsid id, jsval *vp);
 
 typedef JSBool
-(* JS_DLL_CALLBACK JSSetMethodOp)(JSContext *cx, JSObject *obj, jsid id,
-                                  jsval *vp);
+(* JSSetMethodOp)(JSContext *cx, JSObject *obj, jsid id, jsval *vp);
 
 typedef JSBool
-(* JS_DLL_CALLBACK JSEnumerateValuesOp)(JSContext *cx, JSObject *obj,
-                                        JSIterateOp enum_op,
-                                        jsval *statep, jsid *idp, jsval *vp);
+(* JSEnumerateValuesOp)(JSContext *cx, JSObject *obj, JSIterateOp enum_op,
+                        jsval *statep, jsid *idp, jsval *vp);
 
 typedef JSBool
-(* JS_DLL_CALLBACK JSEqualityOp)(JSContext *cx, JSObject *obj, jsval v,
-                                 JSBool *bp);
+(* JSEqualityOp)(JSContext *cx, JSObject *obj, jsval v, JSBool *bp);
 
 typedef JSBool
-(* JS_DLL_CALLBACK JSConcatenateOp)(JSContext *cx, JSObject *obj, jsval v,
-                                    jsval *vp);
+(* JSConcatenateOp)(JSContext *cx, JSObject *obj, jsval v, jsval *vp);
 
 /* Typedef for native functions called by the JS VM. */
 
 typedef JSBool
-(* JS_DLL_CALLBACK JSNative)(JSContext *cx, JSObject *obj, uintN argc,
-                             jsval *argv, jsval *rval);
+(* JSNative)(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
+             jsval *rval);
 
 /* See jsapi.h, the JS_CALLEE, JS_THIS, etc. macros. */
 typedef JSBool
-(* JS_DLL_CALLBACK JSFastNative)(JSContext *cx, uintN argc, jsval *vp);
+(* JSFastNative)(JSContext *cx, uintN argc, jsval *vp);
 
 /* Callbacks and their arguments. */
 
 typedef enum JSContextOp {
     JSCONTEXT_NEW,
     JSCONTEXT_DESTROY
 } JSContextOp;
 
@@ -623,47 +605,46 @@ typedef enum JSContextOp {
  *                      this case the callback is not called again.
  *   JSCONTEXT_DESTROY  One of JS_DestroyContext* methods is called. The
  *                      callback may perform its own cleanup and must always
  *                      return true.
  *   Any other value    For future compatibility the callback must do nothing
  *                      and return true in this case.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSContextCallback)(JSContext *cx, uintN contextOp);
+(* JSContextCallback)(JSContext *cx, uintN contextOp);
 
 typedef enum JSGCStatus {
     JSGC_BEGIN,
     JSGC_END,
     JSGC_MARK_END,
     JSGC_FINALIZE_END
 } JSGCStatus;
 
 typedef JSBool
-(* JS_DLL_CALLBACK JSGCCallback)(JSContext *cx, JSGCStatus status);
+(* JSGCCallback)(JSContext *cx, JSGCStatus status);
 
 /*
  * Generic trace operation that calls JS_CallTracer on each traceable thing
  * stored in data.
  */
 typedef void
-(* JS_DLL_CALLBACK JSTraceDataOp)(JSTracer *trc, void *data);
+(* JSTraceDataOp)(JSTracer *trc, void *data);
 
 typedef JSBool
-(* JS_DLL_CALLBACK JSOperationCallback)(JSContext *cx);
+(* JSOperationCallback)(JSContext *cx);
 
 /*
  * Deprecated form of JSOperationCallback.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSBranchCallback)(JSContext *cx, JSScript *script);
+(* JSBranchCallback)(JSContext *cx, JSScript *script);
 
 typedef void
-(* JS_DLL_CALLBACK JSErrorReporter)(JSContext *cx, const char *message,
-                                    JSErrorReport *report);
+(* JSErrorReporter)(JSContext *cx, const char *message, JSErrorReport *report);
 
 /*
  * Possible exception types. These types are part of a JSErrorFormatString
  * structure. They define which error to throw in case of a runtime error.
  * JSEXN_NONE marks an unthrowable error.
  */
 typedef enum JSExnType {
     JSEXN_NONE = -1,
@@ -685,66 +666,61 @@ typedef struct JSErrorFormatString {
     /* The number of arguments to expand in the formatted error message. */
     uint16 argCount;
 
     /* One of the JSExnType constants above. */
     int16 exnType;
 } JSErrorFormatString;
 
 typedef const JSErrorFormatString *
-(* JS_DLL_CALLBACK JSErrorCallback)(void *userRef, const char *locale,
-                                    const uintN errorNumber);
+(* JSErrorCallback)(void *userRef, const char *locale,
+                    const uintN errorNumber);
 
 #ifdef va_start
 #define JS_ARGUMENT_FORMATTER_DEFINED 1
 
 typedef JSBool
-(* JS_DLL_CALLBACK JSArgumentFormatter)(JSContext *cx, const char *format,
-                                        JSBool fromJS, jsval **vpp,
-                                        va_list *app);
+(* JSArgumentFormatter)(JSContext *cx, const char *format, JSBool fromJS,
+                        jsval **vpp, va_list *app);
 #endif
 
 typedef JSBool
-(* JS_DLL_CALLBACK JSLocaleToUpperCase)(JSContext *cx, JSString *src,
-                                        jsval *rval);
+(* JSLocaleToUpperCase)(JSContext *cx, JSString *src, jsval *rval);
+
+typedef JSBool
+(* JSLocaleToLowerCase)(JSContext *cx, JSString *src, jsval *rval);
 
 typedef JSBool
-(* JS_DLL_CALLBACK JSLocaleToLowerCase)(JSContext *cx, JSString *src,
-                                        jsval *rval);
+(* JSLocaleCompare)(JSContext *cx, JSString *src1, JSString *src2,
+                    jsval *rval);
 
 typedef JSBool
-(* JS_DLL_CALLBACK JSLocaleCompare)(JSContext *cx,
-                                    JSString *src1, JSString *src2,
-                                    jsval *rval);
-
-typedef JSBool
-(* JS_DLL_CALLBACK JSLocaleToUnicode)(JSContext *cx, char *src, jsval *rval);
+(* JSLocaleToUnicode)(JSContext *cx, char *src, jsval *rval);
 
 /*
  * Security protocol types.
  */
 typedef struct JSPrincipals JSPrincipals;
 
 /*
  * XDR-encode or -decode a principals instance, based on whether xdr->mode is
  * JSXDR_ENCODE, in which case *principalsp should be encoded; or JSXDR_DECODE,
  * in which case implementations must return a held (via JSPRINCIPALS_HOLD),
  * non-null *principalsp out parameter.  Return true on success, false on any
  * error, which the implementation must have reported.
  */
 typedef JSBool
-(* JS_DLL_CALLBACK JSPrincipalsTranscoder)(JSXDRState *xdr,
-                                           JSPrincipals **principalsp);
+(* JSPrincipalsTranscoder)(JSXDRState *xdr, JSPrincipals **principalsp);
 
 /*
  * Return a weak reference to the principals associated with obj, possibly via
  * the immutable parent chain leading from obj to a top-level container (e.g.,
  * a window object in the DOM level 0).  If there are no principals associated
  * with obj, return null.  Therefore null does not mean an error was reported;
  * in no event should an error be reported or an exception be thrown by this
  * callback's implementation.
  */
 typedef JSPrincipals *
-(* JS_DLL_CALLBACK JSObjectPrincipalsFinder)(JSContext *cx, JSObject *obj);
+(* JSObjectPrincipalsFinder)(JSContext *cx, JSObject *obj);
 
 JS_END_EXTERN_C
 
 #endif /* jspubtd_h___ */
--- a/js/src/jsscope.cpp
+++ b/js/src/jsscope.cpp
@@ -388,17 +388,17 @@ ChangeScope(JSContext *cx, JSScope *scop
     return JS_TRUE;
 }
 
 /*
  * Take care to exclude the mark bits in case we're called from the GC.
  */
 #define SPROP_FLAGS_NOT_MATCHED (SPROP_MARK | SPROP_FLAG_SHAPE_REGEN)
 
-JS_STATIC_DLL_CALLBACK(JSDHashNumber)
+static JSDHashNumber
 js_HashScopeProperty(JSDHashTable *table, const void *key)
 {
     const JSScopeProperty *sprop = (const JSScopeProperty *)key;
     JSDHashNumber hash;
     JSPropertyOp gsop;
 
     /* Accumulate from least to most random so the low bits are most random. */
     hash = 0;
@@ -434,17 +434,17 @@ js_HashScopeProperty(JSDHashTable *table
                                     aflags, ashortid)                         \
     ((sprop)->getter == (agetter) &&                                          \
      (sprop)->setter == (asetter) &&                                          \
      (sprop)->slot == (aslot) &&                                              \
      (sprop)->attrs == (aattrs) &&                                            \
      (((sprop)->flags ^ (aflags)) & ~SPROP_FLAGS_NOT_MATCHED) == 0 &&         \
      (sprop)->shortid == (ashortid))
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 js_MatchScopeProperty(JSDHashTable *table,
                       const JSDHashEntryHdr *hdr,
                       const void *key)
 {
     const JSPropertyTreeEntry *entry = (const JSPropertyTreeEntry *)hdr;
     const JSScopeProperty *sprop = entry->child;
     const JSScopeProperty *kprop = (const JSScopeProperty *)key;
 
@@ -1612,17 +1612,17 @@ MeterPropertyTree(JSBasicStats *bs, JSSc
             MeterPropertyTree(bs, kids);
             nkids = 1;
         }
     }
 
     MeterKidCount(bs, nkids);
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 js_MeterPropertyTree(JSDHashTable *table, JSDHashEntryHdr *hdr, uint32 number,
                      void *arg)
 {
     JSPropertyTreeEntry *entry = (JSPropertyTreeEntry *)hdr;
     JSBasicStats *bs = (JSBasicStats *)arg;
 
     MeterPropertyTree(bs, entry->child);
     return JS_DHASH_NEXT;
--- a/js/src/jsscript.cpp
+++ b/js/src/jsscript.cpp
@@ -958,54 +958,54 @@ js_InitScriptClass(JSContext *cx, JSObje
                         NULL, script_methods, NULL, script_static_methods);
 }
 
 #endif /* JS_HAS_SCRIPT_OBJECT */
 
 /*
  * Shared script filename management.
  */
-JS_STATIC_DLL_CALLBACK(int)
+static int
 js_compare_strings(const void *k1, const void *k2)
 {
     return strcmp((const char *) k1, (const char *) k2) == 0;
 }
 
 /* NB: This struct overlays JSHashEntry -- see jshash.h, do not reorganize. */
 typedef struct ScriptFilenameEntry {
     JSHashEntry         *next;          /* hash chain linkage */
     JSHashNumber        keyHash;        /* key hash function result */
     const void          *key;           /* ptr to filename, below */
     uint32              flags;          /* user-defined filename prefix flags */
     JSPackedBool        mark;           /* GC mark flag */
     char                filename[3];    /* two or more bytes, NUL-terminated */
 } ScriptFilenameEntry;
 
-JS_STATIC_DLL_CALLBACK(void *)
+static void *
 js_alloc_table_space(void *priv, size_t size)
 {
     return malloc(size);
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 js_free_table_space(void *priv, void *item)
 {
     free(item);
 }
 
-JS_STATIC_DLL_CALLBACK(JSHashEntry *)
+static JSHashEntry *
 js_alloc_sftbl_entry(void *priv, const void *key)
 {
     size_t nbytes = offsetof(ScriptFilenameEntry, filename) +
                     strlen((const char *) key) + 1;
 
     return (JSHashEntry *) malloc(JS_MAX(nbytes, sizeof(JSHashEntry)));
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 js_free_sftbl_entry(void *priv, JSHashEntry *he, uintN flag)
 {
     if (flag != HT_FREE_ENTRY)
         return;
     free(he);
 }
 
 static JSHashAllocOps sftbl_alloc_ops = {
@@ -1233,17 +1233,17 @@ js_MarkScriptFilename(const char *filena
 {
     ScriptFilenameEntry *sfe;
 
     sfe = FILENAME_TO_SFE(filename);
     ASSERT_VALID_SFE(sfe);
     sfe->mark = JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(intN)
+static intN
 js_script_filename_marker(JSHashEntry *he, intN i, void *arg)
 {
     ScriptFilenameEntry *sfe = (ScriptFilenameEntry *) he;
 
     sfe->mark = JS_TRUE;
     return HT_ENUMERATE_NEXT;
 }
 
@@ -1264,17 +1264,17 @@ js_MarkScriptFilenames(JSRuntime *rt, JS
     for (head = &rt->scriptFilenamePrefixes, link = head->next;
          link != head;
          link = link->next) {
         sfp = (ScriptFilenamePrefix *) link;
         js_MarkScriptFilename(sfp->name);
     }
 }
 
-JS_STATIC_DLL_CALLBACK(intN)
+static intN
 js_script_filename_sweeper(JSHashEntry *he, intN i, void *arg)
 {
     ScriptFilenameEntry *sfe = (ScriptFilenameEntry *) he;
 
     if (!sfe->mark)
         return HT_ENUMERATE_REMOVE;
     sfe->mark = JS_FALSE;
     return HT_ENUMERATE_NEXT;
--- a/js/src/jsstr.cpp
+++ b/js/src/jsstr.cpp
@@ -2378,17 +2378,17 @@ js_str_fromCharCode(JSContext *cx, uintN
     return JS_TRUE;
 }
 
 static JSFunctionSpec string_static_methods[] = {
     JS_FN("fromCharCode",    js_str_fromCharCode,    1,0),
     JS_FS_END
 };
 
-JS_STATIC_DLL_CALLBACK(JSHashNumber)
+static JSHashNumber
 js_hash_string_pointer(const void *key)
 {
     return (JSHashNumber)JS_PTR_TO_UINT32(key) >> JSVAL_TAGBITS;
 }
 
 JSBool
 js_InitRuntimeStringState(JSContext *cx)
 {
--- a/js/src/jstypes.h
+++ b/js/src/jstypes.h
@@ -79,45 +79,36 @@
 #ifdef WIN32
 
 /* These also work for __MWERKS__ */
 # define JS_EXTERN_API(__type)  extern __declspec(dllexport) __type
 # define JS_EXPORT_API(__type)  __declspec(dllexport) __type
 # define JS_EXTERN_DATA(__type) extern __declspec(dllexport) __type
 # define JS_EXPORT_DATA(__type) __declspec(dllexport) __type
 
-# define JS_DLL_CALLBACK
-# define JS_STATIC_DLL_CALLBACK(__x)    static __x
-
 #elif defined(XP_OS2) && defined(__declspec)
 
 # define JS_EXTERN_API(__type)  extern __declspec(dllexport) __type
 # define JS_EXPORT_API(__type)  __declspec(dllexport) __type
 # define JS_EXTERN_DATA(__type) extern __declspec(dllexport) __type
 # define JS_EXPORT_DATA(__type) __declspec(dllexport) __type
 
-# define JS_DLL_CALLBACK
-# define JS_STATIC_DLL_CALLBACK(__x)    static __x
-
 #else /* Unix */
 
 # ifdef HAVE_VISIBILITY_ATTRIBUTE
 #  define JS_EXTERNAL_VIS __attribute__((visibility ("default")))
 # else
 #  define JS_EXTERNAL_VIS
 # endif
 
 # define JS_EXTERN_API(__type)  extern JS_EXTERNAL_VIS __type
 # define JS_EXPORT_API(__type)  JS_EXTERNAL_VIS __type
 # define JS_EXTERN_DATA(__type) extern JS_EXTERNAL_VIS __type
 # define JS_EXPORT_DATA(__type) JS_EXTERNAL_VIS __type
 
-# define JS_DLL_CALLBACK
-# define JS_STATIC_DLL_CALLBACK(__x)    static __x
-
 #endif
 
 #ifdef _WIN32
 # if defined(__MWERKS__) || defined(__GNUC__)
 #  define JS_IMPORT_API(__x)    __x
 # else
 #  define JS_IMPORT_API(__x)    __declspec(dllimport) __x
 # endif
--- a/js/src/jsxml.cpp
+++ b/js/src/jsxml.cpp
@@ -6031,17 +6031,17 @@ TraceObjectVector(JSTracer *trc, JSObjec
         obj = vec[i];
         if (obj) {
             JS_SET_TRACING_INDEX(trc, "vector", i);
             JS_CallTracer(trc, obj, JSTRACE_OBJECT);
         }
     }
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 trace_temp_ns_array(JSTracer *trc, JSTempValueRooter *tvr)
 {
     JSTempRootedNSArray *tmp = (JSTempRootedNSArray *)tvr;
 
     TraceObjectVector(trc,
                       (JSObject **) tmp->array.vector,
                       tmp->array.length);
     XMLArrayCursorTrace(trc, tmp->array.cursors);
--- a/js/src/jsxml.h
+++ b/js/src/jsxml.h
@@ -50,17 +50,17 @@ extern const char js_isXMLName_str[];
 extern const char js_XMLList_str[];
 
 extern const char js_amp_entity_str[];
 extern const char js_gt_entity_str[];
 extern const char js_lt_entity_str[];
 extern const char js_quot_entity_str[];
 
 typedef JSBool
-(* JS_DLL_CALLBACK JSIdentityOp)(const void *a, const void *b);
+(* JSIdentityOp)(const void *a, const void *b);
 
 struct JSXMLArray {
     uint32              length;
     uint32              capacity;
     void                **vector;
     JSXMLArrayCursor    *cursors;
 };
 
--- a/js/src/liveconnect/README.html
+++ b/js/src/liveconnect/README.html
@@ -461,23 +461,16 @@ of us are not using vt100's to read sour
 is to use no more than 95 columns per line, but exceptions are made to
 format tables or table-like code.</li>
 
 <li>
 DLL entry points have their return type expanded within a JS_EXPORT_API()&nbsp;
 macro call, to get the right Windows secret type qualifiers in the right
 places for both 16- and 32-bit builds.</li>
 
-<li>
-Callback functions that might be called from a DLL are similarly macroized
-with JS_STATIC_DLL_CALLBACK (if the function otherwise would be static
-to hide its name) or JS_DLL_CALLBACK (this macro takes no type argument;
-it should be used after the return type and before the function name).</li>
-</ul>
-
 <h2>
 <a NAME="API"></a>The LiveConnect API</h2>
 All public LiveConnect entry points and callbacks are documented in 
 <A HREF=http://lxr.mozilla.org/mozilla/source/js/src/liveconnect/jsjava.h>jsjava.h</A>,
 the header file that exports those functions.
 <br>&nbsp;
 <h2>
 <a NAME="File_walkthrough"></a>File walk-through</h2>
--- a/js/src/liveconnect/jsj_JSObject.c
+++ b/js/src/liveconnect/jsj_JSObject.c
@@ -369,17 +369,17 @@ destroy_saved_js_error(JNIEnv *jEnv, Cap
  * that has itself been called from Java.  A copy of the JS error data is made
  * and hung off the JSJ environment.  When JS completes and returns to its Java
  * caller, this data is used to synthesize an instance of
  * netscape.javascript.JSException.  If the resulting JSException is not caught
  * within Java, it may be propagated up the stack beyond the Java caller back
  * into JavaScript, in which case the error will be re-reported as a JavaScript
  * error.
  */
-JS_STATIC_DLL_CALLBACK(void)
+static void
 capture_js_error_reports_for_java(JSContext *cx, const char *message,
                                   JSErrorReport *report)
 {
     CapturedJSError *new_error;
     JSJavaThreadState *jsj_env;
     jthrowable java_exception, tmp_exception;
     JNIEnv *jEnv;
 
--- a/js/src/liveconnect/jsj_JavaArray.c
+++ b/js/src/liveconnect/jsj_JavaArray.c
@@ -203,47 +203,47 @@ access_java_array_element(JSContext *cx,
         return jsj_SetJavaArrayElement(cx, jEnv, java_array, index,
                                        array_component_signature, *vp);
     } else {
         return jsj_GetJavaArrayElement(cx, jEnv, java_array, index,
                                        array_component_signature, vp);
     }
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaArray_getPropertyById(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
     JNIEnv *jEnv;
     JSJavaThreadState *jsj_env;
     JSBool result;
 
     jsj_env = jsj_EnterJava(cx, &jEnv);
     if (!jEnv)
         return JS_FALSE;
     result = access_java_array_element(cx, jEnv, obj, id, vp, JS_FALSE);
     jsj_ExitJava(jsj_env);
     return result;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaArray_setPropertyById(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
     JNIEnv *jEnv;
     JSJavaThreadState *jsj_env;
     JSBool result;
     
     jsj_env = jsj_EnterJava(cx, &jEnv);
     if (!jEnv)
         return JS_FALSE;
     result = access_java_array_element(cx, jEnv, obj, id, vp, JS_TRUE);
     jsj_ExitJava(jsj_env);
     return result;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaArray_lookupProperty(JSContext *cx, JSObject *obj, jsid id,
                          JSObject **objp, JSProperty **propp)
 {
     JNIEnv *jEnv;
     JSErrorReporter old_reporter;
     JSJavaThreadState *jsj_env;
 
     jsj_env = jsj_EnterJava(cx, &jEnv);
@@ -258,54 +258,54 @@ JavaArray_lookupProperty(JSContext *cx, 
         *objp = NULL;
         *propp = NULL;
     }
     JS_SetErrorReporter(cx, old_reporter);
     jsj_ExitJava(jsj_env);
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaArray_defineProperty(JSContext *cx, JSObject *obj, jsid id, jsval value,
                          JSPropertyOp getter, JSPropertyOp setter,
                          uintN attrs, JSProperty **propp)
 {
     jsval *vp = &value;
     if (propp)
         return JS_FALSE;
     if (attrs & ~(JSPROP_PERMANENT|JSPROP_ENUMERATE))
         return JS_FALSE;
 
     return JavaArray_setPropertyById(cx, obj, id, vp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaArray_getAttributes(JSContext *cx, JSObject *obj, jsid id,
                         JSProperty *prop, uintN *attrsp)
 {
     /* We don't maintain JS property attributes for Java class members */
     *attrsp = JSPROP_PERMANENT|JSPROP_ENUMERATE;
     return JS_FALSE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaArray_setAttributes(JSContext *cx, JSObject *obj, jsid id,
                         JSProperty *prop, uintN *attrsp)
 {
     /* We don't maintain JS property attributes for Java class members */
     if (*attrsp != (JSPROP_PERMANENT|JSPROP_ENUMERATE)) {
         JS_ASSERT(0);
         return JS_FALSE;
     }
 
     /* Silently ignore all setAttribute attempts */
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaArray_deleteProperty(JSContext *cx, JSObject *obj, jsid id, jsval *vp)
 {
     JSVersion version = JS_GetVersion(cx);
 
     *vp = JSVAL_FALSE;
     
     if (!JSVERSION_IS_ECMA(version)) {
         JS_ReportErrorNumber(cx, jsj_GetErrorMessage, NULL, 
@@ -313,24 +313,24 @@ JavaArray_deleteProperty(JSContext *cx, 
         return JS_FALSE;
     } else {
         /* Attempts to delete permanent properties are silently ignored
            by ECMAScript. */
         return JS_TRUE;
     }
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaArray_defaultValue(JSContext *cx, JSObject *obj, JSType type, jsval *vp)
 {
     /* printf("In JavaArray_defaultValue()\n"); */
     return JavaObject_convert(cx, obj, JSTYPE_STRING, vp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaArray_newEnumerate(JSContext *cx, JSObject *obj, JSIterateOp enum_op,
                        jsval *statep, jsid *idp)
 {
     JavaObjectWrapper *java_wrapper;
     JSJavaThreadState *jsj_env;
     JNIEnv *jEnv;
     jsize array_length, index;
     JSBool ok = JS_TRUE;
@@ -383,17 +383,17 @@ JavaArray_newEnumerate(JSContext *cx, JS
         ok = JS_FALSE;
         break;
     }
 
     jsj_ExitJava(jsj_env);
     return ok;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaArray_checkAccess(JSContext *cx, JSObject *obj, jsid id,
                       JSAccessMode mode, jsval *vp, uintN *attrsp)
 {
     switch (mode) {
     case JSACC_WATCH:
         JS_ReportErrorNumber(cx, jsj_GetErrorMessage, NULL, 
                                             JSJMSG_JARRAY_PROP_WATCH);
         return JS_FALSE;
@@ -428,17 +428,17 @@ JSObjectOps JavaArray_ops = {
     NULL,                           /* setProto */
     NULL,                           /* setParent */
     NULL,                           /* mark */
     NULL,                           /* clear */
     jsj_wrapper_getRequiredSlot,    /* getRequiredSlot */
     jsj_wrapper_setRequiredSlot     /* setRequiredSlot */
 };
 
-JS_STATIC_DLL_CALLBACK(JSObjectOps *)
+static JSObjectOps *
 JavaArray_getObjectOps(JSContext *cx, JSClass *clazz)
 {
     return &JavaArray_ops;
 }
 
 JSClass JavaArray_class = {
     "JavaArray", JSCLASS_HAS_PRIVATE,
     NULL, NULL, NULL, NULL,
--- a/js/src/liveconnect/jsj_JavaClass.c
+++ b/js/src/liveconnect/jsj_JavaClass.c
@@ -53,17 +53,17 @@
  * a first-class object that can be referenced simply as "java.lang.String".)
  */
 
 #include <stdlib.h>
 #include <string.h>
 
 #include "jsj_private.h"        /* LiveConnect internals */
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaClass_convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp)
 {
     char *name;
     JSString *str;
 
     JavaClassDescriptor *class_descriptor;
     
     class_descriptor = JS_GetPrivate(cx, obj);
@@ -153,17 +153,17 @@ lookup_static_member_by_id(JSContext *cx
     }
 
 done:
     if (memberp)
         *memberp = member_descriptor;
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaClass_getPropertyById(JSContext *cx, JSObject *obj, jsid id, jsval *vp)
 {
     jsval idval;
     jclass java_class;
     const char *member_name;
     JavaClassDescriptor *class_descriptor;
     JavaMemberDescriptor *member_descriptor;
     JNIEnv *jEnv;
@@ -222,17 +222,17 @@ JavaClass_getPropertyById(JSContext *cx,
 
         *vp = OBJECT_TO_JSVAL(JS_GetFunctionObject(function));
     }
 
     jsj_ExitJava(jsj_env);
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaClass_setPropertyById(JSContext *cx, JSObject *obj, jsid id, jsval *vp)
 {
     jclass java_class;
     const char *member_name;
     JavaClassDescriptor *class_descriptor;
     JavaMemberDescriptor *member_descriptor;
     jsval idval;
     JNIEnv *jEnv;
@@ -275,17 +275,17 @@ no_such_field:
                    member_name, class_descriptor->name);
     jsj_ExitJava(jsj_env);
     return JS_FALSE;
 }
 
 /*
  * Free the private native data associated with the JavaPackage object.
  */
-JS_STATIC_DLL_CALLBACK(void)
+static void
 JavaClass_finalize(JSContext *cx, JSObject *obj)
 {
     JNIEnv *jEnv;
     JSJavaThreadState *jsj_env;
 
     JavaClassDescriptor *class_descriptor = JS_GetPrivate(cx, obj);
     if (!class_descriptor)
         return;
@@ -296,17 +296,17 @@ JavaClass_finalize(JSContext *cx, JSObje
         return;
 
     /* printf("Finalizing %s\n", class_descriptor->name); */
     jsj_ReleaseJavaClassDescriptor(cx, jEnv, class_descriptor);
     jsj_ExitJava(jsj_env);
 }
 
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaClass_lookupProperty(JSContext *cx, JSObject *obj, jsid id,
                          JSObject **objp, JSProperty **propp)
 {
     JNIEnv *jEnv;
     JSErrorReporter old_reporter;
     JSJavaThreadState *jsj_env;
 
     /* printf("In JavaClass_lookupProperty()\n"); */
@@ -325,17 +325,17 @@ JavaClass_lookupProperty(JSContext *cx, 
         *propp = NULL;
     }
 
     JS_SetErrorReporter(cx, old_reporter);
     jsj_ExitJava(jsj_env);
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaClass_defineProperty(JSContext *cx, JSObject *obj, jsid id, jsval value,
                          JSPropertyOp getter, JSPropertyOp setter,
                          uintN attrs, JSProperty **propp)
 {
     JavaClassDescriptor *class_descriptor;
     
     class_descriptor = JS_GetPrivate(cx, obj);
 
@@ -343,40 +343,40 @@ JavaClass_defineProperty(JSContext *cx, 
     if (!class_descriptor)
 	return JS_TRUE;
 
     JS_ReportErrorNumber(cx, jsj_GetErrorMessage, NULL, 
                          JSJMSG_JCLASS_PROP_DEFINE);
     return JS_FALSE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaClass_getAttributes(JSContext *cx, JSObject *obj, jsid id,
                         JSProperty *prop, uintN *attrsp)
 {
     /* We don't maintain JS property attributes for Java class members */
     *attrsp = JSPROP_PERMANENT|JSPROP_ENUMERATE;
     return JS_FALSE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaClass_setAttributes(JSContext *cx, JSObject *obj, jsid id,
                         JSProperty *prop, uintN *attrsp)
 {
     /* We don't maintain JS property attributes for Java class members */
     if (*attrsp != (JSPROP_PERMANENT|JSPROP_ENUMERATE)) {
         JS_ASSERT(0);
         return JS_FALSE;
     }
 
     /* Silently ignore all setAttribute attempts */
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaClass_deleteProperty(JSContext *cx, JSObject *obj, jsid id, jsval *vp)
 {
     JSVersion version = JS_GetVersion(cx);
     
     *vp = JSVAL_FALSE;
 
     if (!JSVERSION_IS_ECMA(version)) {
         JS_ReportErrorNumber(cx, jsj_GetErrorMessage, NULL,
@@ -384,24 +384,24 @@ JavaClass_deleteProperty(JSContext *cx, 
         return JS_FALSE;
     } else {
         /* Attempts to delete permanent properties are silently ignored
            by ECMAScript. */
         return JS_TRUE;
     }
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaClass_defaultValue(JSContext *cx, JSObject *obj, JSType type, jsval *vp)
 {
     /* printf("In JavaClass_defaultValue()\n"); */
     return JavaClass_convert(cx, obj, JSTYPE_STRING, vp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaClass_newEnumerate(JSContext *cx, JSObject *obj, JSIterateOp enum_op,
                        jsval *statep, jsid *idp)
 {
     JavaMemberDescriptor *member_descriptor;
     JavaClassDescriptor *class_descriptor;
     JNIEnv *jEnv;
     JSJavaThreadState *jsj_env;
     
@@ -453,17 +453,17 @@ JavaClass_newEnumerate(JSContext *cx, JS
         return JS_TRUE;
 
     default:
         JS_ASSERT(0);
         return JS_FALSE;
     }
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaClass_checkAccess(JSContext *cx, JSObject *obj, jsid id,
                       JSAccessMode mode, jsval *vp, uintN *attrsp)
 {
     switch (mode) {
     case JSACC_WATCH:
         JS_ReportErrorNumber(cx, jsj_GetErrorMessage, NULL, 
                                             JSJMSG_JCLASS_PROP_WATCH);
         return JS_FALSE;
@@ -472,17 +472,17 @@ JavaClass_checkAccess(JSContext *cx, JSO
         return JS_TRUE;
     }
 }
 
 /*
  * Implement the JavaScript instanceof operator for JavaClass objects by using
  * the equivalent Java instanceof operation.
  */
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaClass_hasInstance(JSContext *cx, JSObject *obj, jsval candidate_jsval,
                       JSBool *has_instancep)
 {
     JavaClassDescriptor *class_descriptor;
     JavaObjectWrapper *java_wrapper;
     JSClass *js_class;
     JSBool has_instance;
     JSObject *candidate_obj;
@@ -553,17 +553,17 @@ JSObjectOps JavaClass_ops = {
     NULL,                           /* setProto */
     NULL,                           /* setParent */
     NULL,                           /* mark */
     NULL,                           /* clear */
     jsj_wrapper_getRequiredSlot,    /* getRequiredSlot */
     jsj_wrapper_setRequiredSlot     /* setRequiredSlot */
 };
 
-JS_STATIC_DLL_CALLBACK(JSObjectOps *)
+static JSObjectOps *
 JavaClass_getObjectOps(JSContext *cx, JSClass *clazz)
 {
     return &JavaClass_ops;
 }
 
 JSClass JavaClass_class = {
     "JavaClass", JSCLASS_HAS_PRIVATE,
     NULL, NULL, NULL, NULL,
@@ -626,17 +626,17 @@ jsj_define_JavaClass(JSContext *cx, JNIE
 /*
  * The getClass() native JS method is defined as a property of the global
  * object.  Given a JavaObject it returns the corresponding JavaClass.  This
  * is useful for accessing static methods and fields.
  *
  *    js> getClass(new java.lang.String("foo"))
  *    [JavaClass java.lang.String]
  */
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 getClass(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     JSObject *obj_arg, *JavaClass_obj;
     JavaObjectWrapper *java_wrapper;
     JavaClassDescriptor *class_descriptor;
     JNIEnv *jEnv;
     JSJavaThreadState *jsj_env;
 
@@ -669,17 +669,17 @@ getClass(JSContext *cx, JSObject *obj, u
         return JS_FALSE;
     }
 
     *rval = OBJECT_TO_JSVAL(JavaClass_obj);
     jsj_ExitJava(jsj_env);
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaClass_construct(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     JSObject *obj_arg, *JavaClass_obj;
     JavaObjectWrapper *java_wrapper;
     JavaClassDescriptor *class_descriptor;
     JNIEnv *jEnv;
     JSJavaThreadState *jsj_env;
 
--- a/js/src/liveconnect/jsj_JavaMember.c
+++ b/js/src/liveconnect/jsj_JavaMember.c
@@ -87,28 +87,28 @@ jsj_CreateJavaMember(JSContext *cx, jsva
 
     member_val->method_val = method_val;
     member_val->field_val = field_val;
     JS_SetPrivate(cx, JavaMember_obj, (void *)member_val);
 
     return JavaMember_obj;
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 JavaMember_finalize(JSContext *cx, JSObject *obj)
 {
     JavaMethodOrFieldValue *member_val;
 
     member_val = JS_GetPrivate(cx, obj);
     if (!member_val)
         return;
     JS_free(cx, member_val);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaMember_convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp)
 {
     JavaMethodOrFieldValue *member_val;
         
     member_val = JS_GetPrivate(cx, obj);
     if (!member_val) {
         if (type == JSTYPE_OBJECT) {
             *vp = OBJECT_TO_JSVAL(obj);
@@ -138,24 +138,24 @@ JavaMember_convert(JSContext *cx, JSObje
     }
 }
 
 /*
  * This function exists only to make JavaMember's Call'able.  The way the JS
  * engine is written now, it's never actually called because when a JavaMember
  * is invoked, it's converted to a JS function via JavaMember_convert().
  */
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaMember_Call(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     JS_ASSERT(0);
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 JavaMember_trace(JSTracer *trc, JSObject *obj)
 {
     JavaMethodOrFieldValue *member_val;
 
     member_val = (JavaMethodOrFieldValue *)JS_GetPrivate(trc->context, obj);
     if (member_val) {
         JS_CALL_VALUE_TRACER(trc, member_val->method_val, "method_val");
         JS_CALL_VALUE_TRACER(trc, member_val->field_val, "field_val");
--- a/js/src/liveconnect/jsj_JavaObject.c
+++ b/js/src/liveconnect/jsj_JavaObject.c
@@ -85,17 +85,17 @@ static JSJHashTable *java_obj_reflection
 static PRMonitor *java_obj_reflections_monitor = NULL;
 static int java_obj_reflections_mutation_count = 0;
 #endif
 
 static JSBool installed_GC_callback = JS_FALSE;
 static JSGCCallback old_GC_callback = NULL;
 static JavaObjectWrapper* deferred_wrappers = NULL;
 
-static JSBool JS_DLL_CALLBACK jsj_GC_callback(JSContext *cx, JSGCStatus status)
+static JSBool jsj_GC_callback(JSContext *cx, JSGCStatus status)
 {
     if (status == JSGC_END && deferred_wrappers) {
         JNIEnv *jEnv;
         JSJavaThreadState *jsj_env = jsj_EnterJava(cx, &jEnv);
         if (jEnv) {
             JavaObjectWrapper* java_wrapper = deferred_wrappers;
             while (java_wrapper) {
                 deferred_wrappers = java_wrapper->u.next;
@@ -367,17 +367,17 @@ jsj_DiscardJavaObjReflections(JNIEnv *jE
         JSJ_HashTableEnumerateEntries(java_obj_reflections,
                                       enumerate_remove_java_obj,
                                       (void*)jsj_env);
         JSJ_HashTableDestroy(java_obj_reflections);
         java_obj_reflections = NULL;
     }
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 JavaObject_convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp)
 {
     JavaObjectWrapper *java_wrapper;
     JavaClassDescriptor *class_descriptor;
     jobject java_obj;
     JNIEnv *jEnv;
     JSJavaThreadState *jsj_env;
     JSBool result;
@@ -722,17 +722,17 @@ JavaObject_getPropertyById(JSContext *cx
     }
 
 #endif  /* !TEST_JAVAMEMBER */
 
     jsj_ExitJava(jsj_env);
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaObject_setPropertyById(JSContext *cx, JSObject *obj, jsid id, jsval *vp)
 {
     jobject java_obj;
     const char *member_name;
     JavaObjectWrapper *java_wrapper;
     JavaClassDescriptor *class_descriptor;
     JavaMemberDescriptor *member_descriptor;
     jsval idval;
@@ -806,17 +806,17 @@ no_such_field:
     class_descriptor = java_wrapper->class_descriptor;
     JS_ReportErrorNumber(cx, jsj_GetErrorMessage, NULL,
                          JSJMSG_NO_NAME_IN_CLASS,
                          member_name, class_descriptor->name);
     jsj_ExitJava(jsj_env);
     return JS_FALSE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaObject_lookupProperty(JSContext *cx, JSObject *obj, jsid id,
                          JSObject **objp, JSProperty **propp)
 {
     JNIEnv *jEnv;
     JSErrorReporter old_reporter;
     jsval dummy_val;
     JSObject *proto_chain;
     JSJPropertyInfo prop_info;
@@ -846,50 +846,50 @@ JavaObject_lookupProperty(JSContext *cx,
         *propp = NULL;
     }
 
     JS_SetErrorReporter(cx, old_reporter);
     jsj_ExitJava(jsj_env);
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaObject_defineProperty(JSContext *cx, JSObject *obj, jsid id, jsval value,
                          JSPropertyOp getter, JSPropertyOp setter,
                          uintN attrs, JSProperty **propp)
 {
     JS_ReportErrorNumber(cx, jsj_GetErrorMessage, NULL,
                          JSJMSG_JOBJECT_PROP_DEFINE);
     return JS_FALSE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaObject_getAttributes(JSContext *cx, JSObject *obj, jsid id,
                         JSProperty *prop, uintN *attrsp)
 {
     /* We don't maintain JS property attributes for Java class members */
     *attrsp = JSPROP_PERMANENT|JSPROP_ENUMERATE;
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaObject_setAttributes(JSContext *cx, JSObject *obj, jsid id,
                         JSProperty *prop, uintN *attrsp)
 {
     /* We don't maintain JS property attributes for Java class members */
     if (*attrsp != (JSPROP_PERMANENT|JSPROP_ENUMERATE)) {
         JS_ASSERT(0);
         return JS_FALSE;
     }
 
     /* Silently ignore all setAttribute attempts */
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaObject_deleteProperty(JSContext *cx, JSObject *obj, jsid id, jsval *vp)
 {
     JSVersion version = JS_GetVersion(cx);
 
     *vp = JSVAL_FALSE;
 
     if (!JSVERSION_IS_ECMA(version)) {
         JS_ReportErrorNumber(cx, jsj_GetErrorMessage, NULL,
@@ -897,24 +897,24 @@ JavaObject_deleteProperty(JSContext *cx,
         return JS_FALSE;
     } else {
         /* Attempts to delete permanent properties are silently ignored
            by ECMAScript. */
         return JS_TRUE;
     }
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaObject_defaultValue(JSContext *cx, JSObject *obj, JSType type, jsval *vp)
 {
     /* printf("In JavaObject_defaultValue()\n"); */
     return JavaObject_convert(cx, obj, type, vp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaObject_newEnumerate(JSContext *cx, JSObject *obj, JSIterateOp enum_op,
                         jsval *statep, jsid *idp)
 {
     JavaObjectWrapper *java_wrapper;
     JavaMemberDescriptor *member_descriptor;
     JavaClassDescriptor *class_descriptor;
     JNIEnv *jEnv;
     JSJavaThreadState *jsj_env;
@@ -971,63 +971,63 @@ JavaObject_newEnumerate(JSContext *cx, J
         return JS_TRUE;
 
     default:
         JS_ASSERT(0);
         return JS_FALSE;
     }
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaObject_checkAccess(JSContext *cx, JSObject *obj, jsid id,
                       JSAccessMode mode, jsval *vp, uintN *attrsp)
 {
     switch (mode) {
     case JSACC_WATCH:
         JS_ReportErrorNumber(cx, jsj_GetErrorMessage, NULL,
                              JSJMSG_JOBJECT_PROP_WATCH);
         return JS_FALSE;
 
     default:
         return JS_TRUE;
     }
 }
 
 #define JSJ_SLOT_COUNT (JSSLOT_PRIVATE+1)
 
-JSObjectMap * JS_DLL_CALLBACK
+JSObjectMap *
 jsj_wrapper_newObjectMap(JSContext *cx, jsrefcount nrefs, JSObjectOps *ops,
                          JSClass *clasp, JSObject *obj)
 {
     JSObjectMap * map;
 
     map = (JSObjectMap *) JS_malloc(cx, sizeof(JSObjectMap));
     if (map) {
         map->nrefs = nrefs;
         map->ops = ops;
         map->freeslot = JSJ_SLOT_COUNT;
     }
     return map;
 }
 
-void JS_DLL_CALLBACK
+void
 jsj_wrapper_destroyObjectMap(JSContext *cx, JSObjectMap *map)
 {
     JS_free(cx, map);
 }
 
-jsval JS_DLL_CALLBACK
+jsval
 jsj_wrapper_getRequiredSlot(JSContext *cx, JSObject *obj, uint32 slot)
 {
     JS_ASSERT(slot < JSJ_SLOT_COUNT);
     JS_ASSERT(obj->map->freeslot == JSJ_SLOT_COUNT);
     return STOBJ_GET_SLOT(obj, slot);
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 jsj_wrapper_setRequiredSlot(JSContext *cx, JSObject *obj, uint32 slot, jsval v)
 {
     JS_ASSERT(slot < JSJ_SLOT_COUNT);
     JS_ASSERT(obj->map->freeslot == JSJ_SLOT_COUNT);
     STOBJ_SET_SLOT(obj, slot, v);
     return JS_TRUE;
 }
 
@@ -1056,17 +1056,17 @@ JSObjectOps JavaObject_ops = {
     NULL,                           /* setProto */
     NULL,                           /* setParent */
     NULL,                           /* mark */
     NULL,                           /* clear */
     jsj_wrapper_getRequiredSlot,    /* getRequiredSlot */
     jsj_wrapper_setRequiredSlot     /* setRequiredSlot */
 };
 
-JS_STATIC_DLL_CALLBACK(JSObjectOps *)
+static JSObjectOps *
 JavaObject_getObjectOps(JSContext *cx, JSClass *clazz)
 {
     return &JavaObject_ops;
 }
 
 JSClass JavaObject_class = {
     "JavaObject", JSCLASS_HAS_PRIVATE,
     NULL, NULL, NULL, NULL,
--- a/js/src/liveconnect/jsj_JavaPackage.c
+++ b/js/src/liveconnect/jsj_JavaPackage.c
@@ -132,17 +132,17 @@ define_JavaPackage(JSContext *cx, JSObje
 
 /* JavaPackage uses standard JS getProperty */
 
 /*
  * Don't allow user-defined properties to be set on Java package objects, e.g.
  * it is illegal to write "java.lang.myProperty = 4".  We probably could relax
  * this restriction, but it's potentially confusing and not clearly useful.
  */
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaPackage_setProperty(JSContext *cx, JSObject *obj, jsval slot, jsval *vp)
 {
     JavaPackage_Private *package = JS_GetPrivate(cx, obj);
     if (!package) {
         JS_ReportErrorNumber(cx, jsj_GetErrorMessage, NULL, 
                                                 JSJMSG_BAD_ADD_TO_PACKAGE);
         return JS_FALSE;
     }
@@ -151,17 +151,17 @@ JavaPackage_setProperty(JSContext *cx, J
     return JS_FALSE;
 }
 
 static JSBool quiet_resolve_failure;
 
 /*
  * Resolve a component name to be either the name of a class or a package.
  */
-JS_STATIC_DLL_CALLBACK(JSBool)
+static  JSBool
 JavaPackage_resolve(JSContext *cx, JSObject *obj, jsval id)
 {
     JavaPackage_Private *package;
     JSBool ok = JS_TRUE;
     jclass jclazz;
     char *subPath, *newPath;
     const char *path;
     JNIEnv *jEnv;
@@ -284,17 +284,17 @@ JavaPackage_resolve(JSContext *cx, JSObj
     }
     
 out:
     JS_smprintf_free(newPath);
     jsj_ExitJava(jsj_env);
     return ok;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaPackage_convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp)
 {
     JSString *str;
     char *name, *cp;
 
     JavaPackage_Private *package = JS_GetPrivate(cx, obj);
     if (!package) {
         fprintf(stderr, "JavaPackage_resolve: no private data!\n");
@@ -337,17 +337,17 @@ JavaPackage_convert(JSContext *cx, JSObj
         break;
     }
     return JS_TRUE;
 }
 
 /*
  * Free the private native data associated with the JavaPackage object.
  */
-JS_STATIC_DLL_CALLBACK(void)
+static void
 JavaPackage_finalize(JSContext *cx, JSObject *obj)
 {
     JavaPackage_Private *package = JS_GetPrivate(cx, obj);
     if (!package)
         return;
 
     if (package->path)
         JS_free(cx, (char *)package->path);
@@ -527,17 +527,17 @@ out_of_memory:
     JS_ReportOutOfMemory(cx);
 
 error:
     JS_FREE_IF(cx, package_name);
     JS_FREE_IF(cx, path);
     return JS_FALSE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 JavaPackage_toString(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                  jsval *rval)
 {
     if (!JS_InstanceOf(cx, obj, &JavaPackage_class, argv))
         return JS_FALSE;
     return JavaPackage_convert(cx, obj, JSTYPE_STRING, rval);
 }
 
--- a/js/src/liveconnect/jsj_class.c
+++ b/js/src/liveconnect/jsj_class.c
@@ -399,17 +399,17 @@ new_class_descriptor(JSContext *cx, JNIE
     return class_descriptor;
 
 error:
     destroy_class_descriptor(cx, jEnv, class_descriptor);
     return NULL;
 }
 
 /* Trivial helper for jsj_DiscardJavaClassReflections(), below */
-JS_STATIC_DLL_CALLBACK(JSIntn)
+static JSIntn
 enumerate_remove_java_class(JSJHashEntry *he, JSIntn i, void *arg)
 {
     JSJavaThreadState *jsj_env = (JSJavaThreadState *)arg;
     JavaClassDescriptor *class_descriptor;
 
     class_descriptor = (JavaClassDescriptor*)he->value;
 
     destroy_class_descriptor(jsj_env->cx, jsj_env->jEnv, class_descriptor);
--- a/js/src/liveconnect/jsj_hash.h
+++ b/js/src/liveconnect/jsj_hash.h
@@ -56,19 +56,19 @@
 #include "jstypes.h"
 
 JS_BEGIN_EXTERN_C
 
 typedef struct JSJHashEntry  JSJHashEntry;
 typedef struct JSJHashTable  JSJHashTable;
 typedef JSUint32 JSJHashNumber;
 #define JSJ_HASH_BITS 32
-typedef JSJHashNumber (* JS_DLL_CALLBACK JSJHashFunction)(const void *key, void *arg);
-typedef JSIntn (* JS_DLL_CALLBACK JSJHashComparator)(const void *v1, const void *v2, void *arg);
-typedef JSIntn (* JS_DLL_CALLBACK JSJHashEnumerator)(JSJHashEntry *he, JSIntn i, void *arg);
+typedef JSJHashNumber (* JSJHashFunction)(const void *key, void *arg);
+typedef JSIntn (* JSJHashComparator)(const void *v1, const void *v2, void *arg);
+typedef JSIntn (* JSJHashEnumerator)(JSJHashEntry *he, JSIntn i, void *arg);
 
 /* Flag bits in JSJHashEnumerator's return value */
 #define HT_ENUMERATE_NEXT       0       /* continue enumerating entries */
 #define HT_ENUMERATE_STOP       1       /* stop enumerating entries */
 #define HT_ENUMERATE_REMOVE     2       /* remove and free the current entry */
 #define HT_ENUMERATE_UNHASH     4       /* just unhash the current entry */
 
 typedef struct JSJHashAllocOps {
--- a/js/src/liveconnect/jsj_private.h
+++ b/js/src/liveconnect/jsj_private.h
@@ -550,17 +550,17 @@ extern JSBool
 jsj_InitJavaObjReflectionsTable(void);
 
 extern JSObject *
 jsj_WrapJavaObject(JSContext *cx, JNIEnv *jEnv, jobject java_obj, jclass java_class);
 
 extern void
 jsj_DiscardJavaObjReflections(JNIEnv *jEnv);
 
-extern JSBool JS_DLL_CALLBACK
+extern JSBool
 JavaObject_convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp);
 
 JS_EXTERN_API(void)
 JavaObject_finalize(JSContext *cx, JSObject *obj);
 
 extern JSBool
 JavaObject_resolve(JSContext *cx, JSObject *obj, jsval id);
 
@@ -605,23 +605,23 @@ extern void
 jsj_UnexpectedJavaError(JSContext *cx, JNIEnv *env, const char *format, ...);
 
 extern const char *
 jsj_GetJavaErrorMessage(JNIEnv *env);
 
 extern void
 jsj_LogError(const char *error_msg);
 
-extern const JSErrorFormatString * JS_DLL_CALLBACK
+extern const JSErrorFormatString *
 jsj_GetErrorMessage(void *userRef, const char *locale, const uintN errorNumber);
 
-JSJHashNumber JS_DLL_CALLBACK
+JSJHashNumber
 jsj_HashJavaObject(const void *key, void* env);
 
-intN JS_DLL_CALLBACK
+intN
 jsj_JavaObjectComparator(const void *v1, const void *v2, void *arg);
 
 extern JSJavaThreadState *
 jsj_MapJavaThreadToJSJavaThreadState(JNIEnv *jEnv, char **errp);
 
 extern void
 jsj_MakeJNIClassname(char *jClassName);
 
@@ -638,27 +638,27 @@ extern const char *
 jsj_DupJavaStringUTF(JSContext *cx, JNIEnv *jEnv, jstring jstr);
 
 extern JSJavaThreadState *
 jsj_EnterJava(JSContext *cx, JNIEnv **envp);
 
 extern void
 jsj_ExitJava(JSJavaThreadState *jsj_env);
 
-extern JSObjectMap * JS_DLL_CALLBACK
+extern JSObjectMap *
 jsj_wrapper_newObjectMap(JSContext *cx, jsrefcount nrefs, JSObjectOps *ops,
                          JSClass *clasp, JSObject *obj);
 
-extern void JS_DLL_CALLBACK
+extern void
 jsj_wrapper_destroyObjectMap(JSContext *cx, JSObjectMap *map);
 
-extern jsval JS_DLL_CALLBACK
+extern jsval
 jsj_wrapper_getRequiredSlot(JSContext *cx, JSObject *obj, uint32 slot);
 
-extern JSBool JS_DLL_CALLBACK
+extern JSBool
 jsj_wrapper_setRequiredSlot(JSContext *cx, JSObject *obj, uint32 slot, jsval v);
 
 #ifdef DEBUG
 #define DEBUG_LOG(args) printf args
 #endif
 
 #define JS_FREE_IF(cx, x)                                                   \
     JS_BEGIN_MACRO                                                          \
--- a/js/src/liveconnect/jsj_simpleapi.c
+++ b/js/src/liveconnect/jsj_simpleapi.c
@@ -75,17 +75,17 @@ default_map_jsj_thread_to_js_context(JSJ
 
 /* Trivial implementation of callback function */
 static JSObject *
 default_map_java_object_to_js_object(JNIEnv *jEnv, void *hint, char **errp)
 {
     return the_global_js_obj;
 }
 
-static JSBool JS_DLL_CALLBACK
+static JSBool
 default_create_java_vm(SystemJavaVM* *jvm, JNIEnv* *initialEnv, void* initargs)
 {
     jint err;
     const char* user_classpath = (const char*)initargs;
     char* full_classpath = NULL;
 
     /* No Java VM supplied, so create our own */
     JDK1_1InitArgs vm_args;
@@ -111,43 +111,43 @@ default_create_java_vm(SystemJavaVM* *jv
     err = JNI_CreateJavaVM((JavaVM**)jvm, initialEnv, &vm_args);
     
     if (full_classpath)
         JS_smprintf_free(full_classpath);
     
     return err == 0;
 }
 
-static JSBool JS_DLL_CALLBACK
+static JSBool
 default_destroy_java_vm(SystemJavaVM* jvm, JNIEnv* initialEnv)
 {
     JavaVM* java_vm = (JavaVM*)jvm;
     jint err = (*java_vm)->DestroyJavaVM(java_vm);
     return err == 0;
 }
 
-static JNIEnv* JS_DLL_CALLBACK
+static JNIEnv*
 default_attach_current_thread(SystemJavaVM* jvm)
 {
     JavaVM* java_vm = (JavaVM*)jvm;
     JNIEnv* env = NULL;
     (*java_vm)->AttachCurrentThread(java_vm, &env, NULL);
     return env;
 }
 
-static JSBool JS_DLL_CALLBACK
+static JSBool
 default_detach_current_thread(SystemJavaVM* jvm, JNIEnv* env)
 {
     JavaVM* java_vm = (JavaVM*)jvm;
     /* assert that env is the JNIEnv of the current thread */
     jint err = (*java_vm)->DetachCurrentThread(java_vm);
     return err == 0;
 }
 
-static SystemJavaVM* JS_DLL_CALLBACK
+static SystemJavaVM*
 default_get_java_vm(JNIEnv* env)
 {
     JavaVM* java_vm = NULL;
     (*env)->GetJavaVM(env, &java_vm);
     return (SystemJavaVM*)java_vm;
 }
 
 /* Trivial implementations of callback functions */
--- a/js/src/liveconnect/jsj_utils.c
+++ b/js/src/liveconnect/jsj_utils.c
@@ -58,17 +58,17 @@
 #include "jsj_private.h"        /* LiveConnect internals */
 #include "jsjava.h"             /* External LiveConnect API */
 
 
 /*
  * This is a hash-table utility routine that computes the hash code of a Java
  * object by calling java.lang.System.identityHashCode()
  */
-JSJHashNumber JS_DLL_CALLBACK
+JSJHashNumber
 jsj_HashJavaObject(const void *key, void* env)
 {
     JSHashNumber hash_code;
     jobject java_obj;
     JNIEnv *jEnv;
 
     java_obj = (jobject)key;
     jEnv = (JNIEnv*) env;
@@ -88,17 +88,17 @@ jsj_HashJavaObject(const void *key, void
 
 /* 
  * This is a hash-table utility routine for comparing two Java objects.
  * It's not possible to use the == operator to directly compare two jobject's,
  * since they're opaque references and aren't guaranteed to be simple pointers
  * or handles (though they may be in some JVM implementations).  Instead,
  * use the JNI routine for comparing the two objects.
  */
-intN JS_DLL_CALLBACK
+intN
 jsj_JavaObjectComparator(const void *v1, const void *v2, void *arg)
 {
     jobject java_obj1, java_obj2;
     JNIEnv *jEnv;
 
     jEnv = (JNIEnv*)arg;
     java_obj1 = (jobject)v1;
     java_obj2 = (jobject)v2;
--- a/js/src/plify_jsdhash.sed
+++ b/js/src/plify_jsdhash.sed
@@ -20,18 +20,16 @@ s/uint16  /PRUint16/g
 s/\([^U]\)int16  /\1PRInt16/g
 s/uint32/PRUint32/g
 s/\([^U]\)int32/\1PRInt32/g
 s/uint16/PRUint16/g
 s/\([^U]\)int16/\1PRInt16/g
 s/JSBool/PRBool/g
 s/extern JS_PUBLIC_API(\([^()]*\))/NS_COM_GLUE \1/
 s/JS_PUBLIC_API(\([^()]*\))/\1/
-s/JS_DLL_CALLBACK/PR_CALLBACK/
-s/JS_STATIC_DLL_CALLBACK/PR_STATIC_CALLBACK/
 s/JS_NewDHashTable/PL_NewDHashTable/
 s/JS_ASSERT(0)/NS_NOTREACHED("0")/
 s/\( *\)JS_ASSERT(\(.*\));/\1NS_ASSERTION(\2,\n\1             "\2");/
 s/JSDHASH_ONELINE_ASSERT(\(.*\));/NS_ASSERTION(\1, "\1");/
 s/JS_UNLIKELY/NS_UNLIKELY/g
 s/JS_LIKELY/NS_LIKELY/g
 s/JS_/PR_/g
 s/fprintf(stderr,/printf_stderr(/
--- a/js/src/prmjtime.cpp
+++ b/js/src/prmjtime.cpp
@@ -554,17 +554,17 @@ PRMJ_DSTOffset(JSInt64 local_time)
     JSLL_UI2L(local_time,diff);
 
     JSLL_MUL(local_time,local_time,us2s);
 
     return(local_time);
 }
 
 #ifdef NS_HAVE_INVALID_PARAMETER_HANDLER
-JS_STATIC_DLL_CALLBACK(void)
+static void
 PRMJ_InvalidParameterHandler(const wchar_t *expression,
                              const wchar_t *function,
                              const wchar_t *file,
                              unsigned int   line,
                              uintptr_t      pReserved)
 {
     /* empty */
 }
--- a/js/src/xpconnect/loader/mozJSComponentLoader.cpp
+++ b/js/src/xpconnect/loader/mozJSComponentLoader.cpp
@@ -118,17 +118,17 @@ static PRLogModuleInfo *gJSCLLog;
 #define ERROR_SCOPE_OBJ "%s - Second argument must be an object."
 #define ERROR_NOT_PRESENT "%s - EXPORTED_SYMBOLS is not present."
 #define ERROR_NOT_AN_ARRAY "%s - EXPORTED_SYMBOLS is not an array."
 #define ERROR_GETTING_ARRAY_LENGTH "%s - Error getting array length of EXPORTED_SYMBOLS."
 #define ERROR_ARRAY_ELEMENT "%s - EXPORTED_SYMBOLS[%d] is not a string."
 #define ERROR_GETTING_SYMBOL "%s - Could not get symbol '%s'."
 #define ERROR_SETTING_SYMBOL "%s - Could not set symbol '%s' on target object."
 
-void JS_DLL_CALLBACK
+void
 mozJSLoaderErrorReporter(JSContext *cx, const char *message, JSErrorReport *rep)
 {
     nsresult rv;
 
     /* Use the console service to register the error. */
     nsCOMPtr<nsIConsoleService> consoleService =
         do_GetService(NS_CONSOLESERVICE_CONTRACTID);
 
@@ -176,43 +176,43 @@ mozJSLoaderErrorReporter(JSContext *cx, 
     fprintf(stderr, "JS Component Loader: %s %s:%d\n"
             "                     %s\n",
             JSREPORT_IS_WARNING(rep->flags) ? "WARNING" : "ERROR",
             rep->filename, rep->lineno,
             message ? message : "<no message>");
 #endif
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Dump(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     JSString *str;
     if (!argc)
         return JS_TRUE;
     
     str = JS_ValueToString(cx, argv[0]);
     if (!str)
         return JS_FALSE;
 
     char *bytes = JS_GetStringBytes(str);
     fputs(bytes, stderr);
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Debug(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
 #ifdef DEBUG
     return Dump(cx, obj, argc, argv, rval);
 #else
     return JS_TRUE;
 #endif
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Atob(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     JSString *str;
     if (!argc)
         return JS_TRUE;
 
     str = JS_ValueToString(cx, argv[0]);
     if (!str)
@@ -238,17 +238,17 @@ Atob(JSContext *cx, JSObject *obj, uintN
     PR_Free(bin_data);
     if (!str)
         return JS_FALSE;
 
     *rval = STRING_TO_JSVAL(str);
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Btoa(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     JSString *str;
     if (!argc)
         return JS_TRUE;
 
     str = JS_ValueToString(cx, argv[0]);
     if (!str)
--- a/js/src/xpconnect/loader/mozJSSubScriptLoader.cpp
+++ b/js/src/xpconnect/loader/mozJSSubScriptLoader.cpp
@@ -68,17 +68,17 @@
 #define LOAD_ERROR_NOSTREAM  "Error opening input stream (invalid filename?)"
 #define LOAD_ERROR_NOCONTENT "ContentLength not available (not a local URL?)"
 #define LOAD_ERROR_BADREAD   "File Read Error."
 #define LOAD_ERROR_READUNDERFLOW "File Read Error (underflow.)"
 #define LOAD_ERROR_NOPRINCIPALS "Failed to get principals."
 #define LOAD_ERROR_NOSPEC "Failed to get URI spec.  This is bad."
 
 // We just use the same reporter as the component loader
-extern void JS_DLL_CALLBACK
+extern void
 mozJSLoaderErrorReporter(JSContext *cx, const char *message, JSErrorReport *rep);
 
 mozJSSubScriptLoader::mozJSSubScriptLoader() : mSystemPrincipal(nsnull)
 {
 }
 
 mozJSSubScriptLoader::~mozJSSubScriptLoader()    
 {
--- a/js/src/xpconnect/shell/xpcshell.cpp
+++ b/js/src/xpconnect/shell/xpcshell.cpp
@@ -108,17 +108,17 @@ FILE *gErrFile = NULL;
 
 int gExitCode = 0;
 JSBool gQuitting = JS_FALSE;
 static JSBool reportWarnings = JS_TRUE;
 static JSBool compileOnly = JS_FALSE;
 
 JSPrincipals *gJSPrincipals = nsnull;
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 my_ErrorReporter(JSContext *cx, const char *message, JSErrorReport *report)
 {
     int i, j, k, n;
     char *prefix = NULL, *tmp;
     const char *ctmp;
 
     if (!report) {
         fprintf(gErrFile, "%s\n", message);
@@ -175,17 +175,17 @@ my_ErrorReporter(JSContext *cx, const ch
     }
     fputs("^\n", gErrFile);
  out:
     if (!JSREPORT_IS_WARNING(report->flags))
         gExitCode = EXITCODE_RUNTIME_ERROR;
     JS_free(cx, prefix);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Print(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     uintN i, n;
     JSString *str;
 
     for (i = n = 0; i < argc; i++) {
         str = JS_ValueToString(cx, argv[i]);
         if (!str)
@@ -193,17 +193,17 @@ Print(JSContext *cx, JSObject *obj, uint
         fprintf(gOutFile, "%s%s", i ? " " : "", JS_GetStringBytes(str));
     }
     n++;
     if (n)
         fputc('\n', gOutFile);
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Dump(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     JSString *str;
     if (!argc)
         return JS_TRUE;
     
     str = JS_ValueToString(cx, argv[0]);
     if (!str)
@@ -212,17 +212,17 @@ Dump(JSContext *cx, JSObject *obj, uintN
     char *bytes = JS_GetStringBytes(str);
     bytes = strdup(bytes);
 
     fputs(bytes, gOutFile);
     free(bytes);
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Load(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     uintN i;
     JSString *str;
     const char *filename;
     JSScript *script;
     JSBool ok;
     jsval result;
@@ -246,49 +246,49 @@ Load(JSContext *cx, JSObject *obj, uintN
             JS_DestroyScript(cx, script);
         }
         if (!ok)
             return JS_FALSE;
     }
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Version(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     if (argc > 0 && JSVAL_IS_INT(argv[0]))
         *rval = INT_TO_JSVAL(JS_SetVersion(cx, JSVersion(JSVAL_TO_INT(argv[0]))));
     else
         *rval = INT_TO_JSVAL(JS_GetVersion(cx));
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 BuildDate(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     fprintf(gOutFile, "built on %s at %s\n", __DATE__, __TIME__);
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Quit(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
 #ifdef LIVECONNECT
     JSJ_SimpleShutdown();
 #endif
 
     gExitCode = 0;
     JS_ConvertArguments(cx, argc, argv,"/ i", &gExitCode);
 
     gQuitting = JS_TRUE;
 //    exit(0);
     return JS_FALSE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 DumpXPC(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     int32 depth = 2;
 
     if (argc > 0) {
         if (!JS_ValueToInt32(cx, argv[0], &depth))
             return JS_FALSE;
     }
@@ -297,17 +297,17 @@ DumpXPC(JSContext *cx, JSObject *obj, ui
     if(xpc)
         xpc->DebugDump((int16)depth);
     return JS_TRUE;
 }
 
 /* XXX needed only by GC() */
 #include "jscntxt.h"
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 GC(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     JSRuntime *rt;
     uint32 preBytes;
 
     rt = cx->runtime;
     preBytes = rt->gcBytes;
     JS_GC(cx);
@@ -403,17 +403,17 @@ DumpHeap(JSContext *cx, JSObject *obj, u
     fprintf(gErrFile,
             "dumpHeap: argument %u is not null or a heap-allocated thing\n",
             (unsigned)(vp - argv));
     return JS_FALSE;
 }
 
 #endif /* DEBUG */
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Clear(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     if (argc > 0 && !JSVAL_IS_PRIMITIVE(argv[0])) {
         JS_ClearScope(cx, JSVAL_TO_OBJECT(argv[0]));
     } else {
         JS_ReportError(cx, "'clear' requires an object");
         return JS_FALSE;
     }    
@@ -581,17 +581,17 @@ typedef enum JSShellErrNum {
 
 JSErrorFormatString jsShell_ErrorFormatString[JSErr_Limit] = {
 #define MSG_DEF(name, number, count, exception, format) \
     { format, count } ,
 #include "jsshell.msg"
 #undef MSG_DEF
 };
 
-JS_STATIC_DLL_CALLBACK(const JSErrorFormatString *)
+static const JSErrorFormatString *
 my_GetErrorMessage(void *userRef, const char *locale, const uintN errorNumber)
 {
     if ((errorNumber > 0) && (errorNumber < JSShellErr_Limit))
             return &jsShell_ErrorFormatString[errorNumber];
         else
             return NULL;
 }
 
@@ -1298,17 +1298,17 @@ nsXPCFunctionThisTranslator::TranslateTh
     *_retval = aInitialThis;
     *aHideFirstParamFromJS = JS_FALSE;
     *aIIDOfResult = nsnull;
     return NS_OK;
 }
 
 #endif
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 ContextCallback(JSContext *cx, uintN contextOp)
 {
     if (contextOp == JSCONTEXT_NEW) {
         JS_SetErrorReporter(cx, my_ErrorReporter);
         JS_SetVersion(cx, JSVERSION_LATEST);
     }
     return JS_TRUE;
 }
--- a/js/src/xpconnect/src/XPCCrossOriginWrapper.cpp
+++ b/js/src/xpconnect/src/XPCCrossOriginWrapper.cpp
@@ -44,62 +44,62 @@
 #include "jscntxt.h"  // For JSAutoTempValueRooter.
 #include "XPCWrapper.h"
 #include "nsIDOMWindow.h"
 #include "nsIDOMWindowCollection.h"
 
 // This file implements a wrapper around objects that allows them to be
 // accessed safely from across origins.
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_AddProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_DelProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_GetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_SetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_Enumerate(JSContext *cx, JSObject *obj);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_NewResolve(JSContext *cx, JSObject *obj, jsval id, uintN flags,
                    JSObject **objp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_Convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_XOW_Finalize(JSContext *cx, JSObject *obj);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_CheckAccess(JSContext *cx, JSObject *obj, jsval id, JSAccessMode mode,
                     jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_Call(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_Construct(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                   jsval *rval);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_HasInstance(JSContext *cx, JSObject *obj, jsval v, JSBool *bp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_Equality(JSContext *cx, JSObject *obj, jsval v, JSBool *bp);
 
-JS_STATIC_DLL_CALLBACK(JSObject *)
+static JSObject *
 XPC_XOW_Iterator(JSContext *cx, JSObject *obj, JSBool keysonly);
 
-JS_STATIC_DLL_CALLBACK(JSObject *)
+static JSObject *
 XPC_XOW_WrappedObject(JSContext *cx, JSObject *obj);
 
 JSExtendedClass sXPC_XOW_JSClass = {
   // JSClass (JSExtendedClass.base) initialization
   { "XPCCrossOriginWrapper",
     JSCLASS_NEW_RESOLVE | JSCLASS_IS_EXTENDED |
     JSCLASS_HAS_RESERVED_SLOTS(XPCWrapper::sNumSlots + 1),
     XPC_XOW_AddProperty, XPC_XOW_DelProperty,
@@ -127,17 +127,17 @@ JSExtendedClass sXPC_XOW_JSClass = {
 // (the parent link ensures this), we know that, when we're being
 // finalized, either our scope is still alive (i.e. we became garbage
 // due to no more references) or it is being garbage collected right now.
 // Therefore, we can look in gDyingScopes, and if our scope is there,
 // then the map is about to be destroyed anyway, so we don't need to
 // do anything.
 static const int XPC_XOW_ScopeSlot = XPCWrapper::sNumSlots;
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_toString(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                  jsval *rval);
 
 // Throws an exception on context |cx|.
 static inline
 JSBool
 ThrowException(nsresult ex, JSContext *cx)
 {
@@ -537,17 +537,17 @@ XPC_XOW_WrapObject(JSContext *cx, JSObje
   { // Scoped lock
     XPCAutoLock al(rt->GetMapLock());
     map->Add(wn->GetScope()->GetWrapperMap(), wrappedObj, outerObj);
   }
 
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_AddProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   // All AddProperty needs to do is pass on addProperty requests to
   // same-origin objects, and throw for all else.
 
   obj = GetWrapper(obj);
   jsval resolving;
   if (!JS_GetReservedSlot(cx, obj, XPCWrapper::sResolvingSlot, &resolving)) {
@@ -577,17 +577,17 @@ XPC_XOW_AddProperty(JSContext *cx, JSObj
     }
     return JS_FALSE;
   }
 
   // Same origin, pass this request along.
   return XPCWrapper::AddProperty(cx, obj, wrappedObj, id, vp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_DelProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   JSObject *wrappedObj = GetWrappedObject(cx, obj);
   if (!wrappedObj) {
     return ThrowException(NS_ERROR_ILLEGAL_VALUE, cx);
   }
 
   XPCCallContext ccx(JS_CALLER, cx);
@@ -732,29 +732,29 @@ XPC_XOW_GetOrSetProperty(JSContext *cx, 
       JS_ReportError(cx, "invalid __proto__ value (can only be set to null)");
       return JS_FALSE;
     }
   }
 
   return WrapSameOriginProp(cx, obj, vp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_GetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   return XPC_XOW_GetOrSetProperty(cx, obj, id, vp, JS_FALSE);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_SetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   return XPC_XOW_GetOrSetProperty(cx, obj, id, vp, JS_TRUE);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_Enumerate(JSContext *cx, JSObject *obj)
 {
   obj = GetWrapper(obj);
   JSObject *wrappedObj = GetWrappedObject(cx, obj);
   if (!wrappedObj) {
     // Nothing to enumerate.
     return JS_TRUE;
   }
@@ -772,17 +772,17 @@ XPC_XOW_Enumerate(JSContext *cx, JSObjec
     }
 
     return JS_FALSE;
   }
 
   return XPCWrapper::Enumerate(cx, obj, wrappedObj);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_NewResolve(JSContext *cx, JSObject *obj, jsval id, uintN flags,
                    JSObject **objp)
 {
   obj = GetWrapper(obj);
 
   JSObject *wrappedObj = GetWrappedObject(cx, obj);
   if (!wrappedObj) {
     // No wrappedObj means that this is probably the prototype.
@@ -848,17 +848,17 @@ XPC_XOW_NewResolve(JSContext *cx, JSObje
     }
 
     return ok;
   }
 
   return XPCWrapper::NewResolve(cx, obj, wrappedObj, id, flags, objp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_Convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp)
 {
   // Don't do any work to convert to object.
   if (type == JSTYPE_OBJECT) {
     *vp = OBJECT_TO_JSVAL(obj);
     return JS_TRUE;
   }
 
@@ -895,17 +895,17 @@ XPC_XOW_Convert(JSContext *cx, JSObject 
     return JS_FALSE;
   }
 
   return NS_SUCCEEDED(rv)
          ? WrapSameOriginProp(cx, obj, vp)
          : XPC_XOW_RewrapIfNeeded(cx, obj, vp);
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_XOW_Finalize(JSContext *cx, JSObject *obj)
 {
   JSObject *wrappedObj = GetWrappedObject(cx, obj);
   if (!wrappedObj) {
     return;
   }
 
   // Get our scope.
@@ -922,30 +922,30 @@ XPC_XOW_Finalize(JSContext *cx, JSObject
   if (!scope) {
     return;
   }
 
   // Remove ourselves from the map.
   scope->GetWrapperMap()->Remove(wrappedObj);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_CheckAccess(JSContext *cx, JSObject *obj, jsval prop, JSAccessMode mode,
                     jsval *vp)
 {
   // Simply forward checkAccess to our wrapped object. It's already expecting
   // untrusted things to ask it about accesses.
 
   uintN junk;
   jsid id;
   return JS_ValueToId(cx, prop, &id) &&
          JS_CheckAccess(cx, GetWrappedObject(cx, obj), id, mode, vp, &junk);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_Call(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   JSObject *wrappedObj = GetWrappedObject(cx, obj);
   if (!wrappedObj) {
     // Nothing to call.
     return JS_TRUE;
   }
 
@@ -970,17 +970,17 @@ XPC_XOW_Call(JSContext *cx, JSObject *ob
   if (!JS_CallFunctionValue(cx, obj, OBJECT_TO_JSVAL(callee), argc, argv,
                             rval)) {
     return JS_FALSE;
   }
 
   return XPC_XOW_RewrapIfNeeded(cx, callee, rval);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_Construct(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                   jsval *rval)
 {
   JSObject *realObj = GetWrapper(JSVAL_TO_OBJECT(argv[-2]));
   JSObject *wrappedObj = GetWrappedObject(cx, realObj);
   if (!wrappedObj) {
     // Nothing to construct.
     return JS_TRUE;
@@ -1006,17 +1006,17 @@ XPC_XOW_Construct(JSContext *cx, JSObjec
   if (!JS_CallFunctionValue(cx, obj, OBJECT_TO_JSVAL(callee), argc, argv,
                             rval)) {
     return JS_FALSE;
   }
 
   return XPC_XOW_RewrapIfNeeded(cx, callee, rval);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_HasInstance(JSContext *cx, JSObject *obj, jsval v, JSBool *bp)
 {
   JSObject *iface = GetWrappedObject(cx, obj);
 
   XPCCallContext ccx(JS_CALLER, cx);
   if (!ccx.IsValid()) {
     return ThrowException(NS_ERROR_FAILURE, cx);
   }
@@ -1046,17 +1046,17 @@ XPC_XOW_HasInstance(JSContext *cx, JSObj
     if (test) {
       v = OBJECT_TO_JSVAL(test);
     }
   }
 
   return clasp->hasInstance(cx, iface, v, bp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_Equality(JSContext *cx, JSObject *obj, jsval v, JSBool *bp)
 {
   // Convert both sides to XPCWrappedNative and see if they match.
   if (JSVAL_IS_PRIMITIVE(v)) {
     *bp = JS_FALSE;
     return JS_TRUE;
   }
 
@@ -1087,17 +1087,17 @@ XPC_XOW_Equality(JSContext *cx, JSObject
 
   XPCWrappedNative *me = XPCWrappedNative::GetWrappedNativeOfJSObject(cx, obj);
   obj = me->GetFlatJSObject();
   test = other->GetFlatJSObject();
   return ((JSExtendedClass *)STOBJ_GET_CLASS(obj))->
     equality(cx, obj, OBJECT_TO_JSVAL(test), bp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSObject *)
+static JSObject *
 XPC_XOW_Iterator(JSContext *cx, JSObject *obj, JSBool keysonly)
 {
   JSObject *wrappedObj = GetWrappedObject(cx, obj);
   if (!wrappedObj) {
     ThrowException(NS_ERROR_INVALID_ARG, cx);
     return nsnull;
   }
 
@@ -1136,23 +1136,23 @@ XPC_XOW_Iterator(JSContext *cx, JSObject
                           PRIVATE_TO_JSVAL(nsnull))) {
     return nsnull;
   }
 
   return XPCWrapper::CreateIteratorObj(cx, wrapperIter, obj, wrappedObj,
                                        keysonly);
 }
 
-JS_STATIC_DLL_CALLBACK(JSObject *)
+static JSObject *
 XPC_XOW_WrappedObject(JSContext *cx, JSObject *obj)
 {
   return GetWrappedObject(cx, obj);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_XOW_toString(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                  jsval *rval)
 {
   obj = GetWrapper(obj);
   if (!obj) {
     return ThrowException(NS_ERROR_UNEXPECTED, cx);
   }
 
--- a/js/src/xpconnect/src/XPCDispObject.cpp
+++ b/js/src/xpconnect/src/XPCDispObject.cpp
@@ -453,17 +453,17 @@ JSBool GetMember(XPCCallContext& ccx, JS
  * for an IDispatch instance
  * @param cx A pointer to a JS context
  * @param obj JS object that the parameterized property is on
  * @param argc Number of arguments in this call
  * @param argv The parameters passed in if any
  * @param vp The return value
  * @return Returns JS_TRUE if the operation succeeded
  */
-JSBool JS_DLL_CALLBACK
+JSBool
 XPC_IDispatch_CallMethod(JSContext* cx, JSObject* obj, uintN argc,
                          jsval* argv, jsval* vp)
 {
     NS_ASSERTION(JS_TypeOfValue(cx, argv[-2]) == JSTYPE_FUNCTION, "bad function");
     JSObject* funobj = JSVAL_TO_OBJECT(argv[-2]);
     XPCCallContext ccx(JS_CALLER, cx, obj, funobj, 0, argc, argv, vp);
     XPCWrappedNative* wrapper = ccx.GetWrapper();
     THROW_AND_RETURN_IF_BAD_WRAPPER(cx, wrapper);
@@ -487,17 +487,17 @@ XPC_IDispatch_CallMethod(JSContext* cx, 
  * JSObject proxying for an IDispatch instance
  * @param cx A pointer to a JS context
  * @param obj JS object that the parameterized property is on
  * @param argc Number of arguments in this call
  * @param argv The parameters passed in if any
  * @param vp The return value
  * @return Returns JS_TRUE if the operation succeeded
  */
-JSBool JS_DLL_CALLBACK
+JSBool
 XPC_IDispatch_GetterSetter(JSContext *cx, JSObject *obj, uintN argc,
                            jsval *argv, jsval *vp)
 {
     NS_ASSERTION(JS_TypeOfValue(cx, argv[-2]) == JSTYPE_FUNCTION, "bad function");
     JSObject* funobj = JSVAL_TO_OBJECT(argv[-2]);
 
     XPCCallContext ccx(JS_CALLER, cx, obj, funobj);
     XPCWrappedNative* wrapper = ccx.GetWrapper();
--- a/js/src/xpconnect/src/XPCDispParamPropJSClass.cpp
+++ b/js/src/xpconnect/src/XPCDispParamPropJSClass.cpp
@@ -61,17 +61,17 @@ XPCDispParamPropJSClass* GetParamProp(JS
  * property get requests are forward to our owner and on to IDispatch's
  * Invoke
  * @param cx A pointer to a JS context
  * @param obj The object to perform the get on
  * @param id ID of the parameter to get
  * @param vp Pointer to the return value
  * @return JSBool JS_TRUE if property was retrieved
  */
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_PP_GetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
     XPCDispParamPropJSClass* paramProp = GetParamProp(cx, obj);
     JSObject* originalObj = paramProp->GetWrapper()->GetFlatJSObject();
     XPCCallContext ccx(JS_CALLER, cx, originalObj, nsnull, id, 
                        paramProp->GetParams()->GetParamCount(), nsnull, vp);
     return paramProp->Invoke(ccx, XPCDispObject::CALL_GETTER, vp);
 }
@@ -82,17 +82,17 @@ XPC_PP_GetProperty(JSContext *cx, JSObje
  * property get requests are forward to our owner and on to IDispatch's
  * Invoke
  * @param cx A pointer to a JS context
  * @param obj The object to perform the get on
  * @param id ID of the parameter to get
  * @param vp Pointer to the return value
  * @return JSBool JS_TRUE if property was retrieved
  */
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_PP_SetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
     XPCDispParamPropJSClass* paramProp = GetParamProp(cx, obj);
     JSObject* originalObj = paramProp->GetWrapper()->GetFlatJSObject();
     XPCCallContext ccx(JS_CALLER, cx, originalObj, nsnull, id, 
                        paramProp->GetParams()->GetParamCount(), nsnull, vp);
     _variant_t var;
     uintN err;
@@ -121,28 +121,28 @@ XPC_PP_SetProperty(JSContext *cx, JSObje
  * property get requests are forward to our owner and on to IDispatch's
  * Invoke
  * @param cx A pointer to a JS context
  * @param obj The object to perform the get on
  * @param id ID of the parameter to get
  * @param vp Pointer to the return value
  * @return JSBool JS_TRUE if property was retrieved
  */
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_PP_Finalize(JSContext *cx, JSObject *obj)
 {
     delete GetParamProp(cx, obj);
 }
 
 /**
  * Is called to trace things that the object holds.
  * @param trc the tracing structure
  * @param obj the object being marked
  */
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_PP_Trace(JSTracer *trc, JSObject *obj)
 {
     XPCDispParamPropJSClass* paramProp = GetParamProp(trc->context, obj);
     if(paramProp)
     {
         XPCWrappedNative* wrapper = paramProp->GetWrapper();
         if(wrapper && wrapper->IsValid())
             xpc_TraceForValidWrapper(trc, wrapper);
--- a/js/src/xpconnect/src/XPCDispPrivate.h
+++ b/js/src/xpconnect/src/XPCDispPrivate.h
@@ -208,29 +208,29 @@ private:
  * JS callback function that is called when a function is invoked
  * @param cx the JS context the function is invoked with
  * @param obj the object the function is invoked on
  * @param argc the number of parameters passed to the function
  * @param argv the array of parameters passed to the function
  * @param vp holds the result of the function
  * @return true if the function completes without error
  */
-JSBool JS_DLL_CALLBACK
+JSBool
 XPC_IDispatch_CallMethod(JSContext *cx, JSObject *obj, uintN argc,
                          jsval *argv, jsval *vp);
 /**
  * JS callback function that is called when a getter/setter is invoked
  * @param cx the JS context the function is invoked with
  * @param obj the object the function is invoked on
  * @param argc the number of parameters passed to the function
  * @param argv the array of parameters passed to the function
  * @param vp holds the result of the function
  * @return true if the function completes without error
  */
-JSBool JS_DLL_CALLBACK
+JSBool
 XPC_IDispatch_GetterSetter(JSContext *cx, JSObject *obj, uintN argc, 
                            jsval *argv, jsval *vp);
 
 /**
  * This class holds an array of names. This is only used in wrapped
  * JS objects, so the dispid's are not arbitrary. They begin with 1
  * and so dispid - 1 is the index into the array mNames
  */
--- a/js/src/xpconnect/src/XPCDispTearOff.cpp
+++ b/js/src/xpconnect/src/XPCDispTearOff.cpp
@@ -226,17 +226,17 @@ STDMETHODIMP XPCDispatchTearOff::GetIDsO
     ITypeInfo * pTypeInfo = GetCOMTypeInfo();
     if(pTypeInfo != nsnull)
     {
         return pTypeInfo->GetIDsOfNames(rgszNames, cNames, rgDispId);
     }
     return S_OK;
 }
 
-void JS_DLL_CALLBACK
+void
 xpcWrappedJSErrorReporter(JSContext *cx, const char *message,
                           JSErrorReport *report);
 
 STDMETHODIMP XPCDispatchTearOff::Invoke(DISPID dispIdMember, REFIID riid, 
                                         LCID lcid, WORD wFlags,
                                         DISPPARAMS FAR* pDispParams, 
                                         VARIANT FAR* pVarResult, 
                                         EXCEPINFO FAR* pExcepInfo, 
--- a/js/src/xpconnect/src/XPCIDispatchExtension.cpp
+++ b/js/src/xpconnect/src/XPCIDispatchExtension.cpp
@@ -123,33 +123,33 @@ CommonConstructor(JSContext *cx, int nam
     {
         XPCThrower::Throw(nsrv, ccx);
         return JS_FALSE;
     }
     *rval = OBJECT_TO_JSVAL(jsobj);
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 COMObjectConstructor(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, 
                      jsval *rval)
 {
     return CommonConstructor(cx, XPCJSRuntime::IDX_COM_OBJECT, obj, argc,
                              argv, rval, PR_FALSE);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 ActiveXConstructor(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, 
                    jsval *rval)
 {
     return CommonConstructor(cx, XPCJSRuntime::IDX_ACTIVEX_OBJECT, obj, argc, argv,
                              rval, PR_TRUE);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 ActiveXSupports(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, 
                 jsval *rval)
 {
     XPCCallContext ccx(JS_CALLER, cx, JS_GetGlobalObject(cx));
     // Check if IDispatch is enabled, fail if not
     if(!nsXPConnect::IsIDispatchEnabled())
     {
         XPCThrower::Throw(NS_ERROR_XPC_IDISPATCH_NOT_ENABLED, ccx);
--- a/js/src/xpconnect/src/XPCNativeWrapper.cpp
+++ b/js/src/xpconnect/src/XPCNativeWrapper.cpp
@@ -39,63 +39,63 @@
  * ***** END LICENSE BLOCK ***** */
 
 #include "xpcprivate.h"
 #include "XPCNativeWrapper.h"
 #include "XPCWrapper.h"
 #include "jsdbgapi.h"
 #include "jsscope.h"
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_AddProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_DelProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_GetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_SetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_Enumerate(JSContext *cx, JSObject *obj);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_NewResolve(JSContext *cx, JSObject *obj, jsval id, uintN flags,
                   JSObject **objp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_Convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_NW_Finalize(JSContext *cx, JSObject *obj);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_CheckAccess(JSContext *cx, JSObject *obj, jsval id,
                    JSAccessMode mode, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_Call(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
             jsval *rval);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_Construct(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                  jsval *rval);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_HasInstance(JSContext *cx, JSObject *obj, jsval v, JSBool *bp);
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_NW_Trace(JSTracer *trc, JSObject *obj);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_Equality(JSContext *cx, JSObject *obj, jsval v, JSBool *bp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_FunctionWrapper(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                        jsval *rval);
 
 // JS class for XPCNativeWrapper (and this doubles as the constructor
 // for XPCNativeWrapper for the moment too...)
 
 JSExtendedClass XPCNativeWrapper::sXPC_NW_JSClass = {
   // JSClass (JSExtendedClass.base) initialization
@@ -175,21 +175,21 @@ ShouldBypassNativeWrapper(JSContext *cx,
   XPC_NW_BYPASS_BASE(cx, obj, XPC_NW_CAST_HOOK(obj, type, hook, args))
 
 #define XPC_NW_BYPASS_TEST(cx, obj, hook, args)                               \
   XPC_NW_BYPASS_BASE(cx, obj,                                                 \
     JSClass *clasp_ = STOBJ_GET_CLASS(obj);                                  \
     return !clasp_->hook || clasp_->hook args;                                \
   )
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_toString(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                 jsval *rval);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPCNativeWrapperCtor(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                      jsval *rval);
 
 static inline
 JSBool
 ThrowException(nsresult ex, JSContext *cx)
 {
   XPCThrower::Throw(ex, cx);
@@ -271,17 +271,17 @@ XPC_NW_WrapFunction(JSContext* cx, JSObj
   }
 
   JSObject* funWrapperObj = ::JS_GetFunctionObject(funWrapper);
   ::JS_SetParent(cx, funWrapperObj, funobj);
   *rval = OBJECT_TO_JSVAL(funWrapperObj);
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_AddProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   JSProperty *prop;
   JSObject *pobj;
   jsid idAsId;
 
   if (!::JS_ValueToId(cx, id, &idAsId) ||
       !OBJ_LOOKUP_PROPERTY(cx, obj, idAsId, &pobj, &prop)) {
@@ -305,17 +305,17 @@ XPC_NW_AddProperty(JSContext *cx, JSObje
   }
 
   // Note: no need to protect *vp from GC here, since it's already in the slot
   // on |obj|.
   return EnsureLegalActivity(cx, obj) &&
          XPC_NW_RewrapIfDeepWrapper(cx, obj, *vp, vp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_DelProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   if (!EnsureLegalActivity(cx, obj)) {
     return JS_FALSE;
   }
 
   XPC_NW_BYPASS_BASE(cx, obj,
     // We're being notified of a delete operation on id in this
@@ -410,17 +410,17 @@ XPC_NW_RewrapIfDeepWrapper(JSContext *cx
     *rval = OBJECT_TO_JSVAL(wrapperObj);
   } else {
     *rval = v;
   }
 
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_FunctionWrapper(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                        jsval *rval)
 {
   JSObject *funObj = JSVAL_TO_OBJECT(argv[-2]);
   if (!::JS_ObjectIsFunction(cx, funObj)) {
     obj = nsnull;
   }
 
@@ -526,29 +526,29 @@ XPC_NW_GetOrSetProperty(JSContext *cx, J
 
     return XPC_SJOW_Construct(cx, nsnull, 1, &nativeVal, vp);
   }
 
   return XPCWrapper::GetOrSetNativeProperty(cx, obj, wrappedNative, id, vp,
                                             aIsSet, JS_TRUE);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_GetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   return XPC_NW_GetOrSetProperty(cx, obj, id, vp, PR_FALSE);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_SetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   return XPC_NW_GetOrSetProperty(cx, obj, id, vp, PR_TRUE);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_Enumerate(JSContext *cx, JSObject *obj)
 {
   // We are being notified of a for-in loop or similar operation on this
   // XPCNativeWrapper, so forward to the correct high-level object hook,
   // OBJ_ENUMERATE on the XPCWrappedNative's object, called via the
   // JS_Enumerate API.  Then reflect properties named by the enumerated
   // identifiers from the wrapped native to the native wrapper.
 
@@ -559,17 +559,17 @@ XPC_NW_Enumerate(JSContext *cx, JSObject
   XPCWrappedNative *wn = XPCNativeWrapper::GetWrappedNative(obj);
   if (!wn) {
     return JS_TRUE;
   }
 
   return XPCWrapper::Enumerate(cx, obj, wn->GetFlatJSObject());
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_NewResolve(JSContext *cx, JSObject *obj, jsval id, uintN flags,
                   JSObject **objp)
 {
   // No need to preserve on sets of wrappedJSObject or toString, since callers
   // couldn't get at those values anyway.  Also, we always deal with
   // wrappedJSObject and toString before looking at our scriptable hooks, so no
   // need to mess with our flags yet.
   if (id == GetRTStringByIndex(cx, XPCJSRuntime::IDX_WRAPPED_JSOBJECT)) {
@@ -639,42 +639,42 @@ XPC_NW_NewResolve(JSContext *cx, JSObjec
   }
 
   return XPCWrapper::ResolveNativeProperty(cx, obj,
                                            wrappedNative->GetFlatJSObject(),
                                            wrappedNative, id, flags, objp,
                                            JS_TRUE);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_Convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp)
 {
   if (!EnsureLegalActivity(cx, obj)) {
     return JS_FALSE;
   }
 
   XPC_NW_BYPASS(cx, obj, convert, (cx, obj, type, vp));
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_NW_Finalize(JSContext *cx, JSObject *obj)
 {
   // We must not use obj's private data here since it's likely that it
   // has already been finalized.
   XPCJSRuntime *rt = nsXPConnect::GetRuntime();
 
   {
     // scoped lock
     XPCAutoLock lock(rt->GetMapLock());
     rt->GetExplicitNativeWrapperMap()->Remove(obj);
   }
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_CheckAccess(JSContext *cx, JSObject *obj, jsval id,
                    JSAccessMode mode, jsval *vp)
 {
   // Prevent setting __proto__ on an XPCNativeWrapper
   if ((mode & JSACC_WATCH) == JSACC_PROTO && (mode & JSACC_WRITE)) {
     return ThrowException(NS_ERROR_XPC_SECURITY_MANAGER_VETO, cx);
   }
 
@@ -692,17 +692,17 @@ XPC_NW_CheckAccess(JSContext *cx, JSObje
 
   JSObject *wrapperJSObject = wrappedNative->GetFlatJSObject();
 
   JSClass *clazz = STOBJ_GET_CLASS(wrapperJSObject);
   return !clazz->checkAccess ||
     clazz->checkAccess(cx, wrapperJSObject, id, mode, vp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_Call(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   if (!XPCNativeWrapper::IsNativeWrapper(obj)) {
     // If obj is not an XPCNativeWrapper, then someone's probably trying to call
     // our prototype (i.e., XPCNativeWrapper.prototype()). In this case, it is
     // safe to simply ignore the call, since that's what would happen anyway.
 
 #ifdef DEBUG
@@ -713,17 +713,17 @@ XPC_NW_Call(JSContext *cx, JSObject *obj
     return JS_TRUE;
   }
 
   XPC_NW_BYPASS_TEST(cx, obj, call, (cx, obj, argc, argv, rval));
 
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_Construct(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                  jsval *rval)
 {
   // The object given to us by the JS engine is actually a stub object (the
   // "new" object). This isn't any help to us, so instead use the function
   // object of the constructor that we're calling (which is the native
   // wrapper).
   obj = JSVAL_TO_OBJECT(argv[-2]);
@@ -754,17 +754,17 @@ XPC_NW_Construct(JSContext *cx, JSObject
 
   if (JSVAL_IS_PRIMITIVE(*rval)) {
     return ThrowException(NS_ERROR_ILLEGAL_VALUE, cx);
   }
 
   return XPC_NW_RewrapIfDeepWrapper(cx, obj, *rval, rval);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_HasInstance(JSContext *cx, JSObject *obj, jsval v, JSBool *bp)
 {
   XPC_NW_BYPASS_TEST(cx, obj, hasInstance, (cx, obj, v, bp));
 
   return JS_TRUE;
 }
 
 static JSBool
@@ -780,17 +780,17 @@ MirrorWrappedNativeParent(JSContext *cx,
 
     *result = XPCNativeWrapper::GetNewOrUsed(cx, parent_wrapper, nsnull);
     if (!*result)
       return JS_FALSE;
   }
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPCNativeWrapperCtor(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                      jsval *rval)
 {
   if (argc < 1) {
     return ThrowException(NS_ERROR_XPC_NOT_ENOUGH_ARGS, cx);
   }
 
   // |obj| almost always has the wrong proto and parent so we have to create
@@ -970,28 +970,28 @@ XPCNativeWrapperCtor(JSContext *cx, JSOb
     // scoped lock
     XPCAutoLock lock(rt->GetMapLock());
     rt->GetExplicitNativeWrapperMap()->Add(wrapperObj);
   }
 
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_NW_Trace(JSTracer *trc, JSObject *obj)
 {
   XPCWrappedNative *wrappedNative = XPCNativeWrapper::GetWrappedNative(obj);
 
   if (wrappedNative && wrappedNative->IsValid()) {
     JS_CALL_OBJECT_TRACER(trc, wrappedNative->GetFlatJSObject(),
                           "wrappedNative.flatJSObject");
   }
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_Equality(JSContext *cx, JSObject *obj, jsval v, JSBool *bp)
 {
   NS_ASSERTION(XPCNativeWrapper::IsNativeWrapper(obj),
                "Uh, we should only ever be called for XPCNativeWrapper "
                "objects!");
 
   if (JSVAL_IS_PRIMITIVE(v)) {
     *bp = JS_FALSE;
@@ -1015,17 +1015,17 @@ XPC_NW_Equality(JSContext *cx, JSObject 
 
     *bp = (obj == other ||
            XPC_GetIdentityObject(cx, obj) == XPC_GetIdentityObject(cx, other));
   }
 
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_NW_toString(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                 jsval *rval)
 {
   while (!XPCNativeWrapper::IsNativeWrapper(obj)) {
     obj = STOBJ_GET_PROTO(obj);
     if (!obj) {
       return ThrowException(NS_ERROR_UNEXPECTED, cx);
     }
@@ -1173,17 +1173,17 @@ XPCNativeWrapper::GetNewOrUsed(JSContext
 }
 
 struct WrapperAndCxHolder
 {
     XPCWrappedNative* wrapper;
     JSContext* cx;
 };
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 ClearNativeWrapperScope(JSDHashTable *table, JSDHashEntryHdr *hdr,
                         uint32 number, void *arg)
 {
     JSDHashEntryStub* entry = (JSDHashEntryStub*)hdr;
     WrapperAndCxHolder* d = (WrapperAndCxHolder*)arg;
 
     if (d->wrapper->GetWrapper() == (JSObject*)entry->key)
     {
--- a/js/src/xpconnect/src/XPCSafeJSObjectWrapper.cpp
+++ b/js/src/xpconnect/src/XPCSafeJSObjectWrapper.cpp
@@ -37,60 +37,60 @@
  *
  * ***** END LICENSE BLOCK ***** */
 
 #include "xpcprivate.h"
 #include "jsdbgapi.h"
 #include "jsscript.h" // for js_ScriptClass
 #include "XPCWrapper.h"
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_AddProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_DelProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_GetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_SetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_Enumerate(JSContext *cx, JSObject *obj);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_NewResolve(JSContext *cx, JSObject *obj, jsval id, uintN flags,
                     JSObject **objp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_Convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_SJOW_Finalize(JSContext *cx, JSObject *obj);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_CheckAccess(JSContext *cx, JSObject *obj, jsval id, JSAccessMode mode,
                      jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_Call(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
               jsval *rval);
 
 JSBool
 XPC_SJOW_Construct(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                    jsval *rval);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_Equality(JSContext *cx, JSObject *obj, jsval v, JSBool *bp);
 
-JS_STATIC_DLL_CALLBACK(JSObject *)
+static JSObject *
 XPC_SJOW_Iterator(JSContext *cx, JSObject *obj, JSBool keysonly);
 
-JS_STATIC_DLL_CALLBACK(JSObject *)
+static JSObject *
 XPC_SJOW_WrappedObject(JSContext *cx, JSObject *obj);
 
 static inline
 JSBool
 ThrowException(nsresult ex, JSContext *cx)
 {
   XPCThrower::Throw(ex, cx);
 
@@ -203,17 +203,17 @@ JSExtendedClass sXPC_SJOW_JSClass = {
   XPC_SJOW_Equality,
   nsnull, // outerObject
   nsnull, // innerObject
   XPC_SJOW_Iterator,
   XPC_SJOW_WrappedObject,
   JSCLASS_NO_RESERVED_MEMBERS
 };
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_toString(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                   jsval *rval);
 
 // Reserved slot indexes on safe wrappers.
 
 // Boolean value, initialized to false on object creation and true
 // only while we're resolving a property on the object.
 #define XPC_SJOW_SLOT_IS_RESOLVING           0
@@ -457,17 +457,17 @@ GetScriptedFunction(JSContext *cx, JSObj
       return JS_FALSE;
     }
   }
 
   return JS_TRUE;
 }
 
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_AddProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   // The constructor and toString properties needs to live on the safe
   // wrapper.
   if (id == GetRTStringByIndex(cx, XPCJSRuntime::IDX_CONSTRUCTOR) ||
       id == GetRTStringByIndex(cx, XPCJSRuntime::IDX_TO_STRING)) {
     return JS_TRUE;
   }
@@ -493,17 +493,17 @@ XPC_SJOW_AddProperty(JSContext *cx, JSOb
   if (!CanCallerAccess(cx, unsafeObj)) {
     // CanCallerAccess() already threw for us.
     return JS_FALSE;
   }
 
   return XPCWrapper::AddProperty(cx, obj, unsafeObj, id, vp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_DelProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   JSObject *unsafeObj = GetUnsafeObject(obj);
   if (!unsafeObj) {
     return ThrowException(NS_ERROR_UNEXPECTED, cx);
   }
 
   // Check that the caller can access the unsafe object.
@@ -514,17 +514,17 @@ XPC_SJOW_DelProperty(JSContext *cx, JSOb
 
   return XPCWrapper::DelProperty(cx, unsafeObj, id, vp);
 }
 
 // Call wrapper to help with wrapping calls to functions or callable
 // objects in a scripted function (see XPC_SJOW_Call()). The first
 // argument passed to this method is the unsafe function to call, the
 // rest are the arguments to pass to the function we're calling.
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_CallWrapper(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                      jsval *rval)
 {
   // Make sure we've got at least one argument (which may not be the
   // case if someone's monkeying with this function directly from JS).
   if (argc < 1) {
     return ThrowException(NS_ERROR_INVALID_ARG, cx);
   }
@@ -582,29 +582,29 @@ XPC_SJOW_GetOrSetProperty(JSContext *cx,
 
   jsval val;
   JSBool ok = ::JS_CallFunctionValue(cx, unsafeObj, scriptedFunVal,
                                      aIsSet ? 2 : 1, args, &val);
 
   return ok && WrapJSValue(cx, obj, val, vp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_GetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   return XPC_SJOW_GetOrSetProperty(cx, obj, id, vp, PR_FALSE);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_SetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   return XPC_SJOW_GetOrSetProperty(cx, obj, id, vp, PR_TRUE);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_Enumerate(JSContext *cx, JSObject *obj)
 {
   obj = FindSafeObject(obj);
   NS_ASSERTION(obj != nsnull, "FindSafeObject() returned null in class hook!");
 
   // We are being notified of a for-in loop or similar operation on
   // this XPCSafeJSObjectWrapper. Forward to the correct high-level
   // object hook, OBJ_ENUMERATE on the unsafe object, called via the
@@ -626,17 +626,17 @@ XPC_SJOW_Enumerate(JSContext *cx, JSObje
   // Since we enumerate using JS_Enumerate() on the unsafe object here
   // we don't need to do a security check since JS_Enumerate() will
   // look up unsafeObj.__iterator__ and if we don't have permission to
   // access that, it'll throw and we'll be safe.
 
   return XPCWrapper::Enumerate(cx, obj, unsafeObj);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_NewResolve(JSContext *cx, JSObject *obj, jsval id, uintN flags,
                     JSObject **objp)
 {
   obj = FindSafeObject(obj);
   NS_ASSERTION(obj != nsnull, "FindSafeObject() returned null in class hook!");
 
   JSObject *unsafeObj = GetUnsafeObject(obj);
   if (!unsafeObj) {
@@ -656,37 +656,37 @@ XPC_SJOW_NewResolve(JSContext *cx, JSObj
     *objp = obj;
     return JS_DefineFunction(cx, obj, "toString",
                              XPC_SJOW_toString, 0, 0) != nsnull;
   }
 
   return XPCWrapper::NewResolve(cx, obj, unsafeObj, id, flags, objp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_Convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp)
 {
   NS_ASSERTION(type != JSTYPE_STRING, "toString failed us");
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_SJOW_Finalize(JSContext *cx, JSObject *obj)
 {
   // Release the reference to the cached principal if we have one.
   jsval v;
   if (::JS_GetReservedSlot(cx, obj, XPC_SJOW_SLOT_PRINCIPAL, &v) &&
       !JSVAL_IS_VOID(v)) {
     nsIPrincipal *principal = (nsIPrincipal *)JSVAL_TO_PRIVATE(v);
 
     NS_RELEASE(principal);
   }
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_CheckAccess(JSContext *cx, JSObject *obj, jsval id,
                      JSAccessMode mode, jsval *vp)
 {
   // Prevent setting __proto__ on an XPCSafeJSObjectWrapper
   if ((mode & JSACC_WATCH) == JSACC_PROTO && (mode & JSACC_WRITE)) {
     return ThrowException(NS_ERROR_XPC_SECURITY_MANAGER_VETO, cx);
   }
 
@@ -709,17 +709,17 @@ XPC_SJOW_CheckAccess(JSContext *cx, JSOb
     return JS_FALSE;
   }
 
   JSClass *clazz = STOBJ_GET_CLASS(unsafeObj);
   return !clazz->checkAccess ||
     clazz->checkAccess(cx, unsafeObj, id, mode, vp);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_Call(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
               jsval *rval)
 {
   JSObject *tmp = FindSafeObject(obj);
   JSObject *unsafeObj, *callThisObj = nsnull;
 
   if (tmp) {
     // A function wrapped in an XPCSafeJSObjectWrapper is being called
@@ -940,17 +940,17 @@ XPC_SJOW_Construct(JSContext *cx, JSObje
     return JS_FALSE;
   }
 
   *rval = OBJECT_TO_JSVAL(wrapperObj);
 
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_Equality(JSContext *cx, JSObject *obj, jsval v, JSBool *bp)
 {
   if (JSVAL_IS_PRIMITIVE(v)) {
     *bp = JS_FALSE;
   } else {
     JSObject *unsafeObj = GetUnsafeObject(obj);
 
     JSObject *other = JSVAL_TO_OBJECT(v);
@@ -971,17 +971,17 @@ XPC_SJOW_Equality(JSContext *cx, JSObjec
 
       *bp = objIdentity && objIdentity == otherIdentity;
     }
   }
 
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSObject *)
+static JSObject *
 XPC_SJOW_Iterator(JSContext *cx, JSObject *obj, JSBool keysonly)
 {
   obj = FindSafeObject(obj);
   NS_ASSERTION(obj != nsnull, "FindSafeObject() returned null in class hook!");
 
   JSObject *unsafeObj = GetUnsafeObject(obj);
   if (!unsafeObj) {
     ThrowException(NS_ERROR_INVALID_ARG, cx);
@@ -1010,23 +1010,23 @@ XPC_SJOW_Iterator(JSContext *cx, JSObjec
 
   JSAutoTempValueRooter tvr(cx, OBJECT_TO_JSVAL(wrapperIter));
 
   // Initialize the wrapper.
   return XPCWrapper::CreateIteratorObj(cx, wrapperIter, obj, unsafeObj,
                                        keysonly);
 }
 
-JS_STATIC_DLL_CALLBACK(JSObject *)
+static JSObject *
 XPC_SJOW_WrappedObject(JSContext *cx, JSObject *obj)
 {
   return GetUnsafeObject(obj);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_SJOW_toString(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                   jsval *rval)
 {
   obj = FindSafeObject(obj);
   if (!obj) {
     return ThrowException(NS_ERROR_INVALID_ARG, cx);
   }
 
--- a/js/src/xpconnect/src/XPCWrapper.cpp
+++ b/js/src/xpconnect/src/XPCWrapper.cpp
@@ -50,29 +50,29 @@ const PRUint32
 XPCWrapper::sResolvingSlot = 0;
 
 const PRUint32
 XPCWrapper::sNumSlots = 2;
 
 JSNative
 XPCWrapper::sEvalNative = nsnull;
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 IteratorFinalize(JSContext *cx, JSObject *obj)
 {
   jsval v;
   JS_GetReservedSlot(cx, obj, 0, &v);
 
   JSIdArray *ida = reinterpret_cast<JSIdArray *>(JSVAL_TO_PRIVATE(v));
   if (ida) {
     JS_DestroyIdArray(cx, ida);
   }
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 IteratorNext(JSContext *cx, uintN argc, jsval *vp)
 {
   JSObject *obj;
   jsval v;
  
   obj = JS_THIS_OBJECT(cx, vp);
   if (!obj)
     return JS_FALSE;
--- a/js/src/xpconnect/src/nsXPConnect.cpp
+++ b/js/src/xpconnect/src/nsXPConnect.cpp
@@ -420,17 +420,17 @@ nsXPConnect::GetInfoForName(const char *
 static JSGCCallback gOldJSGCCallback;
 // Whether cycle collection was run.
 static PRBool gDidCollection;
 // Whether starting cycle collection was successful.
 static PRBool gInCollection;
 // Whether cycle collection collected anything.
 static PRBool gCollected;
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPCCycleCollectGCCallback(JSContext *cx, JSGCStatus status)
 {
     // Launch the cycle collector.
     if(status == JSGC_MARK_END)
     {
         // This is the hook between marking and sweeping in the JS GC. Do cycle
         // collection.
         if(!gDidCollection)
@@ -549,17 +549,17 @@ struct NoteJSRootTracer : public JSTrace
       : mObjects(aObjects),
         mCb(cb)
     {
     }
     PLDHashTable* mObjects;
     nsCycleCollectionTraversalCallback& mCb;
 };
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 NoteJSRoot(JSTracer *trc, void *thing, uint32 kind)
 {
     if(ADD_TO_CC(kind))
     {
         NoteJSRootTracer *tracer = static_cast<NoteJSRootTracer*>(trc);
         PLDHashEntryHdr *entry = PL_DHashTableOperate(tracer->mObjects, thing,
                                                       PL_DHASH_ADD);
         if(entry && !reinterpret_cast<PLDHashEntryStub*>(entry)->key)
@@ -714,17 +714,17 @@ nsXPConnect::Unroot(void *p)
 struct TraversalTracer : public JSTracer
 {
     TraversalTracer(nsCycleCollectionTraversalCallback &aCb) : cb(aCb)
     {
     }
     nsCycleCollectionTraversalCallback &cb;
 };
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 NoteJSChild(JSTracer *trc, void *thing, uint32 kind)
 {
     if(ADD_TO_CC(kind))
     {
         TraversalTracer *tracer = static_cast<TraversalTracer*>(trc);
 #if defined(DEBUG) && defined(DEBUG_CC)
         // based on DumpNotify in jsapi.c
         if (tracer->debugPrinter) {
@@ -1108,17 +1108,17 @@ nsXPConnect::InitClasses(JSContext * aJS
         return UnexpectedFailure(NS_ERROR_FAILURE);
 
     if (!XPC_SJOW_AttachNewConstructorObject(ccx, aGlobalJSObj))
         return UnexpectedFailure(NS_ERROR_FAILURE);
 
     return NS_OK;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 TempGlobalResolve(JSContext *aJSContext, JSObject *obj, jsval id)
 {
     JSBool resolved;
     return JS_ResolveStandardClass(aJSContext, obj, id, &resolved);
 }
 
 static JSClass xpcTempGlobalClass = {
     "xpcTempGlobalClass", 0,
@@ -1401,17 +1401,17 @@ nsXPConnect::ReparentWrappedNativeIfFoun
     if(!scope2)
         return UnexpectedFailure(NS_ERROR_FAILURE);
 
     return XPCWrappedNative::
         ReparentWrapperIfFound(ccx, scope, scope2, aNewParent, aCOMObj,
                                (XPCWrappedNative**) _retval);
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 MoveableWrapperFinder(JSDHashTable *table, JSDHashEntryHdr *hdr,
                       uint32 number, void *arg)
 {
     // Every element counts.
     nsVoidArray *va = static_cast<nsVoidArray *>(arg);
     va->AppendElement(((Native2WrappedNativeMap::Entry*)hdr)->value);
     return JS_DHASH_NEXT;
 }
--- a/js/src/xpconnect/src/xpccomponents.cpp
+++ b/js/src/xpconnect/src/xpccomponents.cpp
@@ -2964,17 +2964,17 @@ const char kScriptSecurityManagerContrac
 NS_IMPL_THREADSAFE_ISUPPORTS1(PrincipalHolder, nsIScriptObjectPrincipal)
 
 nsIPrincipal *
 PrincipalHolder::GetPrincipal()
 {
     return mHoldee;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 SandboxDump(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     JSString *str;
     if (!argc)
         return JS_TRUE;
 
     str = JS_ValueToString(cx, argv[0]);
     if (!str)
@@ -2983,44 +2983,44 @@ SandboxDump(JSContext *cx, JSObject *obj
     char *bytes = JS_GetStringBytes(str);
     if (!bytes)
         return JS_FALSE;
 
     fputs(bytes, stderr);
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 SandboxDebug(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
 #ifdef DEBUG
     return SandboxDump(cx, obj, argc, argv, rval);
 #else
     return JS_TRUE;
 #endif
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 SandboxFunForwarder(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                     jsval *rval)
 {
     jsval v;
     if (!JS_GetReservedSlot(cx, JSVAL_TO_OBJECT(argv[-2]), 0, &v) ||
         !JS_CallFunctionValue(cx, obj, v, argc, argv, rval)) {
         return JS_FALSE;
     }
 
     if (JSVAL_IS_PRIMITIVE(*rval))
         return JS_TRUE; // nothing more to do.
     
     XPCThrower::Throw(NS_ERROR_NOT_IMPLEMENTED, cx);
     return JS_FALSE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 SandboxImport(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
               jsval *rval)
 {
     if (argc < 1) {
         XPCThrower::Throw(NS_ERROR_INVALID_ARG, cx);
         return JS_FALSE;
     }
     
@@ -3076,30 +3076,30 @@ SandboxImport(JSContext *cx, JSObject *o
     if (!newfunobj)
         return JS_FALSE;
 
     // Functions come with two extra reserved slots on them. Use the 0-th slot
     // to communicate the wrapped function to our forwarder.
     return JS_SetReservedSlot(cx, newfunobj, 0, argv[0]);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 sandbox_enumerate(JSContext *cx, JSObject *obj)
 {
     return JS_EnumerateStandardClasses(cx, obj);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 sandbox_resolve(JSContext *cx, JSObject *obj, jsval id)
 {
     JSBool resolved;
     return JS_ResolveStandardClass(cx, obj, id, &resolved);
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 sandbox_finalize(JSContext *cx, JSObject *obj)
 {
     nsIScriptObjectPrincipal *sop =
         (nsIScriptObjectPrincipal *)xpc_GetJSPrivate(obj);
     NS_IF_RELEASE(sop);
 }
 
 static JSClass SandboxClass = {
@@ -3339,17 +3339,17 @@ public:
     JSContext * GetJSContext()
     {
         return mJSContext;
     }
 
     NS_DECL_ISUPPORTS
 
 private:
-    static JSBool JS_DLL_CALLBACK ContextHolderOperationCallback(JSContext *cx);
+    static JSBool ContextHolderOperationCallback(JSContext *cx);
     
     XPCAutoJSContext mJSContext;
     JSContext* mOrigCx;
 };
 
 NS_IMPL_ISUPPORTS0(ContextHolder)
 
 ContextHolder::ContextHolder(JSContext *aOuterCx, JSObject *aSandbox)
@@ -3367,17 +3367,17 @@ ContextHolder::ContextHolder(JSContext *
         if(JS_GetOperationCallback(aOuterCx))
         {
             JS_SetOperationCallback(mJSContext, ContextHolderOperationCallback,
                                     JS_GetOperationLimit(aOuterCx));
         }
     }
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 ContextHolder::ContextHolderOperationCallback(JSContext *cx)
 {
     ContextHolder* thisObject =
         static_cast<ContextHolder*>(JS_GetContextPrivate(cx));
     NS_ASSERTION(thisObject, "How did that happen?");
 
     JSContext *origCx = thisObject->mOrigCx;
     JSOperationCallback callback = JS_GetOperationCallback(origCx);
--- a/js/src/xpconnect/src/xpcconvert.cpp
+++ b/js/src/xpconnect/src/xpcconvert.cpp
@@ -160,17 +160,17 @@ XPCConvert::GetISupportsFromJSObject(JSO
         *iface = (nsISupports*) xpc_GetJSPrivate(obj);
         return JS_TRUE;
     }
     return JS_FALSE;
 }
 
 /***************************************************************************/
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 FinalizeXPCOMUCString(JSContext *cx, JSString *str)
 {
     NS_ASSERTION(sXPCOMUCStringFinalizerIndex != -1,
                  "XPCConvert: XPCOM Unicode string finalizer called uninitialized!");
 
     jschar* buffer = JS_GetStringChars(str);
     nsMemory::Free(buffer);
 }
@@ -1640,17 +1640,17 @@ XPCConvert::JSErrorToXPCException(XPCCal
 #define VARARGS_ASSIGN(foo, bar)	foo[0] = bar[0]
 #else
 #define VARARGS_ASSIGN(foo, bar)	(foo) = (bar)
 #endif
 
 // We assert below that these formats all begin with "%i".
 const char* XPC_ARG_FORMATTER_FORMAT_STRINGS[] = {"%ip", "%iv", "%is", nsnull};
 
-JSBool JS_DLL_CALLBACK
+JSBool
 XPC_JSArgumentFormatter(JSContext *cx, const char *format,
                         JSBool fromJS, jsval **vpp, va_list *app)
 {
     XPCCallContext ccx(NATIVE_CALLER, cx);
     if(!ccx.IsValid())
         return JS_FALSE;
 
     jsval *vp;
--- a/js/src/xpconnect/src/xpcdebug.cpp
+++ b/js/src/xpconnect/src/xpcdebug.cpp
@@ -300,17 +300,17 @@ xpc_DumpJSStack(JSContext* cx, JSBool sh
     }
     else
         puts("Failed to format JavaScript stack for dump");
     return JS_TRUE;
 }
 
 /***************************************************************************/
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 xpcDumpEvalErrorReporter(JSContext *cx, const char *message,
                          JSErrorReport *report)
 {
     printf("Error: %s\n", message);
 }
 
 JSBool
 xpc_DumpEvalInJSStackFrame(JSContext* cx, JSUint32 frameno, const char* text)
@@ -358,17 +358,17 @@ xpc_DumpEvalInJSStackFrame(JSContext* cx
         puts("eval failed!");
     JS_SetErrorReporter(cx, older);
     JS_RestoreExceptionState(cx, exceptionState);
     return JS_TRUE;
 }
 
 /***************************************************************************/
 
-JSTrapStatus JS_DLL_CALLBACK
+JSTrapStatus
 xpc_DebuggerKeywordHandler(JSContext *cx, JSScript *script, jsbytecode *pc,
                            jsval *rval, void *closure)
 {
     static const char line[] =
     "------------------------------------------------------------------------";
     puts(line);
     puts("Hit JavaScript \"debugger\" keyword. JS call stack...");
     xpc_DumpJSStack(cx, JS_TRUE, JS_TRUE, JS_FALSE);
--- a/js/src/xpconnect/src/xpcjsruntime.cpp
+++ b/js/src/xpconnect/src/xpcjsruntime.cpp
@@ -78,17 +78,17 @@ static JSGCCallback gOldJSGCCallback;
 
 // data holder class for the enumerator callback below
 struct JSDyingJSObjectData
 {
     JSContext* cx;
     nsVoidArray* array;
 };
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WrappedJSDyingJSObjectFinder(JSDHashTable *table, JSDHashEntryHdr *hdr,
                 uint32 number, void *arg)
 {
     JSDyingJSObjectData* data = (JSDyingJSObjectData*) arg;
     nsXPCWrappedJS* wrapper = ((JSObject2WrappedJSMap::Entry*)hdr)->value;
     NS_ASSERTION(wrapper, "found a null JS wrapper!");
 
     // walk the wrapper chain and find any whose JSObject is to be finalized
@@ -105,27 +105,27 @@ WrappedJSDyingJSObjectFinder(JSDHashTabl
 }
 
 struct CX_AND_XPCRT_Data
 {
     JSContext* cx;
     XPCJSRuntime* rt;
 };
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 NativeInterfaceGC(JSDHashTable *table, JSDHashEntryHdr *hdr,
                   uint32 number, void *arg)
 {
     CX_AND_XPCRT_Data* data = (CX_AND_XPCRT_Data*) arg;
     ((IID2NativeInterfaceMap::Entry*)hdr)->value->
             DealWithDyingGCThings(data->cx, data->rt);
     return JS_DHASH_NEXT;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 NativeInterfaceSweeper(JSDHashTable *table, JSDHashEntryHdr *hdr,
                        uint32 number, void *arg)
 {
     CX_AND_XPCRT_Data* data = (CX_AND_XPCRT_Data*) arg;
     XPCNativeInterface* iface = ((IID2NativeInterfaceMap::Entry*)hdr)->value;
     if(iface->IsMarked())
     {
         iface->Unmark();
@@ -141,27 +141,27 @@ NativeInterfaceSweeper(JSDHashTable *tab
     return JS_DHASH_REMOVE;
 }
 
 // *Some* NativeSets are referenced from mClassInfo2NativeSetMap.
 // *All* NativeSets are referenced from mNativeSetMap.
 // So, in mClassInfo2NativeSetMap we just clear references to the unmarked.
 // In mNativeSetMap we clear the references to the unmarked *and* delete them.
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 NativeUnMarkedSetRemover(JSDHashTable *table, JSDHashEntryHdr *hdr,
                          uint32 number, void *arg)
 {
     XPCNativeSet* set = ((ClassInfo2NativeSetMap::Entry*)hdr)->value;
     if(set->IsMarked())
         return JS_DHASH_NEXT;
     return JS_DHASH_REMOVE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 NativeSetSweeper(JSDHashTable *table, JSDHashEntryHdr *hdr,
                  uint32 number, void *arg)
 {
     XPCNativeSet* set = ((NativeSetMap::Entry*)hdr)->key_value;
     if(set->IsMarked())
     {
         set->Unmark();
         return JS_DHASH_NEXT;
@@ -176,17 +176,17 @@ NativeSetSweeper(JSDHashTable *table, JS
         printf("    %s\n",JS_GetStringBytes(JSVAL_TO_STRING(iface->GetName())));
     }
 #endif
 
     XPCNativeSet::DestroyInstance(set);
     return JS_DHASH_REMOVE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 JSClassSweeper(JSDHashTable *table, JSDHashEntryHdr *hdr,
                uint32 number, void *arg)
 {
     XPCNativeScriptableShared* shared =
         ((XPCNativeScriptableSharedMap::Entry*) hdr)->key;
     if(shared->IsMarked())
     {
 #ifdef off_XPC_REPORT_JSCLASS_FLUSHING
@@ -203,39 +203,39 @@ JSClassSweeper(JSDHashTable *table, JSDH
            shared->GetJSClass()->name,
            shared->GetJSClass());
 #endif
 
     delete shared;
     return JS_DHASH_REMOVE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 DyingProtoKiller(JSDHashTable *table, JSDHashEntryHdr *hdr,
                  uint32 number, void *arg)
 {
     XPCWrappedNativeProto* proto =
         (XPCWrappedNativeProto*)((JSDHashEntryStub*)hdr)->key;
     delete proto;
     return JS_DHASH_REMOVE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 DetachedWrappedNativeProtoMarker(JSDHashTable *table, JSDHashEntryHdr *hdr,
                                  uint32 number, void *arg)
 {
     XPCWrappedNativeProto* proto = 
         (XPCWrappedNativeProto*)((JSDHashEntryStub*)hdr)->key;
 
     proto->Mark();
     return JS_DHASH_NEXT;
 }
 
 // GCCallback calls are chained
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 ContextCallback(JSContext *cx, uintN operation)
 {
     XPCJSRuntime* self = nsXPConnect::GetRuntime();
     if (self)
     {
         if (operation == JSCONTEXT_NEW)
         {
             // Set the limits on the native and script stack space.
@@ -334,17 +334,17 @@ TraceJSObject(PRUint32 aLangID, void *aS
     if(aLangID == nsIProgrammingLanguage::JAVASCRIPT)
     {
         JS_CALL_TRACER(static_cast<JSTracer*>(aClosure), aScriptThing,
                        js_GetGCThingTraceKind(aScriptThing),
                        "JSObjectHolder");
     }
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 TraceJSHolder(JSDHashTable *table, JSDHashEntryHdr *hdr, uint32 number,
               void *arg)
 {
     ObjectHolder* entry = reinterpret_cast<ObjectHolder*>(hdr);
 
     entry->tracer->Trace(entry->holder, TraceJSObject, arg);
 
     return JS_DHASH_NEXT;
@@ -383,17 +383,17 @@ void XPCJSRuntime::TraceXPConnectRoots(J
 
     for(XPCRootSetElem *e = mWrappedJSRoots; e ; e = e->GetNextRoot())
         static_cast<nsXPCWrappedJS*>(e)->TraceJS(trc);
 
     if(mJSHolders.ops)
         JS_DHashTableEnumerate(&mJSHolders, TraceJSHolder, trc);
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 NoteJSHolder(JSDHashTable *table, JSDHashEntryHdr *hdr, uint32 number,
              void *arg)
 {
     ObjectHolder* entry = reinterpret_cast<ObjectHolder*>(hdr);
 
     nsCycleCollectionTraversalCallback* cb =
         static_cast<nsCycleCollectionTraversalCallback*>(arg);
     cb->NoteRoot(nsIProgrammingLanguage::CPLUSPLUS, entry->holder,
@@ -829,40 +829,40 @@ JSBool XPCJSRuntime::GCCallback(JSContex
 
     // always chain to old GCCallback if non-null.
     return gOldJSGCCallback ? gOldJSGCCallback(cx, status) : JS_TRUE;
 }
 
 /***************************************************************************/
 
 #ifdef XPC_CHECK_WRAPPERS_AT_SHUTDOWN
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 DEBUG_WrapperChecker(JSDHashTable *table, JSDHashEntryHdr *hdr,
                      uint32 number, void *arg)
 {
     XPCWrappedNative* wrapper = (XPCWrappedNative*)((JSDHashEntryStub*)hdr)->key;
     NS_ASSERTION(!wrapper->IsValid(), "found a 'valid' wrapper!");
     ++ *((int*)arg);
     return JS_DHASH_NEXT;
 }
 #endif
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WrappedJSShutdownMarker(JSDHashTable *table, JSDHashEntryHdr *hdr,
                         uint32 number, void *arg)
 {
     JSRuntime* rt = (JSRuntime*) arg;
     nsXPCWrappedJS* wrapper = ((JSObject2WrappedJSMap::Entry*)hdr)->value;
     NS_ASSERTION(wrapper, "found a null JS wrapper!");
     NS_ASSERTION(wrapper->IsValid(), "found an invalid JS wrapper!");
     wrapper->SystemIsBeingShutDown(rt);
     return JS_DHASH_NEXT;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 DetachedWrappedNativeProtoShutdownMarker(JSDHashTable *table, JSDHashEntryHdr *hdr,
                                          uint32 number, void *arg)
 {
     XPCWrappedNativeProto* proto = 
         (XPCWrappedNativeProto*)((JSDHashEntryStub*)hdr)->key;
 
     proto->SystemIsBeingShutDown((JSContext*)arg);
     return JS_DHASH_NEXT;
@@ -1144,17 +1144,17 @@ XPCJSRuntime::GetXPCContext(JSContext* c
 
     // else resync with the JSRuntime's JSContext list and see if it is found
     if(!xpcc)
         xpcc = SyncXPCContextList(cx);
     return xpcc;
 }
 
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 SweepContextsCB(JSDHashTable *table, JSDHashEntryHdr *hdr,
                 uint32 number, void *arg)
 {
     XPCContext* xpcc = ((JSContext2XPCContextMap::Entry*)hdr)->value;
     if(xpcc->IsMarked())
     {
         xpcc->Unmark();
         return JS_DHASH_NEXT;
@@ -1211,17 +1211,17 @@ XPCJSRuntime::SyncXPCContextList(JSConte
         else
             tls->ClearRecentContext();
     }
 
     return found;
 }
 
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 PurgeContextsCB(JSDHashTable *table, JSDHashEntryHdr *hdr,
                 uint32 number, void *arg)
 {
     delete ((JSContext2XPCContextMap::Entry*)hdr)->value;
     return JS_DHASH_REMOVE;
 }
 
 void
@@ -1265,38 +1265,38 @@ XPCJSRuntime::DeferredRelease(nsISupport
         mNativesToReleaseArray.SizeTo(256);
     }
     return mNativesToReleaseArray.AppendElement(obj);
 }
 
 /***************************************************************************/
 
 #ifdef DEBUG
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 ContextMapDumpEnumerator(JSDHashTable *table, JSDHashEntryHdr *hdr,
                          uint32 number, void *arg)
 {
     ((JSContext2XPCContextMap::Entry*)hdr)->value->DebugDump(*(PRInt16*)arg);
     return JS_DHASH_NEXT;
 }
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WrappedJSClassMapDumpEnumerator(JSDHashTable *table, JSDHashEntryHdr *hdr,
                                 uint32 number, void *arg)
 {
     ((IID2WrappedJSClassMap::Entry*)hdr)->value->DebugDump(*(PRInt16*)arg);
     return JS_DHASH_NEXT;
 }
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WrappedJSMapDumpEnumerator(JSDHashTable *table, JSDHashEntryHdr *hdr,
                            uint32 number, void *arg)
 {
     ((JSObject2WrappedJSMap::Entry*)hdr)->value->DebugDump(*(PRInt16*)arg);
     return JS_DHASH_NEXT;
 }
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 NativeSetDumpEnumerator(JSDHashTable *table, JSDHashEntryHdr *hdr,
                         uint32 number, void *arg)
 {
     ((NativeSetMap::Entry*)hdr)->key_value->DebugDump(*(PRInt16*)arg);
     return JS_DHASH_NEXT;
 }
 #endif
 
--- a/js/src/xpconnect/src/xpcmaps.cpp
+++ b/js/src/xpconnect/src/xpcmaps.cpp
@@ -44,32 +44,32 @@
 #include "jsbit.h"
 
 /***************************************************************************/
 // static shared...
 
 // Note this is returning the bit pattern of the first part of the nsID, not
 // the pointer to the nsID.
 
-static JSDHashNumber JS_DLL_CALLBACK
+static JSDHashNumber
 HashIIDPtrKey(JSDHashTable *table, const void *key)
 {
     return *((JSHashNumber*)key);
 }
 
-static JSBool JS_DLL_CALLBACK
+static JSBool
 MatchIIDPtrKey(JSDHashTable *table,
             const JSDHashEntryHdr *entry,
             const void *key)
 {
     return ((const nsID*)key)->
                 Equals(*((const nsID*)((JSDHashEntryStub*)entry)->key));
 }
 
-static JSDHashNumber JS_DLL_CALLBACK
+static JSDHashNumber
 HashNativeKey(JSDHashTable *table, const void *key)
 {
     XPCNativeSetKey* Key = (XPCNativeSetKey*) key;
 
     JSDHashNumber h = 0;
 
     XPCNativeSet*       Set;
     XPCNativeInterface* Addition;
@@ -322,17 +322,17 @@ ClassInfo2WrappedNativeProtoMap::~ClassI
 {
     if(mTable)
         JS_DHashTableDestroy(mTable);
 }
 
 /***************************************************************************/
 // implement NativeSetMap...
 
-JSBool JS_DLL_CALLBACK
+JSBool
 NativeSetMap::Entry::Match(JSDHashTable *table,
                            const JSDHashEntryHdr *entry,
                            const void *key)
 {
     XPCNativeSetKey* Key = (XPCNativeSetKey*) key;
 
     // See the comment in the XPCNativeSetKey declaration in xpcprivate.h.
     if(!Key->IsAKey())
@@ -437,25 +437,25 @@ NativeSetMap::~NativeSetMap()
 {
     if(mTable)
         JS_DHashTableDestroy(mTable);
 }
 
 /***************************************************************************/
 // implement IID2ThisTranslatorMap...
 
-JSBool JS_DLL_CALLBACK
+JSBool
 IID2ThisTranslatorMap::Entry::Match(JSDHashTable *table,
                                     const JSDHashEntryHdr *entry,
                                     const void *key)
 {
     return ((const nsID*)key)->Equals(((Entry*)entry)->key);
 }
 
-void JS_DLL_CALLBACK
+void
 IID2ThisTranslatorMap::Entry::Clear(JSDHashTable *table, JSDHashEntryHdr *entry)
 {
     NS_IF_RELEASE(((Entry*)entry)->value);
     memset(entry, 0, table->entrySize);
 }
 
 struct JSDHashTableOps IID2ThisTranslatorMap::Entry::sOps =
 {
@@ -487,34 +487,34 @@ IID2ThisTranslatorMap::IID2ThisTranslato
 IID2ThisTranslatorMap::~IID2ThisTranslatorMap()
 {
     if(mTable)
         JS_DHashTableDestroy(mTable);
 }
 
 /***************************************************************************/
 
-JSDHashNumber JS_DLL_CALLBACK
+JSDHashNumber
 XPCNativeScriptableSharedMap::Entry::Hash(JSDHashTable *table, const void *key)
 {
     JSDHashNumber h;
     const unsigned char *s;
 
     XPCNativeScriptableShared* obj =
         (XPCNativeScriptableShared*) key;
 
     // hash together the flags and the classname string
 
     h = (JSDHashNumber) obj->GetFlags();
     for (s = (const unsigned char*) obj->GetJSClass()->name; *s != '\0'; s++)
         h = JS_ROTATE_LEFT32(h, 4) ^ *s;
     return h;
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 XPCNativeScriptableSharedMap::Entry::Match(JSDHashTable *table,
                                          const JSDHashEntryHdr *entry,
                                          const void *key)
 {
     XPCNativeScriptableShared* obj1 =
         ((XPCNativeScriptableSharedMap::Entry*) entry)->key;
 
     XPCNativeScriptableShared* obj2 =
--- a/js/src/xpconnect/src/xpcmaps.h
+++ b/js/src/xpconnect/src/xpcmaps.h
@@ -452,17 +452,17 @@ private:
 
 class NativeSetMap
 {
 public:
     struct Entry : public JSDHashEntryHdr
     {
         XPCNativeSet* key_value;
 
-        static JSBool JS_DLL_CALLBACK
+        static JSBool
         Match(JSDHashTable *table,
               const JSDHashEntryHdr *entry,
               const void *key);
 
         static struct JSDHashTableOps sOps;
     };
 
     static NativeSetMap* newMap(int size);
@@ -521,22 +521,22 @@ private:
 class IID2ThisTranslatorMap
 {
 public:
     struct Entry : public JSDHashEntryHdr
     {
         nsIID                         key;
         nsIXPCFunctionThisTranslator* value;
 
-        static JSBool JS_DLL_CALLBACK
+        static JSBool
         Match(JSDHashTable *table,
               const JSDHashEntryHdr *entry,
               const void *key);
 
-        static void JS_DLL_CALLBACK
+        static void
         Clear(JSDHashTable *table, JSDHashEntryHdr *entry);
 
         static struct JSDHashTableOps sOps;
     };
 
     static IID2ThisTranslatorMap* newMap(int size);
 
     inline nsIXPCFunctionThisTranslator* Find(REFNSIID iid)
@@ -584,20 +584,20 @@ private:
 
 class XPCNativeScriptableSharedMap
 {
 public:
     struct Entry : public JSDHashEntryHdr
     {
         XPCNativeScriptableShared* key;
 
-        static JSDHashNumber JS_DLL_CALLBACK
+        static JSDHashNumber
         Hash(JSDHashTable *table, const void *key);
 
-        static JSBool JS_DLL_CALLBACK
+        static JSBool
         Match(JSDHashTable *table,
               const JSDHashEntryHdr *entry,
               const void *key);
 
         static struct JSDHashTableOps sOps;
     };
 
     static XPCNativeScriptableSharedMap* newMap(int size);
--- a/js/src/xpconnect/src/xpcprivate.h
+++ b/js/src/xpconnect/src/xpcprivate.h
@@ -704,22 +704,22 @@ public:
         return mStrJSVals[index];
     }
     const char* GetStringName(uintN index) const
     {
         NS_ASSERTION(index < IDX_TOTAL_COUNT, "index out of range");
         return mStrings[index];
     }
 
-    static void JS_DLL_CALLBACK TraceJS(JSTracer* trc, void* data);
+    static void TraceJS(JSTracer* trc, void* data);
     void TraceXPConnectRoots(JSTracer *trc);
     void AddXPConnectRoots(JSContext* cx,
                            nsCycleCollectionTraversalCallback& cb);
 
-    static JSBool JS_DLL_CALLBACK GCCallback(JSContext *cx, JSGCStatus status);
+    static JSBool GCCallback(JSContext *cx, JSGCStatus status);
 
     inline void AddVariantRoot(XPCTraceableVariant* variant);
     inline void AddWrappedJSRoot(nsXPCWrappedJS* wrappedJS);
     inline void AddObjectHolderRoot(XPCJSObjectHolder* holder);
 
     nsresult AddJSHolder(void* aHolder, nsScriptObjectTracer* aTracer);
     nsresult RemoveJSHolder(void* aHolder);
 
@@ -1166,30 +1166,30 @@ private:
 extern JSExtendedClass XPC_WN_NoHelper_JSClass;
 extern JSClass XPC_WN_NoMods_WithCall_Proto_JSClass;
 extern JSClass XPC_WN_NoMods_NoCall_Proto_JSClass;
 extern JSClass XPC_WN_ModsAllowed_WithCall_Proto_JSClass;
 extern JSClass XPC_WN_ModsAllowed_NoCall_Proto_JSClass;
 extern JSClass XPC_WN_Tearoff_JSClass;
 extern JSClass XPC_WN_NoHelper_Proto_JSClass;
 
-extern JSObjectOps * JS_DLL_CALLBACK
+extern JSObjectOps *
 XPC_WN_GetObjectOpsNoCall(JSContext *cx, JSClass *clazz);
 
-extern JSObjectOps * JS_DLL_CALLBACK
+extern JSObjectOps *
 XPC_WN_GetObjectOpsWithCall(JSContext *cx, JSClass *clazz);
 
-extern JSObjectOps * JS_DLL_CALLBACK
+extern JSObjectOps *
 XPC_WN_Proto_GetObjectOps(JSContext *cx, JSClass *clazz);
 
-extern JSBool JS_DLL_CALLBACK
+extern JSBool
 XPC_WN_CallMethod(JSContext *cx, JSObject *obj,
                   uintN argc, jsval *argv, jsval *vp);
 
-extern JSBool JS_DLL_CALLBACK
+extern JSBool
 XPC_WN_GetterSetter(JSContext *cx, JSObject *obj,
                     uintN argc, jsval *argv, jsval *vp);
 
 extern JSBool
 xpc_InitWrappedNativeJSOps();
 
 // Maybe this macro should check for class->enumerate ==
 // XPC_WN_Shared_Proto_Enumerate or something rather than checking for
@@ -2796,17 +2796,17 @@ public:
                                                           JSString *str);
 
     static void ShutdownDOMStringFinalizer();
 
 private:
     XPCStringConvert();         // not implemented
 };
 
-extern JSBool JS_DLL_CALLBACK
+extern JSBool
 XPC_JSArgumentFormatter(JSContext *cx, const char *format,
                         JSBool fromJS, jsval **vpp, va_list *app);
 
 
 /***************************************************************************/
 // code for throwing exceptions into JS
 
 class XPCThrower
--- a/js/src/xpconnect/src/xpcstring.cpp
+++ b/js/src/xpconnect/src/xpcstring.cpp
@@ -52,17 +52,17 @@
  * well as providing refcounting support.
  */
 
 #include "xpcprivate.h"
 #include "nsStringBuffer.h"
 
 static int sDOMStringFinalizerIndex = -1;
 
-static void JS_DLL_CALLBACK
+static void
 DOMStringFinalizer(JSContext *cx, JSString *str)
 {
     nsStringBuffer::FromData(JS_GetStringChars(str))->Release();
 }
 
 void
 XPCStringConvert::ShutdownDOMStringFinalizer()
 {
--- a/js/src/xpconnect/src/xpcthreadcontext.cpp
+++ b/js/src/xpconnect/src/xpcthreadcontext.cpp
@@ -148,24 +148,24 @@ XPCJSContextStack::DEBUG_StackHasJSConte
 {
     for(PRUint32 i = 0; i < mStack.Length(); i++)
         if(aJSContext == mStack[i].cx)
             return JS_TRUE;
     return JS_FALSE;
 }
 #endif
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 SafeGlobalResolve(JSContext *cx, JSObject *obj, jsval id)
 {
     JSBool resolved;
     return JS_ResolveStandardClass(cx, obj, id, &resolved);
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 SafeFinalize(JSContext* cx, JSObject* obj)
 {
 #ifndef XPCONNECT_STANDALONE
     nsIScriptObjectPrincipal* sop =
         static_cast<nsIScriptObjectPrincipal*>(xpc_GetJSPrivate(obj));
     NS_IF_RELEASE(sop);
 #endif
 }
--- a/js/src/xpconnect/src/xpcwrappedjsclass.cpp
+++ b/js/src/xpconnect/src/xpcwrappedjsclass.cpp
@@ -705,17 +705,17 @@ nsXPCWrappedJSClass::DelegatedQueryInter
 JSObject*
 nsXPCWrappedJSClass::GetRootJSObject(XPCCallContext& ccx, JSObject* aJSObj)
 {
     JSObject* result = CallQueryInterfaceOnJSObject(ccx, aJSObj,
                                                     NS_GET_IID(nsISupports));
     return result ? result : aJSObj;
 }
 
-void JS_DLL_CALLBACK
+void
 xpcWrappedJSErrorReporter(JSContext *cx, const char *message,
                           JSErrorReport *report)
 {
     if(report)
     {
         // If it is an exception report, then we can just deal with the
         // exception later (if not caught in the JS code).
         if(JSREPORT_IS_EXCEPTION(report->flags))
--- a/js/src/xpconnect/src/xpcwrappednativejsops.cpp
+++ b/js/src/xpconnect/src/xpcwrappednativejsops.cpp
@@ -114,27 +114,27 @@ ToStringGuts(XPCCallContext& ccx)
     }
 
     ccx.SetRetVal(STRING_TO_JSVAL(str));
     return JS_TRUE;
 }
 
 /***************************************************************************/
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Shared_ToString(JSContext *cx, JSObject *obj,
                        uintN argc, jsval *argv, jsval *vp)
 {
     XPCCallContext ccx(JS_CALLER, cx, obj);
     ccx.SetName(ccx.GetRuntime()->GetStringJSVal(XPCJSRuntime::IDX_TO_STRING));
     ccx.SetArgsAndResultPtr(argc, argv, vp);
     return ToStringGuts(ccx);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Shared_ToSource(JSContext *cx, JSObject *obj,
                        uintN argc, jsval *argv, jsval *vp)
 {
     static const char empty[] = "{}";
     *vp = STRING_TO_JSVAL(JS_NewStringCopyN(cx, empty, sizeof(empty)-1));
     return JS_TRUE;
 }
 
@@ -173,17 +173,17 @@ GetDoubleWrappedJSObject(XPCCallContext&
         }
     }
     return obj;
 }
 
 // This is the getter native function we use to handle 'wrappedJSObject' for
 // double wrapped JSObjects.
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_DoubleWrappedGetter(JSContext *cx, JSObject *obj,
                            uintN argc, jsval *argv, jsval *vp)
 {
     XPCCallContext ccx(JS_CALLER, cx, obj);
     XPCWrappedNative* wrapper = ccx.GetWrapper();
     THROW_AND_RETURN_IF_BAD_WRAPPER(cx, wrapper);
 
     NS_ASSERTION(JS_TypeOfValue(cx, argv[-2]) == JSTYPE_FUNCTION, "bad function");
@@ -486,40 +486,40 @@ DefinePropertyIfFound(XPCCallContext& cc
                                (JSPropertyOp) funobj,
                                (JSPropertyOp) funobj,
                                propFlags, nsnull);
 }
 
 /***************************************************************************/
 /***************************************************************************/
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_OnlyIWrite_PropertyStub(JSContext *cx, JSObject *obj, jsval idval, jsval *vp)
 {
     CHECK_IDVAL(cx, idval);
 
     XPCCallContext ccx(JS_CALLER, cx, obj, nsnull, idval);
     XPCWrappedNative* wrapper = ccx.GetWrapper();
     THROW_AND_RETURN_IF_BAD_WRAPPER(cx, wrapper);
 
     // Allow only XPConnect to add the property
     if(ccx.GetResolveName() == idval)
         return JS_TRUE;
 
     return Throw(NS_ERROR_XPC_CANT_MODIFY_PROP_ON_WN, cx);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_CannotModifyPropertyStub(JSContext *cx, JSObject *obj, jsval idval, jsval *vp)
 {
     CHECK_IDVAL(cx, idval);
     return Throw(NS_ERROR_XPC_CANT_MODIFY_PROP_ON_WN, cx);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Shared_Convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp)
 {
     if(type == JSTYPE_OBJECT)
     {
         *vp = OBJECT_TO_JSVAL(obj);
         return JS_TRUE;
     }
 
@@ -571,17 +571,17 @@ XPC_WN_Shared_Convert(JSContext *cx, JSO
         default:
             NS_ERROR("bad type in conversion");
             return JS_FALSE;
     }
     NS_NOTREACHED("huh?");
     return JS_FALSE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Shared_Enumerate(JSContext *cx, JSObject *obj)
 {
     XPCCallContext ccx(JS_CALLER, cx, obj);
     XPCWrappedNative* wrapper = ccx.GetWrapper();
     THROW_AND_RETURN_IF_BAD_WRAPPER(cx, wrapper);
 
     // Since we aren't going to enumerate tearoff names and the prototype
     // handles non-mutated members, we can do this potential short-circuit.
@@ -626,17 +626,17 @@ XPC_WN_Shared_Enumerate(JSContext *cx, J
                 return JS_FALSE;
         }
     }
     return JS_TRUE;
 }
 
 /***************************************************************************/
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_WN_NoHelper_Finalize(JSContext *cx, JSObject *obj)
 {
     XPCWrappedNative* p = (XPCWrappedNative*) xpc_GetJSPrivate(obj);
     if(!p)
         return;
     p->FlatJSObjectFinalized(cx);
 }
 
@@ -690,27 +690,27 @@ xpc_TraceForValidWrapper(JSTracer *trc, 
     // the interface set will never be accessed. But the JS engine will still
     // need to use the JSClass. So, some marking is required for protection.
 
     wrapper->TraceJS(trc);
      
     TraceScopeJSObjects(trc, wrapper->GetScope());
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_WN_Shared_Trace(JSTracer *trc, JSObject *obj)
 {
     XPCWrappedNative* wrapper =
         XPCWrappedNative::GetWrappedNativeOfJSObject(trc->context, obj);
 
     if(wrapper && wrapper->IsValid())
         xpc_TraceForValidWrapper(trc, wrapper);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_NoHelper_Resolve(JSContext *cx, JSObject *obj, jsval idval)
 {
     CHECK_IDVAL(cx, idval);
 
     XPCCallContext ccx(JS_CALLER, cx, obj, nsnull, idval);
     XPCWrappedNative* wrapper = ccx.GetWrapper();
     THROW_AND_RETURN_IF_BAD_WRAPPER(cx, wrapper);
 
@@ -746,17 +746,17 @@ XPC_GetIdentityObject(JSContext *cx, JSO
             return XPC_GetIdentityObject(cx, unsafeObj);
 
         return nsnull;
     }
 
     return wrapper->GetIdentityObject();
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Equality(JSContext *cx, JSObject *obj, jsval v, JSBool *bp)
 {
     *bp = JS_FALSE;
 
     XPCWrappedNative *wrapper =
         XPCWrappedNative::GetWrappedNativeOfJSObject(cx, obj);
     THROW_AND_RETURN_IF_BAD_WRAPPER(cx, wrapper);
 
@@ -784,17 +784,17 @@ XPC_WN_Equality(JSContext *cx, JSObject 
         *bp = (obj == other ||
                XPC_GetIdentityObject(cx, obj) ==
                XPC_GetIdentityObject(cx, other));
     }
 
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSObject *)
+static JSObject *
 XPC_WN_OuterObject(JSContext *cx, JSObject *obj)
 {
     XPCWrappedNative *wrapper =
         XPCWrappedNative::GetWrappedNativeOfJSObject(cx, obj);
     if(!wrapper)
     {
         Throw(NS_ERROR_XPC_BAD_OP_ON_WN_PROTO, cx);
 
@@ -823,17 +823,17 @@ XPC_WN_OuterObject(JSContext *cx, JSObje
         }
 
         obj = newThis;
     }
 
     return obj;
 }
 
-JS_STATIC_DLL_CALLBACK(JSObject *)
+static JSObject *
 XPC_WN_InnerObject(JSContext *cx, JSObject *obj)
 {
     XPCWrappedNative *wrapper =
         XPCWrappedNative::GetWrappedNativeOfJSObject(cx, obj);
     if(!wrapper)
     {
         Throw(NS_ERROR_XPC_BAD_OP_ON_WN_PROTO, cx);
 
@@ -900,17 +900,17 @@ JSExtendedClass XPC_WN_NoHelper_JSClass 
     XPC_WN_OuterObject,
     XPC_WN_InnerObject,
     nsnull,nsnull,nsnull,nsnull,nsnull
 };
 
 
 /***************************************************************************/
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_MaybeResolvingPropertyStub(JSContext *cx, JSObject *obj, jsval idval, jsval *vp)
 {
     CHECK_IDVAL(cx, idval);
     XPCCallContext ccx(JS_CALLER, cx, obj);
     XPCWrappedNative* wrapper = ccx.GetWrapper();
     THROW_AND_RETURN_IF_BAD_WRAPPER(cx, wrapper);
 
     if(ccx.GetResolvingWrapper() == wrapper)
@@ -926,125 +926,125 @@ XPC_WN_MaybeResolvingPropertyStub(JSCont
     PRBool retval = JS_TRUE;                                                 \
     nsresult rv = wrapper->GetScriptableCallback()->
 
 #define POST_HELPER_STUB                                                     \
     if(NS_FAILED(rv))                                                        \
         return Throw(rv, cx);                                                \
     return retval;
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Helper_AddProperty(JSContext *cx, JSObject *obj, jsval idval, jsval *vp)
 {
     PRE_HELPER_STUB
     AddProperty(wrapper, cx, obj, idval, vp, &retval);
     POST_HELPER_STUB
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Helper_DelProperty(JSContext *cx, JSObject *obj, jsval idval, jsval *vp)
 {
     PRE_HELPER_STUB
     DelProperty(wrapper, cx, obj, idval, vp, &retval);
     POST_HELPER_STUB
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Helper_GetProperty(JSContext *cx, JSObject *obj, jsval idval, jsval *vp)
 {
     PRE_HELPER_STUB
     GetProperty(wrapper, cx, obj, idval, vp, &retval);
     POST_HELPER_STUB
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Helper_SetProperty(JSContext *cx, JSObject *obj, jsval idval, jsval *vp)
 {
     PRE_HELPER_STUB
     SetProperty(wrapper, cx, obj, idval, vp, &retval);
     POST_HELPER_STUB
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Helper_Convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp)
 {
     PRE_HELPER_STUB
     Convert(wrapper, cx, obj, type, vp, &retval);
     POST_HELPER_STUB
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Helper_CheckAccess(JSContext *cx, JSObject *obj, jsval idval,
                           JSAccessMode mode, jsval *vp)
 {
     CHECK_IDVAL(cx, idval);
     PRE_HELPER_STUB
     CheckAccess(wrapper, cx, obj, idval, mode, vp, &retval);
     POST_HELPER_STUB
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Helper_Call(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                    jsval *rval)
 {
     // this is a hack to get the obj of the actual object not the object
     // that JS thinks is the 'this' (which it passes as 'obj').
     if(!(obj = (JSObject*)argv[-2]))
         return JS_FALSE;
 
     PRE_HELPER_STUB
     Call(wrapper, cx, obj, argc, argv, rval, &retval);
     POST_HELPER_STUB
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Helper_Construct(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                         jsval *rval)
 {
     // this is a hack to get the obj of the actual object not the object
     // that JS thinks is the 'this' (which it passes as 'obj').
     if(!(obj = (JSObject*)argv[-2]))
         return JS_FALSE;
 
     PRE_HELPER_STUB
     Construct(wrapper, cx, obj, argc, argv, rval, &retval);
     POST_HELPER_STUB
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Helper_HasInstance(JSContext *cx, JSObject *obj, jsval v, JSBool *bp)
 {
     PRE_HELPER_STUB
     HasInstance(wrapper, cx, obj, v, bp, &retval);
     POST_HELPER_STUB
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_WN_Helper_Finalize(JSContext *cx, JSObject *obj)
 {
     XPCWrappedNative* wrapper = (XPCWrappedNative*) xpc_GetJSPrivate(obj);
     if(!wrapper)
         return;
     wrapper->GetScriptableCallback()->Finalize(wrapper, cx, obj);
     wrapper->FlatJSObjectFinalized(cx);
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_WN_Helper_Trace(JSTracer *trc, JSObject *obj)
 {
     XPCWrappedNative* wrapper =
         XPCWrappedNative::GetWrappedNativeOfJSObject(trc->context, obj);
     if(wrapper && wrapper->IsValid())
     {
         wrapper->GetScriptableCallback()->Trace(wrapper, trc, obj);
         xpc_TraceForValidWrapper(trc, wrapper);
     }
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Helper_NewResolve(JSContext *cx, JSObject *obj, jsval idval, uintN flags,
                          JSObject **objp)
 {
     CHECK_IDVAL(cx, idval);
 
     XPCCallContext ccx(JS_CALLER, cx, obj);
     XPCWrappedNative* wrapper = ccx.GetWrapper();
     THROW_AND_RETURN_IF_BAD_WRAPPER(cx, wrapper);
@@ -1165,17 +1165,17 @@ static JSObjectOps XPC_WN_NoCall_JSOps;
 
     else //... if( helper wants NO enumerate )
         if( DONT_ENUM_STATICS )
             use enumerate stub - don't use this JSOp thing at all
         else
             do shared enumerate - don't use this JSOp thing at all
 */
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_JSOp_Enumerate(JSContext *cx, JSObject *obj, JSIterateOp enum_op,
                       jsval *statep, jsid *idp)
 {
     JSClass *clazz = STOBJ_GET_CLASS(obj);
     if(!IS_WRAPPER_CLASS(clazz) || clazz == &XPC_WN_NoHelper_JSClass.base)
     {
         // obj must be a prototype object or a wrapper w/o a
         // helper. Short circuit this call to
@@ -1245,17 +1245,17 @@ XPC_WN_JSOp_Enumerate(JSContext *cx, JSO
         }
     }
 
     // else call js_ObjectOps.enumerate...
 
     return js_ObjectOps.enumerate(cx, obj, enum_op, statep, idp);
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_WN_JSOp_Clear(JSContext *cx, JSObject *obj)
 {
     // We're likely to enter this JSOp with a wrapper prototype
     // object. In that case we won't find a wrapper, so we'll just
     // call into js_ObjectOps.clear(), which is exactly what we want.
 
     // If our scope is cleared, make sure we clear the scope of our
     // native wrapper as well.
@@ -1268,23 +1268,23 @@ XPC_WN_JSOp_Clear(JSContext *cx, JSObjec
 
         nsXPConnect* xpc = nsXPConnect::GetXPConnect();
         xpc->UpdateXOWs(cx, wrapper, nsIXPConnect::XPC_XOW_CLEARSCOPE);
     }
 
     js_ObjectOps.clear(cx, obj);
 }
 
-JSObjectOps * JS_DLL_CALLBACK
+JSObjectOps *
 XPC_WN_GetObjectOpsNoCall(JSContext *cx, JSClass *clazz)
 {
     return &XPC_WN_NoCall_JSOps;
 }
 
-JSObjectOps * JS_DLL_CALLBACK
+JSObjectOps *
 XPC_WN_GetObjectOpsWithCall(JSContext *cx, JSClass *clazz)
 {
     return &XPC_WN_WithCall_JSOps;
 }
 
 JSBool xpc_InitWrappedNativeJSOps()
 {
     if(!XPC_WN_NoCall_JSOps.newObjectMap)
@@ -1449,17 +1449,17 @@ XPCNativeScriptableShared::PopulateJSCla
     mJSClass.equality = XPC_WN_Equality;
     mJSClass.outerObject = XPC_WN_OuterObject;
     mJSClass.innerObject = XPC_WN_InnerObject;
 }
 
 /***************************************************************************/
 /***************************************************************************/
 
-JSBool JS_DLL_CALLBACK
+JSBool
 XPC_WN_CallMethod(JSContext *cx, JSObject *obj,
                   uintN argc, jsval *argv, jsval *vp)
 {
     NS_ASSERTION(JS_TypeOfValue(cx, argv[-2]) == JSTYPE_FUNCTION, "bad function");
     JSObject* funobj = JSVAL_TO_OBJECT(argv[-2]);
     XPCCallContext ccx(JS_CALLER, cx, obj, funobj, 0, argc, argv, vp);
     XPCWrappedNative* wrapper = ccx.GetWrapper();
     THROW_AND_RETURN_IF_BAD_WRAPPER(cx, wrapper);
@@ -1468,17 +1468,17 @@ XPC_WN_CallMethod(JSContext *cx, JSObjec
     XPCNativeMember*    member;
 
     if(!XPCNativeMember::GetCallInfo(ccx, funobj, &iface, &member))
         return Throw(NS_ERROR_XPC_CANT_GET_METHOD_INFO, cx);
     ccx.SetCallInfo(iface, member, JS_FALSE);
     return XPCWrappedNative::CallMethod(ccx);
 }
 
-JSBool JS_DLL_CALLBACK
+JSBool
 XPC_WN_GetterSetter(JSContext *cx, JSObject *obj,
                     uintN argc, jsval *argv, jsval *vp)
 {
     NS_ASSERTION(JS_TypeOfValue(cx, argv[-2]) == JSTYPE_FUNCTION, "bad function");
     JSObject* funobj = JSVAL_TO_OBJECT(argv[-2]);
 
     XPCCallContext ccx(JS_CALLER, cx, obj, funobj);
     XPCWrappedNative* wrapper = ccx.GetWrapper();
@@ -1502,17 +1502,17 @@ XPC_WN_GetterSetter(JSContext *cx, JSObj
     // else...
 
     ccx.SetCallInfo(iface, member, JS_FALSE);
     return XPCWrappedNative::GetAttribute(ccx);
 }
 
 /***************************************************************************/
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Shared_Proto_Enumerate(JSContext *cx, JSObject *obj)
 {
     NS_ASSERTION(
         JS_InstanceOf(cx, obj, &XPC_WN_ModsAllowed_WithCall_Proto_JSClass,
                       nsnull) ||
         JS_InstanceOf(cx, obj, &XPC_WN_ModsAllowed_NoCall_Proto_JSClass,
                       nsnull) ||
         JS_InstanceOf(cx, obj, &XPC_WN_NoMods_WithCall_Proto_JSClass, nsnull) ||
@@ -1547,45 +1547,45 @@ XPC_WN_Shared_Proto_Enumerate(JSContext 
             if(!xpc_ForcePropertyResolve(cx, obj, iface->GetMemberAt(k)->GetName()))
                 return JS_FALSE;
         }
     }
 
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_Shared_Proto_Convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp)
 {
     // XXX ?
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_WN_Shared_Proto_Finalize(JSContext *cx, JSObject *obj)
 {
     // This can be null if xpc shutdown has already happened
     XPCWrappedNativeProto* p = (XPCWrappedNativeProto*) xpc_GetJSPrivate(obj);
     if(p)
         p->JSProtoObjectFinalized(cx, obj);
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_WN_Shared_Proto_Trace(JSTracer *trc, JSObject *obj)
 {
     // This can be null if xpc shutdown has already happened
     XPCWrappedNativeProto* p =
         (XPCWrappedNativeProto*) xpc_GetJSPrivate(obj);
     if(p)
         TraceScopeJSObjects(trc, p->GetScope());
 }
 
 /*****************************************************/
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_ModsAllowed_Proto_Resolve(JSContext *cx, JSObject *obj, jsval idval)
 {
     CHECK_IDVAL(cx, idval);
 
     NS_ASSERTION(
         JS_InstanceOf(cx, obj, &XPC_WN_ModsAllowed_WithCall_Proto_JSClass,
                       nsnull) ||
         JS_InstanceOf(cx, obj, &XPC_WN_ModsAllowed_NoCall_Proto_JSClass,
@@ -1612,17 +1612,17 @@ XPC_WN_ModsAllowed_Proto_Resolve(JSConte
                                  enumFlag, nsnull);
 }
 
 // Give our proto classes object ops that match the respective
 // wrappers so that the JS engine can share scope (maps) among
 // wrappers. This essentially duplicates the number of JSClasses we
 // use for prototype objects (from 2 to 4), but the scope sharing
 // benefit is well worth it.
-JSObjectOps * JS_DLL_CALLBACK
+JSObjectOps *
 XPC_WN_Proto_GetObjectOps(JSContext *cx, JSClass *clazz)
 {
     // Protos for wrappers that want calls to their call() hooks get
     // jsops with a call hook, others get jsops w/o a call hook.
 
     if(clazz == &XPC_WN_ModsAllowed_WithCall_Proto_JSClass ||
        clazz == &XPC_WN_NoMods_WithCall_Proto_JSClass)
         return &XPC_WN_WithCall_JSOps;
@@ -1655,17 +1655,17 @@ JSClass XPC_WN_ModsAllowed_WithCall_Prot
     nsnull,                         // call;
     nsnull,                         // construct;
     nsnull,                         // xdrObject;
     nsnull,                         // hasInstance;
     JS_CLASS_TRACE(XPC_WN_Shared_Proto_Trace), // mark/trace;
     nsnull                          // spare;
 };
 
-JSObjectOps * JS_DLL_CALLBACK
+JSObjectOps *
 XPC_WN_ModsAllowedProto_NoCall_GetObjectOps(JSContext *cx, JSClass *clazz)
 {
     return &XPC_WN_NoCall_JSOps;
 }
 
 JSClass XPC_WN_ModsAllowed_NoCall_Proto_JSClass = {
     "XPC_WN_ModsAllowed_NoCall_Proto_JSClass", // name;
     JSCLASS_HAS_PRIVATE | JSCLASS_MARK_IS_TRACE, // flags;
@@ -1688,17 +1688,17 @@ JSClass XPC_WN_ModsAllowed_NoCall_Proto_
     nsnull,                         // xdrObject;
     nsnull,                         // hasInstance;
     JS_CLASS_TRACE(XPC_WN_Shared_Proto_Trace), // mark/trace;
     nsnull                          // spare;
 };
 
 /***************************************************************************/
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_OnlyIWrite_Proto_PropertyStub(JSContext *cx, JSObject *obj, jsval idval, jsval *vp)
 {
     CHECK_IDVAL(cx, idval);
 
     NS_ASSERTION(
         JS_InstanceOf(cx, obj, &XPC_WN_NoMods_WithCall_Proto_JSClass, nsnull) ||
         JS_InstanceOf(cx, obj, &XPC_WN_NoMods_NoCall_Proto_JSClass, nsnull),
                  "bad proto");
@@ -1714,17 +1714,17 @@ XPC_WN_OnlyIWrite_Proto_PropertyStub(JSC
 
     // Allow XPConnect to add the property only
     if(ccx.GetResolveName() == idval)
         return JS_TRUE;
 
     return Throw(NS_ERROR_XPC_BAD_OP_ON_WN_PROTO, cx);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_NoMods_Proto_Resolve(JSContext *cx, JSObject *obj, jsval idval)
 {
     CHECK_IDVAL(cx, idval);
 
     NS_ASSERTION(
         JS_InstanceOf(cx, obj, &XPC_WN_NoMods_WithCall_Proto_JSClass, nsnull) ||
         JS_InstanceOf(cx, obj, &XPC_WN_NoMods_NoCall_Proto_JSClass, nsnull),
                  "bad proto");
@@ -1798,17 +1798,17 @@ JSClass XPC_WN_NoMods_NoCall_Proto_JSCla
     nsnull,                         // xdrObject;
     nsnull,                         // hasInstance;
     JS_CLASS_TRACE(XPC_WN_Shared_Proto_Trace), // mark/trace;
     nsnull                          // spare;
 };
 
 /***************************************************************************/
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_TearOff_Enumerate(JSContext *cx, JSObject *obj)
 {
     XPCCallContext ccx(JS_CALLER, cx, obj);
     XPCWrappedNative* wrapper = ccx.GetWrapper();
     THROW_AND_RETURN_IF_BAD_WRAPPER(cx, wrapper);
 
     XPCWrappedNativeTearOff* to = ccx.GetTearOff();
     XPCNativeInterface* iface;
@@ -1821,17 +1821,17 @@ XPC_WN_TearOff_Enumerate(JSContext *cx, 
     {
         if(!xpc_ForcePropertyResolve(cx, obj, iface->GetMemberAt(k)->GetName()))
             return JS_FALSE;
     }
 
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 XPC_WN_TearOff_Resolve(JSContext *cx, JSObject *obj, jsval idval)
 {
     CHECK_IDVAL(cx, idval);
 
     XPCCallContext ccx(JS_CALLER, cx, obj);
     XPCWrappedNative* wrapper = ccx.GetWrapper();
     THROW_AND_RETURN_IF_BAD_WRAPPER(cx, wrapper);
 
@@ -1844,17 +1844,17 @@ XPC_WN_TearOff_Resolve(JSContext *cx, JS
     return DefinePropertyIfFound(ccx, obj, idval, nsnull, iface, nsnull,
                                  wrapper->GetScope(),
                                  JS_TRUE, nsnull, nsnull, nsnull,
                                  JSPROP_READONLY |
                                  JSPROP_PERMANENT |
                                  JSPROP_ENUMERATE, nsnull);
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 XPC_WN_TearOff_Finalize(JSContext *cx, JSObject *obj)
 {
     XPCWrappedNativeTearOff* p = (XPCWrappedNativeTearOff*)
         xpc_GetJSPrivate(obj);
     if(!p)
         return;
     p->JSObjectFinalized();
 }
--- a/js/src/xpconnect/src/xpcwrappednativescope.cpp
+++ b/js/src/xpconnect/src/xpcwrappednativescope.cpp
@@ -345,17 +345,17 @@ XPCWrappedNativeScope::GetPrototypeNoHel
 
         NS_ASSERTION(mPrototypeNoHelper,
                      "Failed to create prototype for wrappers w/o a helper");
     }
 
     return mPrototypeNoHelper;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WrappedNativeJSGCThingTracer(JSDHashTable *table, JSDHashEntryHdr *hdr,
                              uint32 number, void *arg)
 {
     XPCWrappedNative* wrapper = ((Native2WrappedNativeMap::Entry*)hdr)->value;
     if(wrapper->HasExternalReference() && !wrapper->IsWrapperExpired())
     {
         JSTracer* trc = (JSTracer *)arg;
         JS_CALL_OBJECT_TRACER(trc, wrapper->GetFlatJSObject(),
@@ -386,17 +386,17 @@ struct SuspectClosure
         : cx(aCx), cb(aCb)
     {
     }
 
     JSContext* cx;
     nsCycleCollectionTraversalCallback& cb;
 };
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WrappedNativeSuspecter(JSDHashTable *table, JSDHashEntryHdr *hdr,
                        uint32 number, void *arg)
 {
     SuspectClosure* closure = static_cast<SuspectClosure*>(arg);
     XPCWrappedNative* wrapper = ((Native2WrappedNativeMap::Entry*)hdr)->value;
     XPCWrappedNativeProto* proto = wrapper->GetProto();
     if(proto && proto->ClassIsMainThreadOnly() && wrapper->IsValid())
     {
@@ -499,27 +499,27 @@ XPCWrappedNativeScope::FinishedFinalizat
 
     // FIXME The lock may not be necessary since we are inside
     // JSGC_FINALIZE_END callback and at this point GC still serializes access
     // to JS runtime. See bug 380139.
     XPCAutoLock lock(rt->GetMapLock());
     KillDyingScopes();
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WrappedNativeMarker(JSDHashTable *table, JSDHashEntryHdr *hdr,
                     uint32 number, void *arg)
 {
     ((Native2WrappedNativeMap::Entry*)hdr)->value->Mark();
     return JS_DHASH_NEXT;
 }
 
 // We need to explicitly mark all the protos too because some protos may be
 // alive in the hashtable but not currently in use by any wrapper
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WrappedNativeProtoMarker(JSDHashTable *table, JSDHashEntryHdr *hdr,
                          uint32 number, void *arg)
 {
     ((ClassInfo2WrappedNativeProtoMap::Entry*)hdr)->value->Mark();
     return JS_DHASH_NEXT;
 }
 
 // static
@@ -531,25 +531,25 @@ XPCWrappedNativeScope::MarkAllWrappedNat
         cur->mWrappedNativeMap->Enumerate(WrappedNativeMarker, nsnull);
         cur->mWrappedNativeProtoMap->Enumerate(WrappedNativeProtoMarker, nsnull);
     }
 
     DEBUG_TrackScopeTraversal();
 }
 
 #ifdef DEBUG
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 ASSERT_WrappedNativeSetNotMarked(JSDHashTable *table, JSDHashEntryHdr *hdr,
                                  uint32 number, void *arg)
 {
     ((Native2WrappedNativeMap::Entry*)hdr)->value->ASSERT_SetsNotMarked();
     return JS_DHASH_NEXT;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 ASSERT_WrappedNativeProtoSetNotMarked(JSDHashTable *table, JSDHashEntryHdr *hdr,
                                       uint32 number, void *arg)
 {
     ((ClassInfo2WrappedNativeProtoMap::Entry*)hdr)->value->ASSERT_SetNotMarked();
     return JS_DHASH_NEXT;
 }
 
 // static
@@ -561,17 +561,17 @@ XPCWrappedNativeScope::ASSERT_NoInterfac
         cur->mWrappedNativeMap->Enumerate(
             ASSERT_WrappedNativeSetNotMarked, nsnull);
         cur->mWrappedNativeProtoMap->Enumerate(
             ASSERT_WrappedNativeProtoSetNotMarked, nsnull);
     }
 }
 #endif
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WrappedNativeTearoffSweeper(JSDHashTable *table, JSDHashEntryHdr *hdr,
                             uint32 number, void *arg)
 {
     ((Native2WrappedNativeMap::Entry*)hdr)->value->SweepTearOffs();
     return JS_DHASH_NEXT;
 }
 
 // static
@@ -605,34 +605,34 @@ struct ShutdownData
         : cx(acx), wrapperCount(0),
           sharedProtoCount(0), nonSharedProtoCount(0) {}
     JSContext* cx;
     int wrapperCount;
     int sharedProtoCount;
     int nonSharedProtoCount;
 };
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WrappedNativeShutdownEnumerator(JSDHashTable *table, JSDHashEntryHdr *hdr,
                                 uint32 number, void *arg)
 {
     ShutdownData* data = (ShutdownData*) arg;
     XPCWrappedNative* wrapper = ((Native2WrappedNativeMap::Entry*)hdr)->value;
 
     if(wrapper->IsValid())
     {
         if(wrapper->HasProto() && !wrapper->HasSharedProto())
             data->nonSharedProtoCount++;
         wrapper->SystemIsBeingShutDown(data->cx);
         data->wrapperCount++;
     }
     return JS_DHASH_REMOVE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WrappedNativeProtoShutdownEnumerator(JSDHashTable *table, JSDHashEntryHdr *hdr,
                                      uint32 number, void *arg)
 {
     ShutdownData* data = (ShutdownData*) arg;
     ((ClassInfo2WrappedNativeProtoMap::Entry*)hdr)->value->
         SystemIsBeingShutDown(data->cx);
     data->sharedProtoCount++;
     return JS_DHASH_REMOVE;
@@ -819,27 +819,27 @@ XPCWrappedNativeScope::FindInJSObjectSco
     // XPCWrappedNativeScope::GetNewOrUsed
     NS_ASSERTION(OKIfNotInitialized, "No scope has this global object!");
     return nsnull;
 }
 
 
 /***************************************************************************/
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WNProtoSecPolicyClearer(JSDHashTable *table, JSDHashEntryHdr *hdr,
                         uint32 number, void *arg)
 {
     XPCWrappedNativeProto* proto =
         ((ClassInfo2WrappedNativeProtoMap::Entry*)hdr)->value;
     *(proto->GetSecurityInfoAddr()) = nsnull;
     return JS_DHASH_NEXT;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WNSecPolicyClearer(JSDHashTable *table, JSDHashEntryHdr *hdr,
                     uint32 number, void *arg)
 {
     XPCWrappedNative* wrapper = ((Native2WrappedNativeMap::Entry*)hdr)->value;
     if(wrapper->HasProto() && !wrapper->HasSharedProto())
         *(wrapper->GetProto()->GetSecurityInfoAddr()) = nsnull;
     return JS_DHASH_NEXT;
 }
@@ -857,17 +857,17 @@ XPCWrappedNativeScope::ClearAllWrappedNa
         cur->mWrappedNativeMap->Enumerate(WNSecPolicyClearer, nsnull);
     }
 
     DEBUG_TrackScopeTraversal();
 
     return NS_OK;
 }
 
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WNProtoRemover(JSDHashTable *table, JSDHashEntryHdr *hdr,
                uint32 number, void *arg)
 {
     XPCWrappedNativeProtoMap* detachedMap = (XPCWrappedNativeProtoMap*)arg;
     
     XPCWrappedNativeProto* proto = (XPCWrappedNativeProto*)
         ((ClassInfo2WrappedNativeProtoMap::Entry*)hdr)->value;
 
@@ -906,24 +906,24 @@ XPCWrappedNativeScope::DebugDumpAllScope
         if(depth)
             for(cur = gScopes; cur; cur = cur->mNext)
                 cur->DebugDump(depth);
     XPC_LOG_OUTDENT();
 #endif
 }
 
 #ifdef DEBUG
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WrappedNativeMapDumpEnumerator(JSDHashTable *table, JSDHashEntryHdr *hdr,
                                uint32 number, void *arg)
 {
     ((Native2WrappedNativeMap::Entry*)hdr)->value->DebugDump(*(PRInt16*)arg);
     return JS_DHASH_NEXT;
 }
-JS_STATIC_DLL_CALLBACK(JSDHashOperator)
+static JSDHashOperator
 WrappedNativeProtoMapDumpEnumerator(JSDHashTable *table, JSDHashEntryHdr *hdr,
                                     uint32 number, void *arg)
 {
     ((ClassInfo2WrappedNativeProtoMap::Entry*)hdr)->value->DebugDump(*(PRInt16*)arg);
     return JS_DHASH_NEXT;
 }
 #endif
 
--- a/js/src/xpconnect/tests/TestXPC.cpp
+++ b/js/src/xpconnect/tests/TestXPC.cpp
@@ -63,17 +63,17 @@
 #include "xpctest.h"
 
 /***************************************************************************/
 // host support for jsengine
 
 FILE *gOutFile = NULL;
 FILE *gErrFile = NULL;
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Print(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     uintN i, n;
     JSString *str;
 
     for (i = n = 0; i < argc; i++) {
         str = JS_ValueToString(cx, argv[i]);
         if (!str)
@@ -81,17 +81,17 @@ Print(JSContext *cx, JSObject *obj, uint
         fprintf(gOutFile, "%s%s", i ? " " : "", JS_GetStringBytes(str));
     }
     n++;
     if (n)
         fputc('\n', gOutFile);
     return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 Load(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
     uintN i;
     JSString *str;
     const char *filename;
     JSScript *script;
     JSBool ok;
     jsval result;
@@ -122,17 +122,17 @@ static JSFunctionSpec glob_functions[] =
 };
 
 static JSClass global_class = {
     "global", 0,
     JS_PropertyStub,  JS_PropertyStub,  JS_PropertyStub,  JS_PropertyStub,
     JS_EnumerateStub, JS_ResolveStub,   JS_ConvertStub,   JS_FinalizeStub
 };
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 my_ErrorReporter(JSContext *cx, const char *message, JSErrorReport *report)
 {
     printf(message);
 }
 
 /***************************************************************************/
 // Foo class for used with some of the tests
 
--- a/js/src/xpconnect/tools/src/nsXPCToolsCompiler.cpp
+++ b/js/src/xpconnect/tools/src/nsXPCToolsCompiler.cpp
@@ -64,17 +64,17 @@ NS_IMETHODIMP nsXPCToolsCompiler::GetBin
     if(NS_FAILED(rv))
         return rv;
 
     nsCOMPtr<nsILocalFile> lfile = do_QueryInterface(file);
     NS_ADDREF(*aBinDir = lfile);
     return NS_OK;
 }
 
-JS_STATIC_DLL_CALLBACK(void) ErrorReporter(JSContext *cx, const char *message,
+static void ErrorReporter(JSContext *cx, const char *message,
                           JSErrorReport *report)
 {
     printf("compile error!\n");
 }
 
 static JSClass global_class = {
     "nsXPCToolsCompiler::global", 0,
     JS_PropertyStub,  JS_PropertyStub,  JS_PropertyStub,  JS_PropertyStub,
--- a/js/src/xpconnect/tools/src/nsXPCToolsProfiler.cpp
+++ b/js/src/xpconnect/tools/src/nsXPCToolsProfiler.cpp
@@ -125,17 +125,17 @@ nsXPCToolsProfiler::~nsXPCToolsProfiler(
     if(mLock)
         PR_DestroyLock(mLock);
 }
 
 /***************************************************************************/
 // the hooks...
 
 /* called just after script creation */
-JS_STATIC_DLL_CALLBACK(void)
+static void
 xpctools_JSNewScriptHook(JSContext  *cx,
                          const char *filename,  /* URL of script */
                          uintN      lineno,     /* line script starts */
                          JSScript   *script,
                          JSFunction *fun,
                          void       *callerdata)
 {
     if(!script)
@@ -167,33 +167,33 @@ xpctools_JSNewScriptHook(JSContext  *cx,
             function->IncrementCompileCount();
             self->mScriptTable.Put(script, function);
         }
     }
     PR_Unlock(self->mLock);
 }
 
 /* called just before script destruction */
-JS_STATIC_DLL_CALLBACK(void)
+static void
 xpctools_JSDestroyScriptHook(JSContext  *cx,
                              JSScript   *script,
                              void       *callerdata)
 {
     if(!script)
         return;
     nsXPCToolsProfiler* self = (nsXPCToolsProfiler*) callerdata;
 
     PR_Lock(self->mLock);
     self->mScriptTable.Remove(script);
     PR_Unlock(self->mLock);
 }
 
 
 /* called on entry and return of functions and top level scripts */
-JS_STATIC_DLL_CALLBACK(void*)
+static void*
 xpctools_InterpreterHook(JSContext *cx, JSStackFrame *fp, JSBool before,
                          JSBool *ok, void *closure)
 {
     // ignore returns
     NS_ASSERTION(fp, "bad frame pointer!");
 
     JSScript* script = fp->script;
     if(script)
--- a/modules/oji/src/lcglue.cpp
+++ b/modules/oji/src/lcglue.cpp
@@ -117,17 +117,17 @@ JVMContext* GetJVMContext()
 ////////////////////////////////////////////////////////////////////////////////
 // LiveConnect callbacks
 ////////////////////////////////////////////////////////////////////////////////
 
 JS_BEGIN_EXTERN_C
 
 #include "jscntxt.h"
 
-JS_STATIC_DLL_CALLBACK(JSContext*)
+static JSContext*
 map_jsj_thread_to_js_context_impl(JSJavaThreadState *jsj_env, void* java_applet_obj, JNIEnv *env, char **errp)
 {
 	// Guess what? This design is totally invalid under Gecko, because there isn't a 1 to 1 mapping
 	// between NSPR threads and JSContexts. We have to ask the plugin instance peer what JSContext
 	// it lives in to make any sense of all this.
 	JSContext* context = NULL;
 	if (java_applet_obj != NULL) {
 		nsIPluginInstance* pluginInstance = reinterpret_cast<nsIPluginInstance*>(java_applet_obj);
@@ -145,17 +145,17 @@ map_jsj_thread_to_js_context_impl(JSJava
 }
 
 /*
 ** This callback is called to map a JSContext to a JSJavaThreadState which
 ** is a wrapper around JNIEnv. Hence this callback essentially maps a JSContext
 ** to a java thread. JSJ_AttachCurrentThreadToJava just calls AttachCurrentThread
 ** on the java vm.
 */
-JS_STATIC_DLL_CALLBACK(JSJavaThreadState*)
+static JSJavaThreadState*
 map_js_context_to_jsj_thread_impl(JSContext *cx, char **errp)
 {
 	*errp = NULL;
 
     // FIXME:  how do we ever break the association between the jsj_env and the
     // JVMContext? This needs to be figured out. Otherwise, we'll end up with the
     // same dangling JSContext problem we are trying to weed out.
 
@@ -187,17 +187,17 @@ map_js_context_to_jsj_thread_impl(JSCont
 ** This callback is called in JSObject.getWindow implementation to get
 
 ** a java wrapper JSObject class for a applet only once.
 ** Note that once a mapping between applet -> javascript JSObject -> Java wrapper JSObject 
 ** is made, all subsequent method calls via JSObject use the internal field
 ** to get to the javascript JSObject.
 */
 
-JS_STATIC_DLL_CALLBACK(JSObject*)
+static JSObject*
 map_java_object_to_js_object_impl(JNIEnv *env, void *pluginInstancePtr, char* *errp)
 {
 	JSObject        *window = NULL;
 	PRBool           mayscript = PR_FALSE;
 	PRBool           jvmMochaPrefsEnabled = PR_TRUE;
 	nsresult         err = NS_OK;
 
 	*errp = NULL;
@@ -240,17 +240,17 @@ map_java_object_to_js_object_impl(JNIEnv
 		NS_RELEASE(pluginPeer);
 	}
 
 	//TODO: Get to the window object using DOM.
 	// window = getDOMWindow().getScriptOwner().getJSObject().
 	return window;
 }
 
-JS_STATIC_DLL_CALLBACK(JSPrincipals*)
+static JSPrincipals*
 get_JSPrincipals_from_java_caller_impl(JNIEnv *pJNIEnv, JSContext *pJSContext, void  **ppNSIPrincipalArrayIN, int numPrincipals, void *pNSISecurityContext)
 {
     nsresult rv;
     nsCOMPtr<nsIScriptSecurityManager> secMan = 
         do_GetService(NS_SCRIPTSECURITYMANAGER_CONTRACTID, &rv);
     if (NS_FAILED(rv))
         return NULL;
 
@@ -260,17 +260,17 @@ get_JSPrincipals_from_java_caller_impl(J
     if (NS_FAILED(rv))
         return NULL;
 
     JSPrincipals* jsprincipals = NULL;
     principal->GetJSPrincipals(pJSContext, &jsprincipals);
     return jsprincipals;
 }
 
-JS_STATIC_DLL_CALLBACK(jobject)
+static jobject
 get_java_wrapper_impl(JNIEnv *pJNIEnv, lcjsobject a_jsobject)
 {
     nsresult       err    = NS_OK;
     jobject  pJSObjectWrapper = NULL;
     nsCOMPtr<nsIJVMManager> managerService = do_GetService(kJVMManagerCID, &err);
     if (NS_FAILED(err)) return NULL;
     nsJVMManager* pJVMMgr = (nsJVMManager *)managerService.get();  
     if (pJVMMgr != NULL) {
@@ -281,17 +281,17 @@ get_java_wrapper_impl(JNIEnv *pJNIEnv, l
     }
     if ( err != NS_OK )
     {
        return NULL;
     }
     return pJSObjectWrapper;
 }
 
-JS_STATIC_DLL_CALLBACK(lcjsobject)
+static lcjsobject
 unwrap_java_wrapper_impl(JNIEnv *pJNIEnv, jobject java_wrapper)
 {
     lcjsobject obj = 0;
     nsresult       err    = NS_OK;
     nsCOMPtr<nsIJVMManager> managerService = do_GetService(kJVMManagerCID, &err);
     if (NS_FAILED(err)) return 0;
     nsJVMManager* pJVMMgr = (nsJVMManager *)managerService.get();  
     if (pJVMMgr != NULL) {
@@ -302,79 +302,79 @@ unwrap_java_wrapper_impl(JNIEnv *pJNIEnv
     }
     if ( err != NS_OK )
     {
        return 0;
     }
     return obj;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 enter_js_from_java_impl(JNIEnv *jEnv, char **errp,
                         void **pNSIPrincipaArray, int numPrincipals, 
                         void *pNSISecurityContext,
                         void *java_applet_obj)
 {
 	return PR_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 exit_js_impl(JNIEnv *jEnv, JSContext *cx)
 {
     // The main idea is to execute terminate function if have any;
     if (cx)
     {
         nsIScriptContext *scriptContext = GetScriptContextFromJSContext(cx);
 
         if (scriptContext)
         {
             scriptContext->ScriptEvaluated(PR_TRUE);
         }
     }
     return;
 }
 
-JS_STATIC_DLL_CALLBACK(PRBool)
+static PRBool
 create_java_vm_impl(SystemJavaVM* *jvm, JNIEnv* *initialEnv, void* initargs)
 {
     // const char* classpath = (const char*)initargs;
     nsCOMPtr<nsIJVMManager> serv = do_GetService(kJVMManagerCID);
     if (!serv)
         return PR_FALSE;
     *initialEnv = JVM_GetJNIEnv();
     if (!*initialEnv)
         return PR_FALSE;
     // serv will be released when this function returns, but that's OK because
     // the XPCOM service manager will keep it alive.
     *jvm = reinterpret_cast<SystemJavaVM*>(serv.get());
     return PR_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(PRBool)
+static PRBool
 destroy_java_vm_impl(SystemJavaVM* jvm, JNIEnv* initialEnv)
 {
     JVM_ReleaseJNIEnv(initialEnv);
     // need to release jvm
     return PR_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JNIEnv*)
+static JNIEnv*
 attach_current_thread_impl(SystemJavaVM* jvm)
 {
     return JVM_GetJNIEnv();
 }
 
-JS_STATIC_DLL_CALLBACK(PRBool)
+static PRBool
 detach_current_thread_impl(SystemJavaVM* jvm, JNIEnv* env)
 {
     JVM_ReleaseJNIEnv(env);
     return PR_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(SystemJavaVM*)
+static SystemJavaVM*
 get_java_vm_impl(JNIEnv* env)
 {
     // only one SystemJavaVM for the whole browser, so it doesn't depend on env
     nsresult rv;
     nsCOMPtr<nsIJVMManager> managerService = do_GetService(kJVMManagerCID, &rv);
     if (NS_FAILED(rv)) return NULL;
     SystemJavaVM* jvm = reinterpret_cast<SystemJavaVM*>(managerService.get());  
     return jvm;
--- a/modules/plugin/base/src/nsJSNPRuntime.cpp
+++ b/modules/plugin/base/src/nsJSNPRuntime.cpp
@@ -113,47 +113,47 @@ NPClass nsJSObjWrapper::sJSObjWrapperNPC
     nsJSObjWrapper::NP_HasProperty,
     nsJSObjWrapper::NP_GetProperty,
     nsJSObjWrapper::NP_SetProperty,
     nsJSObjWrapper::NP_RemoveProperty,
     nsJSObjWrapper::NP_Enumerate,
     nsJSObjWrapper::NP_Construct
   };
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_AddProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_DelProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_SetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_GetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_newEnumerate(JSContext *cx, JSObject *obj, JSIterateOp enum_op,
                           jsval *statep, jsid *idp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_NewResolve(JSContext *cx, JSObject *obj, jsval id, uintN flags,
                         JSObject **objp);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_Convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 NPObjWrapper_Finalize(JSContext *cx, JSObject *obj);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_Call(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                   jsval *rval);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_Construct(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                        jsval *rval);
 
 static bool
 CreateNPObjectMember(NPP npp, JSContext *cx, JSObject *obj,
                      NPObject *npobj, jsval id, jsval *vp);
 
 static JSClass sNPObjectJSWrapperClass =
@@ -170,27 +170,27 @@ static JSClass sNPObjectJSWrapperClass =
 
 typedef struct NPObjectMemberPrivate {
     JSObject *npobjWrapper;
     jsval fieldValue;
     jsval methodName;
     NPP   npp;
 } NPObjectMemberPrivate;
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjectMember_Convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp);
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 NPObjectMember_Finalize(JSContext *cx, JSObject *obj);
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjectMember_Call(JSContext *cx, JSObject *obj, uintN argc,
                     jsval *argv, jsval *rval);
 
-JS_STATIC_DLL_CALLBACK(uint32)
+static uint32
 NPObjectMember_Mark(JSContext *cx, JSObject *obj, void *arg);
 
 static JSClass sNPObjectMemberClass =
   {
     "NPObject Ambiguous Member class", JSCLASS_HAS_PRIVATE,
     JS_PropertyStub, JS_PropertyStub,
     JS_PropertyStub, JS_PropertyStub, JS_EnumerateStub,
     JS_ResolveStub, NPObjectMember_Convert,
@@ -1131,17 +1131,17 @@ GetNPObject(JSContext *cx, JSObject *obj
 
   if (!obj) {
     return nsnull;
   }
 
   return (NPObject *)::JS_GetPrivate(cx, obj);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_AddProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   NPObject *npobj = GetNPObject(cx, obj);
 
   if (!npobj || !npobj->_class || !npobj->_class->hasProperty ||
       !npobj->_class->hasMethod) {
     ThrowJSException(cx, "Bad NPObject as private data!");
 
@@ -1156,17 +1156,17 @@ NPObjWrapper_AddProperty(JSContext *cx, 
                      "plugin object!");
 
     return JS_FALSE;
   }
 
   return ReportExceptionIfPending(cx);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_DelProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   NPObject *npobj = GetNPObject(cx, obj);
 
   if (!npobj || !npobj->_class || !npobj->_class->hasProperty) {
     ThrowJSException(cx, "Bad NPObject as private data!");
 
     return JS_FALSE;
@@ -1177,17 +1177,17 @@ NPObjWrapper_DelProperty(JSContext *cx, 
                      "plugin object!");
 
     return JS_FALSE;
   }
 
   return ReportExceptionIfPending(cx);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_SetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   NPObject *npobj = GetNPObject(cx, obj);
 
   if (!npobj || !npobj->_class || !npobj->_class->hasProperty ||
       !npobj->_class->setProperty) {
     ThrowJSException(cx, "Bad NPObject as private data!");
 
@@ -1228,17 +1228,17 @@ NPObjWrapper_SetProperty(JSContext *cx, 
                      "object!");
 
     return JS_FALSE;
   }
 
   return ReportExceptionIfPending(cx);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_GetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
 {
   NPObject *npobj = GetNPObject(cx, obj);
 
   if (!npobj || !npobj->_class || !npobj->_class->hasProperty ||
       !npobj->_class->hasMethod || !npobj->_class->getProperty) {
     ThrowJSException(cx, "Bad NPObject as private data!");
 
@@ -1281,17 +1281,17 @@ NPObjWrapper_GetProperty(JSContext *cx, 
     _releasevariantvalue(&npv);
 
     return JS_TRUE;
   }
 
   return ReportExceptionIfPending(cx);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 CallNPMethodInternal(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                      jsval *rval, PRBool ctorCall)
 {
   while (obj && JS_GET_CLASS(cx, obj) != &sNPObjectJSWrapperClass) {
     obj = ::JS_GetPrototype(cx, obj);
   }
 
   if (!obj) {
@@ -1413,30 +1413,30 @@ CallNPMethodInternal(JSContext *cx, JSOb
   *rval = NPVariantToJSVal(npp, cx, &v);
 
   // *rval now owns the value, release our reference.
   _releasevariantvalue(&v);
 
   return ReportExceptionIfPending(cx);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 CallNPMethod(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
              jsval *rval)
 {
   return CallNPMethodInternal(cx, obj, argc, argv, rval, PR_FALSE);
 }
 
 struct NPObjectEnumerateState {
   PRUint32     index;
   PRUint32     length;
   NPIdentifier *value;
 };
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_newEnumerate(JSContext *cx, JSObject *obj, JSIterateOp enum_op,
                           jsval *statep, jsid *idp)
 {
   NPObject *npobj = GetNPObject(cx, obj);
   NPIdentifier *enum_value;
   uint32_t length;
   NPObjectEnumerateState *state;
 
@@ -1497,17 +1497,17 @@ NPObjWrapper_newEnumerate(JSContext *cx,
     *statep = JSVAL_NULL;
 
     break;
   }
 
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_NewResolve(JSContext *cx, JSObject *obj, jsval id, uintN flags,
                         JSObject **objp)
 {
   NPObject *npobj = GetNPObject(cx, obj);
 
   if (!npobj || !npobj->_class || !npobj->_class->hasProperty ||
       !npobj->_class->hasMethod) {
     ThrowJSException(cx, "Bad NPObject as private data!");
@@ -1559,54 +1559,54 @@ NPObjWrapper_NewResolve(JSContext *cx, J
     *objp = obj;
 
     return fnc != nsnull;
   }
 
   return ReportExceptionIfPending(cx);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_Convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp)
 {
   // The sole reason we implement this hook is to prevent the JS
   // engine from calling valueOf() on NPObject's. Some NPObject's may
   // actually implement a method named valueOf, but it's unlikely to
   // behave as the JS engine expects it to. IOW, this is an empty hook
   // that overrides what the default hook does.
 
   return JS_TRUE;
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 NPObjWrapper_Finalize(JSContext *cx, JSObject *obj)
 {
   NPObject *npobj = (NPObject *)::JS_GetPrivate(cx, obj);
 
   if (npobj) {
     if (sNPObjWrappers.ops) {
       PL_DHashTableOperate(&sNPObjWrappers, npobj, PL_DHASH_REMOVE);
     }
 
     // Let go of our NPObject
     _releaseobject(npobj);
   }
 
   OnWrapperDestroyed();
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_Call(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                   jsval *rval)
 {
   return CallNPMethodInternal(cx, JSVAL_TO_OBJECT(argv[-2]), argc, argv, rval,
                               PR_FALSE);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjWrapper_Construct(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
                        jsval *rval)
 {
   return CallNPMethodInternal(cx, JSVAL_TO_OBJECT(argv[-2]), argc, argv, rval,
                               PR_TRUE);
 }
 
 class NPObjWrapperHashEntry : public PLDHashEntryHdr
@@ -2030,17 +2030,17 @@ CreateNPObjectMember(NPP npp, JSContext 
   memberPrivate->methodName = id;
   memberPrivate->npp = npp;
 
   ::JS_RemoveRoot(cx, vp);
 
   return true;
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjectMember_Convert(JSContext *cx, JSObject *obj, JSType type, jsval *vp)
 {
   NPObjectMemberPrivate *memberPrivate =
     (NPObjectMemberPrivate *)::JS_GetInstancePrivate(cx, obj,
                                                      &sNPObjectMemberClass,
                                                      nsnull);
   NS_ASSERTION(memberPrivate, "no Ambiguous Member Private data!");
 
@@ -2056,29 +2056,29 @@ NPObjectMember_Convert(JSContext *cx, JS
     // Leave this to NPObjectMember_Call.
     return JS_TRUE;
   default:
     NS_ERROR("illegal operation on JSObject prototype object");
     return JS_FALSE;
   }
 }
 
-JS_STATIC_DLL_CALLBACK(void)
+static void
 NPObjectMember_Finalize(JSContext *cx, JSObject *obj)
 {
   NPObjectMemberPrivate *memberPrivate;
 
   memberPrivate = (NPObjectMemberPrivate *)::JS_GetPrivate(cx, obj);
   if (!memberPrivate)
     return;
 
   PR_Free(memberPrivate);
 }
 
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 NPObjectMember_Call(JSContext *cx, JSObject *obj,
                     uintN argc, jsval *argv, jsval *rval)
 {
   JSObject *memobj = JSVAL_TO_OBJECT(argv[-2]);
   NS_ENSURE_TRUE(memobj, JS_FALSE);
 
   NPObjectMemberPrivate *memberPrivate =
     (NPObjectMemberPrivate *)::JS_GetInstancePrivate(cx, memobj,
@@ -2146,17 +2146,17 @@ NPObjectMember_Call(JSContext *cx, JSObj
   *rval = NPVariantToJSVal(memberPrivate->npp, cx, &npv);
 
   // *rval now owns the value, release our reference.
   _releasevariantvalue(&npv);
 
   return ReportExceptionIfPending(cx);
 }
 
-JS_STATIC_DLL_CALLBACK(uint32)
+static uint32
 NPObjectMember_Mark(JSContext *cx, JSObject *obj, void *arg)
 {
   NPObjectMemberPrivate *memberPrivate =
     (NPObjectMemberPrivate *)::JS_GetInstancePrivate(cx, obj,
                                                      &sNPObjectMemberClass,
                                                      nsnull);
   if (!memberPrivate)
     return 0;
--- a/xpinstall/src/nsJSInstallTriggerGlobal.cpp
+++ b/xpinstall/src/nsJSInstallTriggerGlobal.cpp
@@ -97,17 +97,17 @@ JSClass InstallTriggerGlobalClass = {
   JS_ConvertStub,
   FinalizeInstallTriggerGlobal
 };
 
 
 //
 // InstallTriggerGlobal finalizer
 //
-JS_STATIC_DLL_CALLBACK(void)
+static void
 FinalizeInstallTriggerGlobal(JSContext *cx, JSObject *obj)
 {
   nsISupports *nativeThis = (nsISupports*)JS_GetPrivate(cx, obj);
 
   if (nsnull != nativeThis) {
     // get the js object
     nsIScriptObjectOwner *owner = nsnull;
     if (NS_OK == nativeThis->QueryInterface(NS_GET_IID(nsIScriptObjectOwner),
@@ -199,17 +199,17 @@ static nsIDOMInstallTriggerGlobal* getTr
     CreateNativeObject(cx, obj, &native);
   }
   return native;
 }
 
 //
 // Native method UpdateEnabled
 //
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 InstallTriggerGlobalUpdateEnabled(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   nsIDOMInstallTriggerGlobal *nativeThis = getTriggerNative(cx, obj);
   if (!nativeThis)
     return JS_FALSE;
 
   *rval = JSVAL_FALSE;
 
@@ -225,17 +225,17 @@ InstallTriggerGlobalUpdateEnabled(JSCont
   *rval = BOOLEAN_TO_JSVAL(nativeRet);
   return JS_TRUE;
 }
 
 
 //
 // Native method Install
 //
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 InstallTriggerGlobalInstall(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   nsIDOMInstallTriggerGlobal *nativeThis = getTriggerNative(cx, obj);
   if (!nativeThis)
     return JS_FALSE;
 
   *rval = JSVAL_FALSE;
 
@@ -426,17 +426,17 @@ InstallTriggerGlobalInstall(JSContext *c
   JS_ReportError(cx, "Incorrect arguments to InstallTrigger.Install()");
   return JS_FALSE;
 }
 
 
 //
 // Native method InstallChrome
 //
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 InstallTriggerGlobalInstallChrome(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   nsIDOMInstallTriggerGlobal *nativeThis = getTriggerNative(cx, obj);
   if (!nativeThis)
     return JS_FALSE;
 
   uint32       chromeType = NOT_CHROME;
   nsAutoString sourceURL;
@@ -536,17 +536,17 @@ InstallTriggerGlobalInstallChrome(JSCont
   }
   return JS_TRUE;
 }
 
 
 //
 // Native method StartSoftwareUpdate
 //
-JS_STATIC_DLL_CALLBACK(JSBool)
+static JSBool
 InstallTriggerGlobalStartSoftwareUpdate(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
 {
   nsIDOMInstallTriggerGlobal *nativeThis = getTriggerNative(cx, obj);
   if (!nativeThis)
     return JS_FALSE;
 
   PRBool       nativeRet;
   PRInt32      flags = 0;