2007-05-05 22:05:43 +00:00
|
|
|
/*
|
|
|
|
*
|
|
|
|
* (c) 2007 Laurent Vivier <Laurent@lvivier.info>
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
typedef struct emile_config {
|
|
|
|
FILE* fd;
|
|
|
|
char* header;
|
|
|
|
int header_size;
|
|
|
|
char* current;
|
|
|
|
int current_size;
|
|
|
|
} emile_config;
|
|
|
|
|
|
|
|
enum {
|
|
|
|
CONFIG_END,
|
2007-05-12 19:28:08 +00:00
|
|
|
CONFIG_GESTALTID,
|
|
|
|
CONFIG_VGA,
|
|
|
|
CONFIG_MODEM,
|
|
|
|
CONFIG_PRINTER,
|
2007-05-05 22:05:43 +00:00
|
|
|
CONFIG_PARTITION,
|
|
|
|
CONFIG_FIRST_LEVEL,
|
|
|
|
CONFIG_SECOND_LEVEL,
|
|
|
|
CONFIG_TIMEOUT,
|
|
|
|
CONFIG_DEFAULT,
|
|
|
|
CONFIG_TITLE,
|
|
|
|
CONFIG_KERNEL,
|
2007-05-09 19:08:23 +00:00
|
|
|
CONFIG_KERNEL_MAP,
|
2007-05-05 22:05:43 +00:00
|
|
|
CONFIG_ARGS,
|
|
|
|
CONFIG_INITRD,
|
2007-05-09 19:08:23 +00:00
|
|
|
CONFIG_INITRD_MAP,
|
2007-05-05 22:05:43 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
extern emile_config* emile_config_open(char* name);
|
|
|
|
extern void emile_config_close(emile_config* config);
|
|
|
|
|
|
|
|
extern int emile_config_read_first_entry(emile_config* config);
|
|
|
|
extern int emile_config_read_next(emile_config* config);
|
|
|
|
|
2007-05-06 23:12:29 +00:00
|
|
|
extern int emile_config_get(emile_config* config, int tag, ...);
|