As the subject says, xfce4-taskmanager is pretty linux-specific. I've a version that works on Solaris here: http://www.petertribble.co.uk/Solaris/xfce4-taskmanager-0.3.2-solaris.tar.bz2 I'm happy to work with someone (who knows far more about autoconf than I do) to get this integrated properly.
Can you have a look at the two missing functions: void send_signal_to_task(gint task_id, gint signal); void set_priority_to_task(gint task_id, gint prio); They are used to send KILL/TERM/etc signals and set the priority. I added the ones from Linux, they should actually to be the same. The code is now in git. You can test it and let me know if it works for you. You will need the xfce4-dev-tools package and execute the ./autogen.sh script that will build the configure script and run it automatically. http://git.xfce.org/apps/xfce4-taskmanager To clone: git clone git://git.xfce.org/apps/xfce4-taskmanager
Created attachment 2526 Updated Solaris support This patch is against the git repository. Brings my initial port into line with the version in git, which has changed a little since the released tarball I started from Makefile.am needs to select Solaris correctly Makefile needs -lkstat adding to libraries (not sure how best to do that) taskmanager-solaris.c defines kc and includes the headers it needs interface.c - %cpu has two decimal places (on fast machines, or multicore, you need higher precision) %cpu scales properly with the Solaris code %cpu calculated on Solaris - percentage is #ifdef'd out, and the calculation I use is slightly different to get higher precision Implemented set_priority_to_task for Solaris Solaris needs a different list of priorities (must be a better way to do that) Fixed error message in send_signal_to_task (all platforms)
I have one quick remark, do you really think we need that much precision for the cpu usage? I really don't think. Keep in mind that this taskmgr is a very simple tool, that gives you a quick view over running processes but I don't believe it will be used for precise measurements. Otherwise I'm gonna push the patch, of course I will have to take a look for interface.c and functions.c afterwards. I also looked around the Makefile and moved the kstat lib requirement into the autoconf script with the AC_CHECK_LIB macro.
(In reply to comment #3) > I have one quick remark, do you really think we need that much precision for > the cpu usage? I really don't think. Keep in mind that this taskmgr is a very > simple tool, that gives you a quick view over running processes but I don't > believe it will be used for precise measurements. On my system(s), with just the integer percentage, essentially every process sits stubbornly at zero. Even with 2 decimal places most processes only have one significant figure showing, so it's not to get precision but to actually show some useful data. That said, there may be a case for different displays for different operating systems? While Solaris gives you data with nanosecond precision (although typically you only get useful microseconds), I'm not sure whether the Linux code gets you better than 0.01s accuracy - although even there once you've divided by the number of cpus the numbers can get quite small.
(In reply to comment #4) > (In reply to comment #3) > > I have one quick remark, do you really think we need that much precision for > > the cpu usage? I really don't think. Keep in mind that this taskmgr is a very > > simple tool, that gives you a quick view over running processes but I don't > > believe it will be used for precise measurements. > > On my system(s), with just the integer percentage, essentially every process > sits stubbornly at zero. Even with 2 decimal places most processes only have > one significant figure showing, so it's not to get precision but to actually > show some useful data. > > That said, there may be a case for different displays for different operating > systems? While Solaris gives you data with nanosecond precision (although > typically you only get useful microseconds), I'm not sure whether the Linux > code gets you better than 0.01s accuracy - although even there once you've > divided by the number of cpus the numbers can get quite small. I'm still not convinced. I don't see it as important to display processes that don't do much. I can take as example an h264 decoder, you will have a use between 20 to 60% depending of the amount of data to decode (even up to 100% if the CPU is not powerful enough). For MP3 decoding you see generally something between 5 and 15%. And to get to the point the taskmgr lets you figure which application is burning up the CPU. I at least don't think it's worth monitoring the CPU usage of third applications that always sit around. And finally regarding the number of CPUs, it really needs to be a *lot* of CPU installed if you see a process that is at 100% on only one CPU that shows up with 1%. The only inclusion would be through a settings dialog (if not a hidden option). As currently there isn't any such dialog, I simply suggest we keep this in the TODO file. I hope it is fine this way :)?
I pushed a new commit e05fff2. It should be fine by now. Regarding the CPU precision I moved that into the TODO list with a possible settings dialog. If there are other issues with the patch reopen but otherwise file a new bug, thank you for the contribution :)