Updated the GLIBTOP_SOLARIS_RELEASE

2006-06-24  Benoît Dejean  <benoit@placenet.org>

	* libgtop-sysdeps.m4:
	* sysdeps/solaris/glibtop_machine.h:

	Updated the GLIBTOP_SOLARIS_RELEASE

	Patch by hua.zhang@sun.com.
	Closes #345821.
This commit is contained in:
Benoît Dejean
2006-06-24 17:52:28 +00:00
committed by Benoît Dejean
parent 7f477561f0
commit bc79bf010a
3 changed files with 16 additions and 6 deletions

View File

@@ -1,3 +1,13 @@
2006-06-24 Benoît Dejean <benoit@placenet.org>
* libgtop-sysdeps.m4:
* sysdeps/solaris/glibtop_machine.h:
Updated the GLIBTOP_SOLARIS_RELEASE
Patch by hua.zhang@sun.com.
Closes #345821.
2006-06-24 Benoît Dejean <benoit@placenet.org>
* configure.in:

View File

@@ -251,16 +251,16 @@ main (void)
AC_MSG_RESULT($os_version_code)
;;
solaris*)
os_major_version=`uname -r | sed 's/\([[0-9]]*\).\([[0-9]]\)\.*\([[0-9]]*\)/\1/'`
os_minor_version=`uname -r | sed 's/\([[0-9]]*\).\([[0-9]]\)\.*\([[0-9]]*\)/\2/'`
os_micro_version=`uname -r | sed 's/\([[0-9]]*\).\([[0-9]]\)\.*\([[0-9]]*\)/\3/'`
os_major_version=`uname -r | sed 's/\([[0-9]]*\).\([[0-9]]*\)\.*\([[0-9]]*\)/\1/'`
os_minor_version=`uname -r | sed 's/\([[0-9]]*\).\([[0-9]]*\)\.*\([[0-9]]*\)/\2/'`
os_micro_version=`uname -r | sed 's/\([[0-9]]*\).\([[0-9]]*\)\.*\([[0-9]]*\)/\3/'`
test -z "$os_micro_version" && os_micro_version=0
os_version_expr="$os_major_version 100 * $os_minor_version 10 * + $os_micro_version + p q"
os_version_expr="$os_major_version 10000 * $os_minor_version 100 * + $os_micro_version + p q"
os_version_code=`echo "$os_version_expr" | dc`
AC_MSG_CHECKING(for Solaris release code)
AC_DEFINE_UNQUOTED(GLIBTOP_SOLARIS_RELEASE, $os_version_code,
[Solaris release code (eg. 251 for Solaris 2.5.1).])
[Solaris release code (eg. 20501 for Solaris 2.5.1).])
AC_MSG_RESULT($os_version_code)
;;
esac

View File

@@ -64,7 +64,7 @@ struct _glibtop_machine
int ticks; /* clock ticks, as returned by sysconf() */
unsigned long long boot; /* boot time, although it's ui32 in kstat */
void *libproc; /* libproc handle */
#if GLIBTOP_SOLARIS_RELEASE >= 560
#if GLIBTOP_SOLARIS_RELEASE >= 50600
void (*objname)(void *, uintptr_t, const char *, size_t);
struct ps_prochandle *(*pgrab)(pid_t, int, int *);
void (*pfree)(void *);