GNOME Bugzilla – Bug 385444
gpilotd won't work when porting to solaris
Last modified: 2007-01-11 08:57:09 UTC
Please describe the problem: When porting the latest gnome-pilot pkgs for Solaris USB port on X86 and SPARC platform, Gpilotd won't work. Steps to reproduce: Actual results: Expected results: Does this happen every time? yes Other information:
Created attachment 78287 [details] [review] applications patch
I guess this bug is related to 385434. If I read your patch right, this will attempt a sync every 2 seconds on Solaris (it bypasses the code that sees if a recognised device has appeared by querying usbfs). You suggest this is a regression since gnome-pilot 2.0.13, but as far as I can see, 2.0.13 would have tried to read "/proc/bus/usb/devices", and then try reading "/proc/bus/usb/devices_please-use-sysfs-instead" and then give up. Help me out here! :)
NEEDINFO state. Jerry, please reopen this bug report when answering Matt's question. Thanks.
No, it's not related to 385434. Because there are no usb file and directory on Solaris which are similiar with "/proc/bus/usb/devices" and "/sys/bus/usb/devices" on Linux, so it's not necessary to check if a recognised devise has appeared by querying usb file on Solaris. Actually, the patch has already been patched into gnome-pilot 2.0.13 on Solaris. However, we keep it as an internal patch then and we tend to commit it into community CVS currently by adding "if defined(sun) && defined (__SVR4)".
Thanks for the update, Jerry. I understand that there's no need to check the non-existent /proc/bus/usb/devices or /sys/bus/usb/devices on solaris. Do you make any attempt to detect whether a recognised device has appeared, or do you try to sync every 2 seconds? As I mentioned in my first comment, your patch would appear to attempt a sync every 2 seconds. Presumably there is some way to detect devices on solaris, and it would be better to use that than to blindly attempt a sync every timeout interval. What do you think?
Currently this patch try to sync every 2 seconds on Solaris. I totally agree with your ideas that the devices should be detected at first which HAL can do. However, HAL doesn't work well enough on Solaris and we're pushing HAL team to fix it. When HAL works well, I'll enable --with-hal option when building gnome-pilot, then the palm devices can be detected automatically. But currently, unfortunately, there's no better way to do it.
Thanks for clarifying, Jerry. If that's the current situation on Solaris, then your changes seem straightforward. I'll commit your changes at my next check in.
Ok, thanks.
Patch applied to head (i.e. subversion trunk).