1 /*-------------------------------------------------------------------------
4 * include file for the bootstrapping code
7 * Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
8 * Portions Copyright (c) 1994, Regents of the University of California
10 * $Id: bootstrap.h,v 1.21 2001/01/24 19:43:20 momjian Exp $
12 *-------------------------------------------------------------------------
17 #include "access/itup.h"
18 #include "nodes/execnodes.h"
19 #include "utils/rel.h"
21 /* MAXATTR is the maximum number of attributes in a relation supported
22 * at bootstrap time (ie, the max possible in a system table).
26 typedef struct hashnode
28 int strnum; /* Index into string table */
29 struct hashnode *next;
32 #define EMITPROMPT printf("> ")
34 extern Relation reldesc;
35 extern Form_pg_attribute attrtypes[MAXATTR];
39 extern int BootstrapMain(int ac, char *av[]);
41 extern void index_register(char *heap, char *ind, IndexInfo *indexInfo);
43 extern void err_out(void);
44 extern void InsertOneTuple(Oid objectid);
45 extern void closerel(char *name);
46 extern void boot_openrel(char *name);
47 extern char *LexIDStr(int ident_num);
49 extern void DefineAttr(char *name, char *type, int attnum);
50 extern void InsertOneValue(Oid objectid, char *value, int i);
51 extern void InsertOneNull(int i);
52 extern char *MapArrayTypeName(char *s);
53 extern char *CleanUpStr(char *s);
54 extern int EnterString(char *str);
55 extern void build_indices(void);
57 extern int Int_yylex(void);
58 extern void Int_yyerror(const char *str);
61 #define BS_XLOG_BOOTSTRAP 1
62 #define BS_XLOG_STARTUP 2
63 #define BS_XLOG_CHECKPOINT 3
64 #define BS_XLOG_SHUTDOWN 4
66 #endif /* BOOTSTRAP_H */