DragonFlyBSD uses pkgsrc package infrastructure, hence the the need
for extra flags.
Cmake pkg_search_module macro sets according <XPREFIX>_LDFLAGS var,
thus the correct way should be to append it to conky_includes and
conky_libs for each extra package needed.
As all pkgsrc packages always install in /usr/pkg, the simplest thing
is to set specific cflags and ldflags at the very beginning.
Conky is btw wip (work in progress) in pkgsrc system, mostly with
NetBSD patches. This is intended as radical workaround (DragonFlyBSD
specific for now) instead of submitting specific patches to pksrc
maintainers.
* don't use kvm_* calls, just sysctl (so no suid perm necessary)
* sysctls calls in general aren't thread safe, collapse callbacks
using same sysctls (specifically total/running procs and proc list
ones).
Some sysctls need two calls (first to get size of obj returned,
second to get object self); if different threads use this schema
on same sysctl, weird values are returned (first/second calls
sequence should be serialized).
In general it makes not much sense too having more threads that use
the same sysctl; just get info once and populate all data.
* add DragonFly specific extended uname string ($version in conky.conf)
with git version and signature
Todo:
- top process list logic is old style, use top.cc funcs.
- find a solution for cpu freq
Signed-off-by: Pavel Labath <pavelo@centrum.sk>
Rewrote timed_thread library in C++ using fancy new C++0x features. The
main reason for this is to phase out poor encapsulation and C-style
function pointers.