gschem

parsecmd.c File Reference

#include <config.h>
#include <version.h>
#include <missing.h>
#include <stdio.h>
#include <ctype.h>
#include "gschem.h"
Include dependency graph for parsecmd.c:

Go to the source code of this file.

Defines

#define GETOPT_OPTIONS   "c:hL:o:pqr:s:vV"

Functions

static void usage (char *cmd)
 Print brief help message and exit.
static void version ()
 Print version info and exit.
int parse_commandline (int argc, char *argv[])
 Parse gschem command-line options.

Variables

char * optarg
int optind
SCM s_pre_load_expr = SCM_EOL
SCM s_post_load_expr = SCM_EOL

Define Documentation

#define GETOPT_OPTIONS   "c:hL:o:pqr:s:vV"

Definition at line 36 of file parsecmd.c.


Function Documentation

static void usage ( char *  cmd) [static]
Function Description
Print brief help message describing gschem usage & command-line options, then exit with exit_status.
Parameters:
cmdFirst element of argv (name of program as run).

Definition at line 79 of file parsecmd.c.

static void version ( ) [static]
Function Description
Print gEDA version, and copyright/warranty notices, and exit with exit status 0.

Definition at line 113 of file parsecmd.c.

int parse_commandline ( int  argc,
char *  argv[] 
)
Function Description
Parse command line options, displaying usage message or version information as required.
Parameters:
argcNumber of command-line arguments.
argvArray of command-line arguments.
Returns:
index into argv of first non-option argument.

Definition at line 136 of file parsecmd.c.

Here is the call graph for this function:


Variable Documentation

char* optarg
int optind
SCM s_pre_load_expr = SCM_EOL

Contains a Scheme expression arising from command-line arguments. This is evaluated after initialising gschem, but before loading any rc files.

Definition at line 63 of file parsecmd.c.

SCM s_post_load_expr = SCM_EOL

Contains a Scheme expression arising from command-line arguments. This is evaluated after loading gschem and any schematic files specified on the command-line.

Definition at line 69 of file parsecmd.c.

 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines