[oe-commits] org.oe.dev packages/gtk-webcore/files/build_silence.patch

philippe commit openembedded-commits at lists.openembedded.org
Thu Apr 5 04:09:49 UTC 2007


packages/gtk-webcore/files/build_silence.patch 
* remove now obsolete build fix
packages/gtk-webcore/osb-nrcit_svn.bb 
* updated svn recipe to add some more patches
packages/gtk-webcore/files/NRCit_HTTP_auth.diff 
* new patch that fix HTTP AUTH issues
packages/gtk-webcore/files/NRCit_unmap.diff
* patch to fix redraw issues

Author: philippe at openembedded.org
Branch: org.openembedded.dev
Revision: cd87faafb1baaea21105f7e6c92532f906050469
ViewMTN: http://monotone.openembedded.org/revision.psp?id=cd87faafb1baaea21105f7e6c92532f906050469
Files:
1
packages/gtk-webcore/files/NRCit_HTTP_auth.diff
packages/gtk-webcore/files/NRCit_unmap.diff
packages/gtk-webcore/files/build_silence.patch
packages/gtk-webcore/osb-nrcit_svn.bb
Diffs:

#
# mt diff -r3d375d6ff453972e1fe38aa87dc8de18a768d42b -rcd87faafb1baaea21105f7e6c92532f906050469
#
# 
# 
# add_file "packages/gtk-webcore/files/NRCit_HTTP_auth.diff"
#  content [338d8ad7c23af55ee8a44e6e11f2738e033b5af4]
# 
# add_file "packages/gtk-webcore/files/NRCit_unmap.diff"
#  content [dcb7bbe500bbba51d7139ea52400d9f2ee3a046a]
# 
# patch "packages/gtk-webcore/files/build_silence.patch"
#  from [5827b3be5177a88a31de6af20f33a1c2ee99bb54]
#    to [100b164cbd49cc0a8c5e2082dd84d0ac98e0f6d9]
# 
# patch "packages/gtk-webcore/osb-nrcit_svn.bb"
#  from [bd9038b33a39347d8b14f9d564f160cd78a3bde7]
#    to [d171732cc0fabeb4f6802c6f3f1419599cf9950d]
# 
============================================================
--- packages/gtk-webcore/files/NRCit_HTTP_auth.diff	338d8ad7c23af55ee8a44e6e11f2738e033b5af4
+++ packages/gtk-webcore/files/NRCit_HTTP_auth.diff	338d8ad7c23af55ee8a44e6e11f2738e033b5af4
@@ -0,0 +1,132 @@
+Index: NRCit/src/Http.cpp
+===================================================================
+--- NRCit/src/Http.cpp	(revision 55)
++++ NRCit/src/Http.cpp	(working copy)
+@@ -299,3 +299,9 @@
+ {
+ 
+ }
++
++HttpHeaderWWWAuthenticate::HttpHeaderWWWAuthenticate(const gchar * value)
++    : HttpHeader(WWWAuthenticate, "WWW-Authenticate", value)
++{
++
++}
+Index: NRCit/src/HttpCurl.cpp
+===================================================================
+--- NRCit/src/HttpCurl.cpp	(revision 55)
++++ NRCit/src/HttpCurl.cpp	(working copy)
+@@ -69,7 +69,7 @@
+     void setPostData(const gchar * contentType, GByteArray *);
+ 
+ protected:
+-    bool shouldAuthenticate() { return m_authenticate; }
++    bool shouldAuthenticate() { return m_need_authenticate; }
+ 
+     /** Authenticates the request. */
+     void doAuth();
+@@ -89,7 +89,7 @@
+ 
+     GByteArray * postData;
+     bool headerEnd;
+-    bool m_authenticate;
++    bool m_need_authenticate;
+ 
+     gchar * proxy;
+     CurlFactory* parent;
+@@ -374,7 +374,7 @@
+     ,curl_post_last(NULL)
+     ,postData(NULL)
+     ,headerEnd(false)
+-    ,m_authenticate(true)
++    ,m_need_authenticate(true)
+     ,proxy(NULL)
+     ,parent(aParent)
+     ,status(-1)
+@@ -438,7 +438,8 @@
+ }
+ 
+ void CurlRequest::doAuth() {
+-    m_authenticate = m_listener->authenticate(this);
++    m_listener->authenticate(this);
++    m_need_authenticate = false; // set false to go on processing data in CurlRequest::data
+ }
+ 
+ void CurlRequest::execute()
+@@ -457,6 +458,8 @@
+     curl_easy_setopt(handle, CURLOPT_FOLLOWLOCATION, 1);
+     curl_easy_setopt(handle, CURLOPT_MAXREDIRS, 10);
+ 
++    curl_easy_setopt(handle, CURLOPT_AUTOREFERER, 1);
++
+     // url ptr must remain valid through the request
+     curl_easy_setopt(handle, CURLOPT_URL, m_url);
+ 
+@@ -534,7 +537,7 @@
+ 
+ 
+     // if we are in middle of authenticating, do nothing.
+-    if (status != HTTP_AUTH_REQUIRED || !m_authenticate) {
++    if (status != HTTP_AUTH_REQUIRED || !m_need_authenticate) {
+ 		m_listener->data(this, data, len);
+     }
+ }
+@@ -570,6 +573,8 @@
+ 		header = new HttpHeaderRefresh(value);
+     } else if (!strcmp(key, HTTP_SET_COOKIE)) {
+ 		header = new HttpHeaderSetCookie(value);
++    } else if (!strcmp(key, HTTP_WWW_AUTHENTICATE)) {
++		header = new HttpHeaderWWWAuthenticate(value);
+     } else {
+ 		header = new HttpHeader(HttpHeader::Unknown, key, value);
+     }
+@@ -584,7 +589,7 @@
+ {
+     HttpHeader *hdr = parseHeader(data, len);
+     if (hdr) {
+-		if (hdr->key() == HTTP_WWW_AUTHENTICATE && hdr->value())
++		if (!strcmp(hdr->key(), HTTP_WWW_AUTHENTICATE) && hdr->value())
+ 		{
+ 			const gchar * value = hdr->value();
+ 			char * realm = g_strrstr(value, "realm=" );
+Index: NRCit/src/PageLoadListener.cpp
+===================================================================
+--- NRCit/src/PageLoadListener.cpp	(revision 55)
++++ NRCit/src/PageLoadListener.cpp	(working copy)
+@@ -206,8 +206,9 @@
+             creds->setCredential(newcred, space);
+             request->authenticate(newcred.user(), newcred.password());
+         }
+-        if (user) g_free(user);
+-        if (password) g_free(password);
++        // Do not free these values which are owned by Webi.
++        // if (user) g_free(user);
++        // if (password) g_free(password);
+         return ret;
+     }
+ 
+Index: NRCit/src/Http.h
+===================================================================
+--- NRCit/src/Http.h	(revision 55)
++++ NRCit/src/Http.h	(working copy)
+@@ -165,6 +165,7 @@
+ 		ContentLength,
+ 		Refresh,
+ 		SetCookie,
++		WWWAuthenticate,
+ 		Unknown,
+ 		Invalid
+ 	};
+@@ -236,6 +237,12 @@
+ 	~HttpHeaderSetCookie() {}
+ };
+ 
++class HttpHeaderWWWAuthenticate : public HttpHeader
++{
++public:
++	HttpHeaderWWWAuthenticate(const gchar* value);
++	~HttpHeaderWWWAuthenticate() {}
++};
+ 
+ 
+ #endif
============================================================
--- packages/gtk-webcore/files/NRCit_unmap.diff	dcb7bbe500bbba51d7139ea52400d9f2ee3a046a
+++ packages/gtk-webcore/files/NRCit_unmap.diff	dcb7bbe500bbba51d7139ea52400d9f2ee3a046a
@@ -0,0 +1,39 @@
+Index: NRCit/src/gtk/webi.cc
+===================================================================
+--- NRCit/src/gtk/webi.cc	(リビジョン 55)
++++ NRCit/src/gtk/webi.cc	(作業コピー)
+@@ -50,6 +50,7 @@
+ static void _webi_finalize (GObject * self) G_GNUC_UNUSED;
+ static void _webi_realize (GtkWidget * widget) G_GNUC_UNUSED;
+ static void _webi_map (GtkWidget * widget) G_GNUC_UNUSED;
++static void _webi_unmap (GtkWidget * widget) G_GNUC_UNUSED;
+ static gboolean _webi_expose_event (GtkWidget * widget, GdkEventExpose * event) G_GNUC_UNUSED;
+ static void _webi_size_allocate (GtkWidget * widget, GtkAllocation * allocation) G_GNUC_UNUSED;
+ 
+@@ -305,6 +306,7 @@
+     g_object_class->finalize = _webi_finalize;
+     gtk_widget_class->realize = _webi_realize;
+     gtk_widget_class->map = _webi_map;
++    gtk_widget_class->unmap = _webi_unmap;
+     gtk_widget_class->expose_event = _webi_expose_event;
+     gtk_widget_class->size_allocate = _webi_size_allocate;
+     return;
+@@ -736,6 +738,18 @@
+ }
+ #undef PARENT_HANDLER
+ 
++static void
++_webi_unmap (GtkWidget * widget)
++{
++
++    g_return_if_fail(widget != NULL);
++    g_return_if_fail(WEBI_IS_WEBI (widget));
++
++    GTK_WIDGET_UNSET_FLAGS(widget, GTK_MAPPED);
++
++    gdk_window_hide(widget->window);
++}
++
+ static gboolean
+ _webi_expose_event (GtkWidget * widget, GdkEventExpose * event)
+ #define PARENT_HANDLER(___widget,___event) \
============================================================
--- packages/gtk-webcore/files/build_silence.patch	5827b3be5177a88a31de6af20f33a1c2ee99bb54
+++ packages/gtk-webcore/files/build_silence.patch	100b164cbd49cc0a8c5e2082dd84d0ac98e0f6d9
@@ -14,19 +14,3 @@ Index: configure.in
  LDFLAGS="$LDFLAGS $PACKAGE_LIBS $X_LIBS $JSCORE_LIBS \
  -nodefaultlibs -lgcc -lc"
  
