summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuillaume Cottenceau <gc@mandriva.com>2003-11-04 12:35:55 +0000
committerGuillaume Cottenceau <gc@mandriva.com>2003-11-04 12:35:55 +0000
commit23ad4c54181858aa61c954b057926db748e4b5ef (patch)
tree5896cfa3e4766127d909002d5c151c73b67e9102
parent10a60a696635ed47bf4143a08c4eeb5dff278921 (diff)
downloaddrakx-23ad4c54181858aa61c954b057926db748e4b5ef.tar
drakx-23ad4c54181858aa61c954b057926db748e4b5ef.tar.gz
drakx-23ad4c54181858aa61c954b057926db748e4b5ef.tar.bz2
drakx-23ad4c54181858aa61c954b057926db748e4b5ef.tar.xz
drakx-23ad4c54181858aa61c954b057926db748e4b5ef.zip
in mandrake-move, mount cdrom as supermount
-rw-r--r--mdk-stage1/cdrom.c4
-rw-r--r--mdk-stage1/mount.c9
2 files changed, 13 insertions, 0 deletions
diff --git a/mdk-stage1/cdrom.c b/mdk-stage1/cdrom.c
index 98cea4765..7d14cdebb 100644
--- a/mdk-stage1/cdrom.c
+++ b/mdk-stage1/cdrom.c
@@ -41,7 +41,11 @@ static int mount_that_cd_device(char * dev_name)
strcpy(device_fullname, "/dev/");
strcat(device_fullname, dev_name);
+#ifdef MANDRAKE_MOVE
+ return my_mount(device_fullname, IMAGE_LOCATION, "supermount", 0);
+#else
return my_mount(device_fullname, IMAGE_LOCATION, "iso9660", 0);
+#endif
}
diff --git a/mdk-stage1/mount.c b/mdk-stage1/mount.c
index 0b207c368..d5ecba619 100644
--- a/mdk-stage1/mount.c
+++ b/mdk-stage1/mount.c
@@ -22,6 +22,7 @@
#include <stdlib.h>
#include <unistd.h>
#include <string.h>
+#include <stdio.h>
#include <sys/mount.h>
#include <sys/stat.h>
#include <sys/types.h>
@@ -180,6 +181,14 @@ int my_mount(char *dev, char *location, char *fs, int force_rw)
}
}
+ if (!strcmp(fs, "supermount")) {
+ my_insmod("supermount", ANY_DRIVER_TYPE, NULL);
+ my_insmod("isofs", ANY_DRIVER_TYPE, NULL);
+ opts = alloca(500);
+ sprintf(opts, "dev=%s,fs=iso9660,tray_lock=always", dev);
+ dev = "none";
+ }
+
#ifndef DISABLE_MEDIAS
if (!strcmp(fs, "vfat")) {
my_insmod("vfat", ANY_DRIVER_TYPE, NULL);