diff -ru mountall-2.19/src/mountall.c mountall-2.19-rk1/src/mountall.c --- mountall-2.19/src/mountall.c 2010-09-28 10:35:17.000000000 +0200 +++ mountall-2.19-rk1/src/mountall.c 2011-01-19 23:43:25.000000000 +0100 @@ -671,7 +671,10 @@ mnt = find_mount (mntent->mnt_dir); if (mnt - && strcmp (mntent->mnt_type, "swap")) { + && strcmp (mntent->mnt_type, "swap") + && (strcmp (mntent->mnt_type, "none") + || strcmp (mntent->mnt_fsname, "none") + || strncmp (mntent->mnt_opts, "make-", 5))) { update_mount (mnt, mntent->mnt_fsname, mntent->mnt_passno != 0, @@ -1065,6 +1068,7 @@ /* Is this a parent of our mountpoint? */ if (mnt->mountpoint && other->mountpoint + && strlen (other->mountpoint) < strlen (mnt->mountpoint) && is_parent (other->mountpoint, mnt->mountpoint)){ if ((! mount_parent) || (strlen (mount_parent->mountpoint) < strlen (other->mountpoint))) @@ -1074,11 +1078,21 @@ /* Is this a parent mountpoint of our device? */ if ((! mnt->nodev) && other->mountpoint + && strlen (other->mountpoint) < strlen (mnt->device) && is_parent (other->mountpoint, mnt->device)){ if ((! device_parent) || (strlen (device_parent->mountpoint) < strlen (other->mountpoint))) device_parent = other; } + + /* Is this a make-xxx special call? */ + if (mnt->nodev + && !strcmp (mnt->device, "none") + && !strcmp (mnt->type, "none") + && !strcmp (mnt->mountpoint, other->mountpoint) + && !strncmp (mnt->opts, "make-", 5) + && !mount_parent) + mount_parent = other; } /* We nearly always depend on our mountpoint's parent, the only @@ -1816,6 +1830,18 @@ return; } } else if (mnt->nodev + && !strcmp (mnt->type, "none") + && !strcmp (mnt->device, "none") + && !strncmp (mnt->opts, "make-", 5)) { + nih_local char *make_opt = NULL; + make_opt = NIH_MUST (nih_sprintf (NULL, "--%s", mnt->opts)); + args = NIH_MUST (nih_str_array_new (NULL)); + NIH_MUST (nih_str_array_add (&args, NULL, &args_len, "mount")); + NIH_MUST (nih_str_array_add (&args, NULL, &args_len, make_opt)); + NIH_MUST (nih_str_array_add (&args, NULL, &args_len, mnt->mountpoint)); + spawn (mnt, args, TRUE, run_mount_finished); + return; + } else if (mnt->nodev && (! strcmp (mnt->type, "none"))) { nih_debug ("%s: placeholder", MOUNT_NAME (mnt)); mounted (mnt);