[Goodies-commits] r5929 - in xfce4-sensors-plugin/trunk: . lib
Fabian Nowak
timystery at xfce.org
Mon Nov 3 01:20:59 CET 2008
Author: timystery
Date: 2008-11-03 00:20:59 +0000 (Mon, 03 Nov 2008)
New Revision: 5929
Modified:
xfce4-sensors-plugin/trunk/TODO
xfce4-sensors-plugin/trunk/configure.in.in
xfce4-sensors-plugin/trunk/lib/hddtemp.c
xfce4-sensors-plugin/trunk/lib/sensors-interface-common.c
Log:
- xfce4-sensors as default application
- modified configure script to successfully determine working netcat and correct hddtemp path
- fixed uninitialized error string in hddtemp.c
Modified: xfce4-sensors-plugin/trunk/TODO
===================================================================
--- xfce4-sensors-plugin/trunk/TODO 2008-11-02 23:37:51 UTC (rev 5928)
+++ xfce4-sensors-plugin/trunk/TODO 2008-11-03 00:20:59 UTC (rev 5929)
@@ -1,6 +1,8 @@
TODO
======
+- when moving from vertical to horizontal panel or vice versa, the orientation is not regarded for aligning the labels
+
- Use notfication messages when alert is on; when maximum is reached.
- fix error: doesn't find all sensors when newly adding plugin to panel - sensors library problem?
Modified: xfce4-sensors-plugin/trunk/configure.in.in
===================================================================
--- xfce4-sensors-plugin/trunk/configure.in.in 2008-11-02 23:37:51 UTC (rev 5928)
+++ xfce4-sensors-plugin/trunk/configure.in.in 2008-11-03 00:20:59 UTC (rev 5929)
@@ -88,7 +88,6 @@
fi
if test x"$enable_hddtemp" = x"yes"; then
- AC_DEFINE([HAVE_HDDTEMP], [1], [Define to 1 if hddtemp is desired])
AC_ARG_WITH([pathhddtemp], [AC_HELP_STRING([--with-pathhddtemp], [Specify path to hddtemp @<:@default=auto@:>@])],
[
@@ -96,20 +95,21 @@
], [
AC_MSG_CHECKING([for hddtemp path])
HDDTEMP=([`whereis -b hddtemp | sed 's/.*\ \(\/[a-zA-Z0-9\-\/.]*bin[A-Za-z0-9\-\/.]*hddtemp\).*/\1/'`])
-
AC_MSG_RESULT([$HDDTEMP])
])
- AC_DEFINE_UNQUOTED([PATH_HDDTEMP], ["$HDDTEMP"], [Complete path to hddtemp])
- AC_SUBST([PATH_HDDTEMP])
+ if test x"$HDDTEMP" = x"hddtemp:"; then
+ enable_hddtemp=no
+ else
+ AC_DEFINE([HAVE_HDDTEMP], [1], [Define to 1 if hddtemp is desired])
+ AC_DEFINE_UNQUOTED([PATH_HDDTEMP], ["$HDDTEMP"], [Complete path to hddtemp])
+ AC_SUBST([PATH_HDDTEMP])
+ fi
fi
AM_CONDITIONAL([HAVE_HDDTEMP], [test x$enable_hddtemp = x"yes"])
-
-
-
dnl Check for netcat for hddtemp to be used
AC_ARG_ENABLE([netcat], [AC_HELP_STRING([--enable-netcat], [Use netcat to read your hddtemp temperature @<:@default=auto@:>@])],
[],
@@ -128,8 +128,6 @@
fi
if test x"$enable_netcat" = x"yes"; then
- AC_DEFINE([HAVE_NETCAT], [1], [Define to 1 if hddtemp is desired])
-
AC_ARG_WITH([pathnetcat], [AC_HELP_STRING([--with-pathnetcat], [Specify path to netcat @<:@default=auto@:>@])],
[
NETCAT_PATH=$withval
@@ -143,27 +141,30 @@
AC_MSG_RESULT([$NETCAT_PATH])
])
- AC_DEFINE_UNQUOTED([NETCAT_PATH], ["$NETCAT_PATH"], [Complete path to netcat])
- AC_SUBST([NETCAT_PATH])
-
NETCAT_HOST=localhost
- AC_DEFINE_UNQUOTED([NETCAT_HOST], ["$NETCAT_HOST"], [Host for netcat])
- AC_SUBST([NETCAT_HOST])
-
HDDTEMP_PORT=7634
- AC_DEFINE_UNQUOTED([HDDTEMP_PORT], ["$HDDTEMP_PORT"], [Port for hddtemp with netcat])
- AC_SUBST([HDDTEMP_PORT])
+ AC_MSG_CHECKING([for hddtemp being queryable via netcat])
+ NETCAT_RUN=([`"$NETCAT_PATH" "$NETCAT_HOST" "$HDDTEMP_PORT" 2> /dev/null`])
+ AC_MSG_RESULT([$NETCAT_RUN])
+ if test x"$NETCAT_RUN" = x""; then
+ enable_netcat=no
+ dnl AC_DEFINE([HAVE_NETCAT], [0], [Define to 1 if hddtemp daemon is queried via netcat])
+ else
+ AC_DEFINE([HAVE_NETCAT], [1], [Define to 1 if hddtemp daemon is queried via netcat])
+ AC_DEFINE_UNQUOTED([NETCAT_PATH], ["$NETCAT_PATH"], [Complete path to netcat])
+ AC_SUBST([NETCAT_PATH])
+ AC_DEFINE_UNQUOTED([NETCAT_HOST], ["$NETCAT_HOST"], [Host for netcat])
+ AC_SUBST([NETCAT_HOST])
+ AC_DEFINE_UNQUOTED([HDDTEMP_PORT], ["$HDDTEMP_PORT"], [Port for hddtemp with netcat])
+ AC_SUBST([HDDTEMP_PORT])
+ fi
fi
AM_CONDITIONAL([HAVE__NETCAT], [test x$enable_netcat = x"yes"])
-
-
-
-
dnl Check for interface for /proc/acpi to be used
AC_ARG_ENABLE([procacpi], [AC_HELP_STRING([--enable-procacpi], [Use /proc/acpi to read your CPU temperature @<:@default=yes@:>@])],
[],
Modified: xfce4-sensors-plugin/trunk/lib/hddtemp.c
===================================================================
--- xfce4-sensors-plugin/trunk/lib/hddtemp.c 2008-11-02 23:37:51 UTC (rev 5928)
+++ xfce4-sensors-plugin/trunk/lib/hddtemp.c 2008-11-03 00:20:59 UTC (rev 5929)
@@ -457,6 +457,7 @@
result = g_spawn_command_line_sync ( (const gchar*) cmd_line,
&standard_output, &standard_error, &exit_status, NULL);
error = g_new(GError, 1);
+ error->message = g_strdup (_("No concrete error detected.\n"));
if (exit_status==0)
{
tmp3 = "-255";
@@ -483,6 +484,10 @@
g_free(standard_output);
standard_output = tmp3;
}
+ else
+ {
+ error->message = g_strdup (standard_error);
+ }
#else
error = NULL;
Modified: xfce4-sensors-plugin/trunk/lib/sensors-interface-common.c
===================================================================
--- xfce4-sensors-plugin/trunk/lib/sensors-interface-common.c 2008-11-02 23:37:51 UTC (rev 5928)
+++ xfce4-sensors-plugin/trunk/lib/sensors-interface-common.c 2008-11-03 00:20:59 UTC (rev 5929)
@@ -110,7 +110,7 @@
/* double-click improvement */
sensors->exec_command = TRUE;
- sensors->command_name = g_strdup("xsensors");
+ sensors->command_name = g_strdup("xfce4-sensors");
sensors->doubleclick_id = 0;
/* show units */
More information about the Goodies-commits
mailing list