|
Data Structures |
| struct | MacroEntry_s |
| struct | MacroContext_s |
Defines |
| #define | RMIL_DEFAULT -15 |
| | Markers for sources of macros added throughout rpm.
|
| #define | RMIL_MACROFILES -13 |
| #define | RMIL_RPMRC -11 |
| #define | RMIL_CMDLINE -7 |
| #define | RMIL_TARBALL -5 |
| #define | RMIL_SPEC -3 |
| #define | RMIL_OLDSPEC -1 |
| #define | RMIL_GLOBAL 0 |
Typedefs |
| typedef struct MacroEntry_s * | MacroEntry |
| typedef struct MacroContext_s * | MacroContext |
| typedef enum rpmCompressedMagic_e | rpmCompressedMagic |
Enumerations |
| enum | rpmCompressedMagic_e { COMPRESSED_NOT = 0,
COMPRESSED_OTHER = 1,
COMPRESSED_BZIP2 = 2,
COMPRESSED_ZIP = 3
} |
Functions |
| void | rpmDumpMacroTable (MacroContext mc, FILE *fp) |
| | Print macros to file stream.
|
| int | expandMacros (void *spec, MacroContext mc, char *sbuf, size_t slen) |
| | Expand macro into buffer.
|
| void | addMacro (MacroContext mc, const char *n, const char *o, const char *b, int level) |
| | Add macro to context.
|
| void | delMacro (MacroContext mc, const char *n) |
| | Delete macro from context.
|
| int | rpmDefineMacro (MacroContext mc, const char *macro, int level) |
| | Define macro in context.
|
| void | rpmLoadMacros (MacroContext mc, int level) |
| | Load macros from specific context into global context.
|
| void | rpmInitMacros (MacroContext mc, const char *macrofiles) |
| | Initialize global macro context from set of macrofile(s).
|
| void | rpmFreeMacros (MacroContext mc) |
| | Destroy macro context.
|
| int | isCompressed (const char *file, rpmCompressedMagic *compressed) |
| | Return type of compression used in file.
|
| char * | rpmExpand (const char *arg,...) |
| | Return (malloc'ed) concatenated macro expansion(s).
|
| char * | rpmCleanPath (char *path) |
| | Canonicalize file path.
|
| const char * | rpmGetPath (const char *path,...) |
| | Return (malloc'ed) expanded, canonicalized, file path.
|
| const char * | rpmGenPath (const char *urlroot, const char *urlmdir, const char *urlfile) |
| | Merge 3 args into path, any or all of which may be a url.
|
| int | rpmExpandNumeric (const char *arg) |
| | Return macro expansion as a numeric value.
|
Variables |
| MacroContext | rpmGlobalMacroContext |
| MacroContext | rpmCLIMacroContext |
| const char * | macrofiles |
| | List of macro files to read when configuring rpm.
|
| const char* rpmGenPath |
( |
const char * |
urlroot, |
|
|
const char * |
urlmdir, |
|
|
const char * |
urlfile | |
|
) |
| | |
Merge 3 args into path, any or all of which may be a url.
The leading part of the first URL encountered is used for the result, other URL prefixes are discarded, permitting a primitive form of URL inheiritance.
- Parameters:
-
| urlroot | root URL (often path to chroot, or NULL) |
| urlmdir | directory URL (often a directory, or NULL) |
| urlfile | file URL (often a file, or NULL) |
- Returns:
- expanded, merged, canonicalized path (malloc'ed)
Definition at line 1889 of file macro.c.