On Tuesday 06 April 2010 09:50:42 Zhang, Qiang Z wrote:
Hi dear developers,
I found PackageKit zypp backend can't work with proxy. In fact, libzypp can't read GConf system proxy settings,
Yes, libzypp currently refers to /etc/sysconfig/proxy. But there are requests to change this and prefer the settings from the environment, maybe even use libproxy to retrieve the values.
so I have wrote a patch to read GConf proxy setting using GConf API, but I found GConf API can't got the correct proxy setting in libzypp, with some investigation, I found the DBUS_SESSION_BUS_ADDRESS is not set while entering libzypp from PackageKit or zypper, so GConf API(gconf_client_get_default, gconf_client_get,etc.) can't works.
I don't know why GConf API can't works when libzypp is called by PackageKit or zypper, and why DBUS_SESSION_BUS_ADDRESS is not set.
I also have tried to use libproxy API to got proxy info in libzypp, but still failed, because libproxy also use GConf API and GConf API can't works in libzypp.
Attached is my patch for reading GConf proxy info.
What should I do here to let GConf API works in libzypp?
I'm not familiar with GConf. But before taking a GConf reader into libzypp, I'd vote for using libproxy. This reminds me that we want to offer an API to pass proxy settings down to libzypp, overwriting any internal detection. This is what PackageKit could use until libzypps defaults fir it's needs. -- cu, Michael Andres +------------------------------------------------------------------+ Key fingerprint = 2DFA 5D73 18B1 E7EF A862 27AC 3FB8 9E3A 27C6 B0E4 +------------------------------------------------------------------+ Michael Andres YaST Development ma@novell.com SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nuernberg) Maxfeldstrasse 5, D-90409 Nuernberg, Germany, ++49 (0)911 - 740 53-0 +------------------------------------------------------------------+ -- To unsubscribe, e-mail: zypp-devel+unsubscribe@opensuse.org For additional commands, e-mail: zypp-devel+help@opensuse.org