-Index: kwiq/KWQEvent.cpp
-===================================================================
---- kwiq/KWQEvent.cpp	(revision 46)
-+++ kwiq/KWQEvent.cpp	(working copy)
-@@ -759,10 +759,10 @@
- #if 0
-     if (state & GDK_MOD1_MASK)
- 		qstate |= Qt::AltButton;
--#endif
- 
-     if (state & GDK_META_MASK)
- 		qstate |= Qt::MetaButton;
-+#endif
- 
-     if (isKeypadEvent(event))
- 		qstate |= Qt::Keypad;
============================================================
--- packages/gtk-webcore/osb-nrcit_svn.bb	bd9038b33a39347d8b14f9d564f160cd78a3bde7
+++ packages/gtk-webcore/osb-nrcit_svn.bb	d171732cc0fabeb4f6802c6f3f1419599cf9950d
@@ -10,6 +10,8 @@ SRC_URI = "svn://gtk-webcore.svn.sourcef
 DEPENDS = "curl librsvg osb-nrcore"
 
 SRC_URI = "svn://gtk-webcore.svn.sourceforge.net/svnroot/gtk-webcore/trunk;module=NRCit;proto=https \
+	   file://NRCit_unmap.diff;patch=1 \
+           file://NRCit_HTTP_auth.diff;patch=1 \  
            file://gcc4-fno-threadsafe-statics-NRCit.patch;patch=1"
 S = "${WORKDIR}/NRCit"
 






More information about the Openembedded-commits mailing list