Data Structures | Defines | Functions | Variables

build/parseSpec.c File Reference

Top level dispatcher for spec file parsing. More...

#include "system.h"
#include <rpmio_internal.h>
#include <rpmcb.h>
#include <argv.h>
#include <rpmbuild.h>
#include "rpmds.h"
#include "rpmts.h"
#include "debug.h"
Include dependency graph for parseSpec.c:

Go to the source code of this file.

Data Structures

struct  PartRec

Defines

#define _RPMTAG_INTERNAL

Functions

static void initParts (struct PartRec *p)
rpmParseState isPart (Spec spec)
 Check line for section separator, return next parser state.
static int matchTok (const char *token, const char *line)
void handleComments (char *s)
 Truncate comment lines.
static void forceIncludeFile (Spec spec, const char *fileName)
static int restoreFirstChar (Spec spec)
static int copyNextLineFromOFI (Spec spec, OFI_t *ofi, rpmStripFlags strip)
static int copyNextLineFinish (Spec spec, int strip)
static int readLineFromOFI (Spec spec, OFI_t *ofi)
int readLine (Spec spec, rpmStripFlags strip)
 Read next line from spec file.
void closeSpec (Spec spec)
 Stop reading from spec file, freeing resources.
static int genSourceRpmName (Spec spec)
int parseSpec (rpmts ts, const char *specFile, const char *rootURL, int recursing, const char *passPhrase, const char *cookie, int anyarch, int force, int verify)
 Parse spec file into spec control structure.

Variables

static struct PartRec partList []
int noLang

Detailed Description

Top level dispatcher for spec file parsing.

Definition in file parseSpec.c.


Define Documentation

#define _RPMTAG_INTERNAL

Definition at line 12 of file parseSpec.c.


Function Documentation

static int copyNextLineFinish ( Spec  spec,
int  strip 
) [static]
static int copyNextLineFromOFI ( Spec  spec,
OFI_t ofi,
rpmStripFlags  strip 
) [static]
static void forceIncludeFile ( Spec  spec,
const char *  fileName 
) [static]

Definition at line 148 of file parseSpec.c.

References OpenFileInfo::fileName, Spec_s::fileStack, newOpenFileInfo(), OpenFileInfo::next, and xstrdup().

Referenced by readLine().

static int genSourceRpmName ( Spec  spec ) [inline, static]
static void initParts ( struct PartRec p ) [inline, static]

Definition at line 57 of file parseSpec.c.

References PartRec::len, and PartRec::token.

Referenced by isPart().

static int matchTok ( const char *  token,
const char *  line 
) [static]

Definition at line 117 of file parseSpec.c.

References SKIPNONSPACE, SKIPSPACE, and xstrncasecmp().

Referenced by readLine().

static int readLineFromOFI ( Spec  spec,
OFI_t ofi 
) [static]
static int restoreFirstChar ( Spec  spec ) [static]

Definition at line 161 of file parseSpec.c.

References Spec_s::nextline, and Spec_s::nextpeekc.

Referenced by readLine().


Variable Documentation

int noLang

Definition at line 61 of file poptBT.c.

struct PartRec partList[] [static]

Referenced by isPart().