build/rpmfc.h

Go to the documentation of this file.
00001 #ifndef _H_RPMFC_
00002 #define _H_RPMFC_
00003 
00004 #undef  FILE_RCSID
00005 #include "magic.h"
00006 
00007 /*@-exportlocal@*/
00008 /*@unchecked@*/
00009 extern int _rpmfc_debug;
00010 /*@=exportlocal@*/
00011 
00014 typedef /*@abstract@*/ struct rpmfc_s * rpmfc;
00015 
00018 struct rpmfc_s {
00019     int nfiles;         
00020     int fknown;         
00021     int fwhite;         
00022     int ix;             
00023     int skipProv;       
00024     int skipReq;        
00025     int tracked;        
00026     size_t brlen;       
00028     ARGV_t fn;          
00029     ARGI_t fcolor;      
00030     ARGI_t fcdictx;     
00031     ARGI_t fddictx;     
00032     ARGI_t fddictn;     
00033     ARGV_t cdict;       
00034     ARGV_t ddict;       
00035     ARGI_t ddictx;      
00037 /*@relnull@*/
00038     rpmds provides;     
00039 /*@relnull@*/
00040     rpmds requires;     
00042     StringBuf sb_java;  
00043     StringBuf sb_perl;  
00044     StringBuf sb_python;
00046 };
00047 
00050 enum FCOLOR_e {
00051     RPMFC_BLACK                 = 0,
00052     RPMFC_ELF32                 = (1 <<  0),
00053     RPMFC_ELF64                 = (1 <<  1),
00054 #define RPMFC_ELF       (RPMFC_ELF32|RPMFC_ELF64)
00055 
00056     RPMFC_MODULE                = (1 <<  7),
00057     RPMFC_EXECUTABLE            = (1 <<  8),
00058     RPMFC_SCRIPT                = (1 <<  9),
00059     RPMFC_TEXT                  = (1 << 10),
00060     RPMFC_DATA                  = (1 << 11),    /* XXX unused */
00061     RPMFC_DOCUMENT              = (1 << 12),
00062     RPMFC_STATIC                = (1 << 13),
00063     RPMFC_NOTSTRIPPED           = (1 << 14),
00064     RPMFC_COMPRESSED            = (1 << 15),
00065 
00066     RPMFC_DIRECTORY             = (1 << 16),
00067     RPMFC_SYMLINK               = (1 << 17),
00068     RPMFC_DEVICE                = (1 << 18),
00069     RPMFC_LIBRARY               = (1 << 19),
00070     RPMFC_ARCHIVE               = (1 << 20),
00071     RPMFC_FONT                  = (1 << 21),
00072     RPMFC_IMAGE                 = (1 << 22),
00073     RPMFC_MANPAGE               = (1 << 23),
00074 
00075     RPMFC_PERL                  = (1 << 24),
00076     RPMFC_JAVA                  = (1 << 25),
00077     RPMFC_PYTHON                = (1 << 26),
00078     RPMFC_PHP                   = (1 << 27),
00079     RPMFC_TCL                   = (1 << 28),
00080     RPMFC_MONO                  = (1 << 6),
00081 
00082     RPMFC_WHITE                 = (1 << 29),
00083     RPMFC_INCLUDE               = (1 << 30),
00084     RPMFC_ERROR                 = (1 << 31)
00085 };
00086 typedef enum FCOLOR_e FCOLOR_t;
00087 
00090 struct rpmfcTokens_s {
00091 /*@observer@*/
00092     const char * token;
00093     int colors;
00094 };
00095 
00098 typedef struct rpmfcTokens_s * rpmfcToken;
00099 
00100 #ifdef __cplusplus
00101 extern "C" {
00102 #endif
00103 
00111 int rpmfcExec(ARGV_t av, StringBuf sb_stdin, /*@out@*/ StringBuf * sb_stdoutp,
00112                 int failnonzero)
00113         /*@globals rpmGlobalMacroContext, h_errno, fileSystem, internalState @*/
00114         /*@modifies *sb_stdoutp, rpmGlobalMacroContext,
00115                 fileSystem, internalState @*/
00116         /*@requires maxSet(sb_stdoutp) >= 0 @*/;
00117 
00123 /*@-exportlocal@*/
00124 int rpmfcColoring(const char * fmstr)
00125         /*@*/;
00126 /*@=exportlocal@*/
00127 
00135 /*@-exportlocal@*/
00136 void rpmfcPrint(/*@null@*/ const char * msg, rpmfc fc, /*@null@*/ FILE * fp)
00137         /*@globals fileSystem @*/
00138         /*@modifies *fp, fc, fileSystem @*/;
00139 /*@=exportlocal@*/
00140 
00146 /*@-exportlocal@*/
00147 /*@null@*/
00148 rpmfc rpmfcFree(/*@only@*/ /*@null@*/ rpmfc fc)
00149         /*@modifies fc @*/;
00150 /*@=exportlocal@*/
00151 
00156 /*@-exportlocal@*/
00157 rpmfc rpmfcNew(void)
00158         /*@*/;
00159 /*@=exportlocal@*/
00160 
00168 /*@-exportlocal@*/
00169 int rpmfcClassify(rpmfc fc, ARGV_t argv, /*@null@*/ int16_t * fmode)
00170         /*@globals fileSystem, internalState @*/
00171         /*@modifies fc, fileSystem, internalState @*/;
00172 /*@=exportlocal@*/
00173 
00179 /*@-exportlocal@*/
00180 int rpmfcApply(rpmfc fc)
00181         /*@modifies fc @*/;
00182 /*@=exportlocal@*/
00183 
00190 int rpmfcGenerateDepends(const Spec spec, Package pkg)
00191         /*@globals rpmGlobalMacroContext, h_errno, fileSystem, internalState @*/
00192         /*@modifies pkg->cpioList, pkg->header,
00193                 rpmGlobalMacroContext, fileSystem, internalState @*/;
00194 
00195 #ifdef __cplusplus
00196 }
00197 #endif
00198 
00199 #endif /* _H_RPMFC_ */

Generated on Fri Oct 12 08:44:53 2007 for rpm by  doxygen 1.5.2