system.h File Reference

#include <sys/types.h>
#include <sys/stat.h>
#include <stdio.h>
#include <time.h>
#include <strings.h>
#include <errno.h>
#include <sys/file.h>
#include <ctype.h>

Include dependency graph for system.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  our_mntent

Defines

#define major(dev)   (((dev) >> 8) & 0xff)
#define minor(dev)   ((dev) & 0xff)
#define makedev(maj, min)   (((maj) << 8) | (min))
#define EXIT_FAILURE   1
#define SEEK_SET   0
#define SEEK_CUR   1
#define SEEK_END   2
#define F_OK   0
#define X_OK   1
#define W_OK   2
#define R_OK   4
#define dirent   direct
#define NLENGTH(direct)   ((direct)->d_namlen)
#define PATH_MAX   256
#define freecon(_c)
#define getfilecon(_fn, _c)   (-1)
#define lgetfilecon(_fn, _c)   (-1)
#define fgetfilecon(_fd, _c)   (-1)
#define setfilecon(_fn, _c)   (-1)
#define lsetfilecon(_fn, _c)   (-1)
#define fsetfilecon(_fd, _c)   (-1)
#define security_check_context(_c)   (0)
#define is_selinux_enabled()   (0)
#define matchpathcon_init(_fn)   (-1)
#define matchpathcon_fini()   (0)
#define matchpathcon(_fn, _fm, _c)   (-1)
#define rpm_execcon(_v, _fn, _av, _envp)   (0)
#define __progname   program_name
#define setprogname(pn)
#define setlocale(Category, Locale)
#define bindtextdomain(Domain, Directory)
#define textdomain(Domain)
#define _(Text)   Text
#define dgettext(DomainName, Text)   Text
#define N_(Text)   Text
#define S_IFSOCK   (0xc000)
#define S_ISLNK(mode)   ((mode & 0xf000) == S_IFLNK)
#define S_ISSOCK(mode)   ((mode & 0xf000) == S_IFSOCK)
#define lchown   chown
#define our_mntent   struct our_mntent
#define GETMNTENT_ONE   1
#define GETMNTENT_TWO   0
#define MOUNTED   "/etc/mnttab"

Typedefs

typedef char * security_context_t
typedef void * cap_t

Functions

char * memchr ()
char * stpcpy (char *dest, const char *src)
char * stpncpy (char *dest, const char *src, size_t n)
char * getenv (const char *name)
char * realpath (const char *path, char resolved_path[])
static void * _free (void *p)
 Wrapper to free(3), permit NULL, return NULL.
static void * _constfree (const void *p)
 Wrapper to free(3), permit NULL, return NULL.
void * xmalloc (size_t size)
void * xcalloc (size_t nmemb, size_t size)
void * xrealloc (void *ptr, size_t size)
char * xstrdup (const char *str)
void * vmefail (size_t size)
int setenv (const char *name, const char *value, int replace)
void unsetenv (const char *name)
struct our_mntentgetmntent (FILE *filep)

Variables

int errno
const char * program_name


Detailed Description

Definition in file system.h.


Define Documentation

#define _ ( Text   )     Text

#define __progname   program_name

Definition at line 305 of file system.h.

Referenced by argerror(), and main().

#define bindtextdomain ( Domain,
Directory   ) 

Definition at line 335 of file system.h.

Referenced by main().

#define dgettext ( DomainName,
Text   )     Text

Definition at line 340 of file system.h.

#define dirent   direct

Definition at line 140 of file system.h.

#define EXIT_FAILURE   1

Definition at line 115 of file system.h.

Referenced by argerror(), and main().

#define F_OK   0

Definition at line 130 of file system.h.

#define fgetfilecon ( _fd,
_c   )     (-1)

Definition at line 211 of file system.h.

#define freecon ( _c   ) 

Definition at line 207 of file system.h.

#define fsetfilecon ( _fd,
_c   )     (-1)

Definition at line 215 of file system.h.

#define getfilecon ( _fn,
_c   )     (-1)

Definition at line 209 of file system.h.

#define GETMNTENT_ONE   1

Definition at line 442 of file system.h.

#define GETMNTENT_TWO   0

Definition at line 443 of file system.h.

 
#define is_selinux_enabled (  )     (0)

Definition at line 219 of file system.h.

#define lchown   chown

Definition at line 405 of file system.h.

#define lgetfilecon ( _fn,
_c   )     (-1)

