#include "system.h"
#include <rpmio_internal.h>
#include <rpmbuild.h>
#include "debug.h"
Include dependency graph for parsePrep.c:
Go to the source code of this file.
Functions | |
static int | checkOwners (const char *urlfn) |
Check that file owner and group are known. | |
static char * | doPatch (Spec spec, int c, int strip, const char *db, int reverse, int removeEmpties) |
Expand patchN macro into prep scriptlet. | |
static const char * | doUntar (Spec spec, int c, int quietly) |
Expand setup macro into prep scriptlet. | |
static int | doSetupMacro (Spec spec, char *line) |
Parse setup macro. | |
static int | doPatchMacro (Spec spec, char *line) |
Parse patch line. | |
static int | prepFetch (Spec spec) |
Check that all sources/patches/icons exist locally, fetching if necessary. | |
int | parsePrep (Spec spec, int verify) |
Parse %prep section of a spec file. | |
Variables | |
static int | leaveDirs |
static int | skipDefaultAction |
static int | createDir |
static int | quietly |
static const char * | dirName = NULL |
static struct poptOption | optionsTable [] |
Definition in file parsePrep.c.
|
Check that file owner and group are known.
Definition at line 38 of file parsePrep.c. References _, errno, getGname(), getUname(), Lstat(), RPMERR_BADSPEC, rpmError, and strerror. |
|
Expand patchN macro into prep scriptlet.
Definition at line 69 of file parsePrep.c. References _, _free(), checkOwners(), COMPRESSED_BZIP2, COMPRESSED_LZMA, COMPRESSED_LZOP, COMPRESSED_NOT, COMPRESSED_OTHER, COMPRESSED_ZIP, Source::flags, Spec_s::force, isCompressed(), Source::next, Source::num, RPMERR_BADSPEC, rpmError, RPMFILE_PATCH, rpmGenPath(), rpmGetPath(), Source::source, Spec_s::sources, URL_IS_DASH, URL_IS_FTP, URL_IS_HKP, URL_IS_HTTP, URL_IS_HTTPS, URL_IS_PATH, URL_IS_UNKNOWN, and urlPath(). |
|
Parse patch line.
Definition at line 449 of file parsePrep.c. References _, Spec_s::line, Spec_s::lineNum, parseNum(), RPMERR_BADSPEC, and rpmError. |
|
Parse setup macro.
Definition at line 293 of file parsePrep.c. References _, _free(), addMacro(), appendLineStringBuf, appendStringBuf, argv, Spec_s::buildSubdir, createDir, dirName, doUntar(), freeStringBuf(), getStringBuf(), Package_s::header, headerNVR(), leaveDirs, Spec_s::lineNum, Spec_s::macros, MKDIR_P, newStringBuf(), Source::num, optionsTable, Spec_s::packages, parseNum(), Spec_s::prep, quietly, RMIL_SPEC, Spec_s::rootURL, RPMERR_BADSPEC, rpmError, rpmExpand(), rpmGenPath(), skipDefaultAction, urlPath(), and xstrdup(). Referenced by parsePrep(). |
|
Expand setup macro into prep scriptlet.
Definition at line 182 of file parsePrep.c. References _, _free(), checkOwners(), COMPRESSED_BZIP2, COMPRESSED_LZMA, COMPRESSED_LZOP, COMPRESSED_NOT, COMPRESSED_OTHER, COMPRESSED_ZIP, Source::flags, Spec_s::force, isCompressed(), Source::next, Source::num, RPMERR_BADSPEC, rpmError, RPMFILE_SOURCE, rpmGenPath(), rpmGetPath(), rpmIsVerbose, Source::source, Spec_s::sources, stpcpy(), URL_IS_DASH, URL_IS_FTP, URL_IS_HKP, URL_IS_HTTP, URL_IS_HTTPS, URL_IS_PATH, URL_IS_UNKNOWN, and urlPath(). Referenced by doSetupMacro(). |
|
Check that all sources/patches/icons exist locally, fetching if necessary.
Definition at line 562 of file parsePrep.c. References _, _free(), errno, Source::flags, ftpStrerror(), Lstat(), Source::next, Source::num, RPMERR_BADFILENAME, rpmError, RPMFILE_ICON, RPMFILE_PATCH, RPMFILE_SOURCE, rpmGenPath(), rpmMkdirPath(), RPMRC_OK, Source::source, Spec_s::sources, strerror, and urlGetFile(). Referenced by parsePrep(). |
|
Definition at line 18 of file parsePrep.c. Referenced by doSetupMacro(). |
|
Definition at line 20 of file parsePrep.c. Referenced by doSetupMacro(), rpmalAllFileSatisfiesDepend(), rpmdbFindByFile(), and rpmGetFilesystemUsage(). |
|
Definition at line 16 of file parsePrep.c. Referenced by doSetupMacro(). |
|
Initial value: { { NULL, 'a', POPT_ARG_STRING, NULL, 'a', NULL, NULL}, { NULL, 'b', POPT_ARG_STRING, NULL, 'b', NULL, NULL}, { NULL, 'c', 0, &createDir, 0, NULL, NULL}, { NULL, 'D', 0, &leaveDirs, 0, NULL, NULL}, { NULL, 'n', POPT_ARG_STRING, &dirName, 0, NULL, NULL}, { NULL, 'T', 0, &skipDefaultAction, 0, NULL, NULL}, { NULL, 'q', 0, &quietly, 0, NULL, NULL}, { 0, 0, 0, 0, 0, NULL, NULL} } Definition at line 22 of file parsePrep.c. |
|
Definition at line 18 of file parsePrep.c. Referenced by doSetupMacro(). |
|
Definition at line 16 of file parsePrep.c. Referenced by doSetupMacro(). |