Re: [Tracker] runtime checking for tracker availability



Doesn't D-Bus have a method to find out if a service is startable?
Sorry can't check right now though...

Samuel Cormier-Iijima

On 10/30/06, Ulrik Mikaelsson <ulrik mikaelsson gmail com> wrote:
One option would be to try to use the pkg-config infrastructure. I think
this is what it's supposed to do. That'll probably require additions to
tracker, and in worst case an extra dependency, though.

Otherwise, $PATH is probably your best bet.

What exactly do you want to do once you know if it's installed? Launch it?
Would it be possible to let tracker-installation and packaging configure
dbus to launch it on it's first message? Don't know DBUS enough to know if
this is possible for the session bus.


On 10/30/06, Mikkel Kamstrup Erlandsen <mikkel kamstrup gmail com> wrote:
>
> 2006/10/30, Jamie McCracken <jamiemcc blueyonder co uk>:
>
> > Mikkel Kamstrup Erlandsen wrote:
> > > 2006/10/20, Edward Duffy <eduffy gmail com <mailto:
eduffy gmail com>>:
> > >
> > >     Until dbus 0.9+ makes into most distros, you can check the lock
file
> > >
> > >     # lsof ~/.Tracker/${USER}_tracker_lock
> > >
> > >     this'll return 0 if trackerd is running by ${USER}, 1 otherwise.
> > >
> > >
> > > Oh, perhaps I was unclear. I need to check if tracker is _installed_
(I
> > > could check for existence of ~/.Tracker but that dir only exists if
> > > trackerd has been run). I can check if trackerd is _running_ by
> > > dbus.NameHasOwner("org.freedesktop.Tracker"). I could manually scan
the
> > > $PATH for trackerd but that seems unelegant...
> > >
> >
> > you could check for usr/share/tracker (or usr/local/share/tracker)
>
>
> That would work on 98% of all systems, but I would really like a
completely generic test...
>
> Cheers,
> Mikkel
>
>
>
> _______________________________________________
> tracker-list mailing list
> tracker-list gnome org
> http://mail.gnome.org/mailman/listinfo/tracker-list
>
>
>


_______________________________________________
tracker-list mailing list
tracker-list gnome org
http://mail.gnome.org/mailman/listinfo/tracker-list






[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]