Blame doc/reference/html/libgtop-white-paper-overview.html

Packit d37888
Packit d37888
<html>
Packit d37888
<head>
Packit d37888
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
Packit d37888
<title>Overview: Libgtop Reference Manual</title>
Packit d37888
<meta name="generator" content="DocBook XSL Stylesheets Vsnapshot">
Packit d37888
<link rel="home" href="index.html" title="Libgtop Reference Manual">
Packit d37888
<link rel="up" href="libgtop-white-paper.html" title="White paper">
Packit d37888
<link rel="prev" href="libgtop-white-paper.html" title="White paper">
Packit d37888
<link rel="next" href="libgtop-lib.html" title="Libgtop Library Reference">
Packit d37888
<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
Packit d37888
<link rel="stylesheet" href="style.css" type="text/css">
Packit d37888
</head>
Packit d37888
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
Packit d37888
Packit d37888
Packit d37888
Home
Packit d37888
Up
Packit d37888
Prev
Packit d37888
Next
Packit d37888
Packit d37888
Packit d37888

Packit d37888
Overview
Packit d37888

This section should give you a short overview on how LibGTop

Packit d37888
      was developed, which things needed to be considered and how it 
Packit d37888
      works.

Packit d37888
Packit d37888

Packit d37888
Interface Design: Things that need to be considered
Packit d37888

Packit d37888
At the very beginning, it was necessary to collect all the data the library part
Packit d37888
should provide and put them into some C structures. This was not that easiy as it
Packit d37888
might sound since LibGTop should be portable to any modern UNIX system with a common
Packit d37888
library part on all those systems, but the data that should be returned vary from
Packit d37888
system to system. For instance some systems support shared memory, but some others
Packit d37888
may not.

Packit d37888

Packit d37888
The header files where we define these C structures (which are system-independent) are
Packit d37888
shared between client and server. This way we can call the system dependent code
Packit d37888
directly where we do not need any special privileges to do so.

Packit d37888

Packit d37888
All of those structures contain a @code{flags} member which is interpreted as a bit
Packit d37888
mask and tells the caller of the library functions which of the fields in the returned
Packit d37888
structure are valid and which are not.

Packit d37888
Packit d37888
Packit d37888

Packit d37888
Server Implementation: The LibGTop "server"
Packit d37888

Packit d37888
The LibGTop @dfn{server} is a setgid/setuid binary which contains all the system
Packit d37888
dependent code which needs special privileges. It is only build if it's required
Packit d37888
on the current system (for instance, the Linux kernel provides all the required
Packit d37888
data via its @file{/proc} filesystem so we do not need the server at all) and it
Packit d37888
only contains the @dfn{features} which need privileges.

Packit d37888

Packit d37888
Whenever we do not need any privileges to get all the data for some of the requested
Packit d37888
structures (here called @dfn{features}) the library calls the sysdeps code directly
Packit d37888
rather than using the server.

Packit d37888
Packit d37888
Packit d37888
Packit d37888

Generated by GTK-Doc V1.25
Packit d37888
</body>
Packit d37888
</html>