00001 #ifndef H_MISC
00002 #define H_MISC
00003 
00009 #include <string.h>
00010 
00011 #ifdef __cplusplus
00012 extern "C" {
00013 #endif
00014 
00022 rpmRC rpmMkdirPath (const char * dpath, const char * dname)
00023         
00024         ;
00025 
00033  char ** splitString(const char * str, int length, char sep)
00034         ;
00035 
00040 void freeSplitString(  char ** list)
00041         ;
00042 
00049  static inline
00050  char * stripTrailingChar( char * s, char c)
00051         
00052 {
00053     char * t;
00054 
00055     for (t = s + strlen(s) - 1; *t == c && t >= s; t--)
00056         *t = '\0';
00057 
00058     return s;
00059 }
00060 
00068 int dosetenv(const char * name, const char * value, int overwrite)
00069         
00070         ;
00071 
00077 int doputenv(const char * str)
00078         
00079         ;
00080 
00094 int makeTempFile( const char * prefix,
00095                   const char ** fnptr,
00096                  FD_t * fdptr)
00097         
00098 
00099         
00100 ;
00101 
00106  char * currentDirectory(void)
00107         ;
00108 
00109 #ifdef __cplusplus
00110 }
00111 #endif
00112 
00113 #endif