Definition at line 210 of file system.h.

#define lsetfilecon ( _fn,
_c   )     (-1)

Definition at line 214 of file system.h.

#define major ( dev   )     (((dev) >> 8) & 0xff)

Definition at line 60 of file system.h.

#define makedev ( maj,
min   )     (((maj) << 8) | (min))

Definition at line 62 of file system.h.

#define matchpathcon ( _fn,
_fm,
_c   )     (-1)

Definition at line 223 of file system.h.

 
#define matchpathcon_fini (  )     (0)

Definition at line 222 of file system.h.

#define matchpathcon_init ( _fn   )     (-1)

Definition at line 221 of file system.h.

#define minor ( dev   )     ((dev) & 0xff)

Definition at line 61 of file system.h.

#define MOUNTED   "/etc/mnttab"

Definition at line 456 of file system.h.

#define N_ ( Text   )     Text

Definition at line 343 of file system.h.

#define NLENGTH ( direct   )     ((direct)->d_namlen)

Definition at line 141 of file system.h.

#define our_mntent   struct our_mntent

Definition at line 440 of file system.h.

#define PATH_MAX   256

Definition at line 190 of file system.h.

#define R_OK   4

Definition at line 133 of file system.h.

#define rpm_execcon ( _v,
_fn,
_av,
_envp   )     (0)

Definition at line 225 of file system.h.

#define S_IFSOCK   (0xc000)

Definition at line 361 of file system.h.

#define S_ISLNK ( mode   )     ((mode & 0xf000) == S_IFLNK)

Definition at line 365 of file system.h.

#define S_ISSOCK ( mode   )     ((mode & 0xf000) == S_IFSOCK)

Definition at line 369 of file system.h.

#define security_check_context ( _c   )     (0)

Definition at line 217 of file system.h.

#define SEEK_CUR   1

Definition at line 126 of file system.h.

#define SEEK_END   2

Definition at line 127 of file system.h.

#define SEEK_SET   0

Definition at line 125 of file system.h.

#define setfilecon ( _fn,
_c   )     (-1)

Definition at line 213 of file system.h.

#define setlocale ( Category,
Locale   ) 

Definition at line 327 of file system.h.

Referenced by main().

#define setprogname ( pn   ) 

Value:

{ if ((__progname = strrchr(pn, '/')) != NULL) __progname++; \
    else __progname = pn;               \
  }

Definition at line 306 of file system.h.

Referenced by main().

#define textdomain ( Domain   ) 

Definition at line 337 of file system.h.

Referenced by main().

#define W_OK   2

Definition at line 132 of file system.h.

#define X_OK   1

Definition at line 131 of file system.h.


Typedef Documentation

typedef void* cap_t

Definition at line 243 of file system.h.

typedef char* security_context_t

Definition at line 205 of file system.h.


Function Documentation

static void* _constfree ( const void *  p  )  [inline, static]

Wrapper to free(3), permit NULL, return NULL.

For documenting cases where const is used to protect long-lived non-const data that's supposed to be freed.

Parameters:
p memory to free
Returns:
NULL always

Definition at line 258 of file system.h.

static void* _free ( void *  p  )  [inline, static]

Wrapper to free(3), permit NULL, return NULL.

Parameters:
p memory to free
Returns:
NULL always

Definition at line 234 of file system.h.

Referenced by main().

char* getenv ( const char *  name  ) 

struct our_mntent* getmntent ( FILE *  filep  )  [read]

char* memchr (  ) 

char* realpath ( const char *  path,
char  resolved_path[] 
)

int setenv ( const char *  name,
const char *  value,
int  replace 
)

char* stpcpy ( char *  dest,
const char *  src 
)

char* stpncpy ( char *  dest,
const char *  src,
size_t  n 
)

void unsetenv ( const char *  name  ) 

void* vmefail ( size_t  size  ) 

void* xcalloc ( size_t  nmemb,
size_t  size 
)

void* xmalloc ( size_t  size  ) 

Referenced by build(), and main().

void* xrealloc ( void *  ptr,
size_t  size 
)

Todo:
Annotate ptr with returned/out.

Referenced by main().

char* xstrdup ( const char *  str  ) 

Referenced by buildForTarget(), and main().


Variable Documentation

int errno

Referenced by isSpecFile().

const char* program_name

Definition at line 4 of file rpm2cpio.c.


Generated on Sat Apr 18 17:12:59 2009 for rpm by  doxygen 1.5.7.1