summaryrefslogtreecommitdiffstats
path: root/loader2/method.h
blob: 2d5e120caf626474f642645b07aa8028fdaa8e53 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#ifndef H_METHOD
#define H_METHOD

#include "modules.h"
#include "moduledeps.h"
#include "loader.h"
#include <kudzu/kudzu.h>

struct installMethod {
    char * name;
    char * shortname;
    int network;
    enum deviceClass deviceType;			/* for pcmcia */
    char * (*mountImage)(struct installMethod * method,
                         char * location, struct loaderData_s * loaderData,
                         moduleInfoSet modInfo, moduleList modLoaded,
                         moduleDeps * modDepsPtr, int flags);
};


int umountLoopback(char * mntpoint, char * device);
int mountLoopback(char * fsystem, char * mntpoint, char * device);

char * validIsoImages(char * dirName);
int readStampFileFromIso(char *file, char **descr, char **timestamp);
void queryIsoMediaCheck(char * isoDir, int flags);

int verifyStamp(char * path);

void umountStage2(void);
int mountStage2(char * path);
int copyFileAndLoopbackMount(int fd, char * dest, int flags,
                             char * device, char * mntpoint);
int getFileFromBlockDevice(char *device, char *path, char * dest);

void copyUpdatesImg(char * path);
void copyProductImg(char * path);
int copyDirectory(char * from, char * to);

void setMethodFromCmdline(char * arg, struct loaderData_s * ld);

#endif