rpm
4.10.0
|
00001 #ifndef _RPMFILEUTIL_H 00002 #define _RPMFILEUTIL_H 00003 00009 #include <rpm/rpmutil.h> 00010 #include <rpm/rpmio.h> 00011 #include <rpm/rpmpgp.h> 00012 #include <rpm/argv.h> 00013 00014 #ifdef __cplusplus 00015 extern "C" { 00016 #endif 00017 00020 typedef enum rpmCompressedMagic_e { 00021 COMPRESSED_NOT = 0, 00022 COMPRESSED_OTHER = 1, 00023 COMPRESSED_BZIP2 = 2, 00024 COMPRESSED_ZIP = 3, 00025 COMPRESSED_LZMA = 4, 00026 COMPRESSED_XZ = 5, 00027 COMPRESSED_LZIP = 6, 00028 COMPRESSED_LRZIP = 7, 00029 COMPRESSED_7ZIP = 8 00030 } rpmCompressedMagic; 00031 00041 int rpmDoDigest(int algo, const char * fn,int asAscii, 00042 unsigned char * digest, rpm_loff_t * fsizep); 00043 00049 FD_t rpmMkTemp(char *templ); 00050 00061 FD_t rpmMkTempFile(const char * prefix, char **fn); 00062 00071 int rpmioMkpath(const char * path, mode_t mode, uid_t uid, gid_t gid); 00072 00081 int rpmMkdirs(const char *root, const char *pathstr); 00082 00088 char * rpmCleanPath (char * path); 00089 00100 char * rpmGenPath (const char * urlroot, 00101 const char * urlmdir, 00102 const char * urlfile); 00103 00109 char * rpmGetPath (const char * path, ...) RPM_GNUC_NULL_TERMINATED; 00110 00118 int rpmGlob(const char * patterns, int * argcPtr, ARGV_t * argvPtr); 00119 00125 char * rpmEscapeSpaces(const char * s); 00126 00133 int rpmFileIsCompressed (const char * file, rpmCompressedMagic * compressed); 00134 00141 int rpmFileHasSuffix(const char *path, const char *suffix); 00142 00147 char * rpmGetCwd(void); 00148 00149 #ifdef __cplusplus 00150 } 00151 #endif 00152 #endif /* _RPMFILEUTIL_H */