~ubuntu-branches/ubuntu/raring/partman-target/raring

« back to all changes in this revision

Viewing changes to finish.d/fstab_removable_media_entries

  • Committer: Bazaar Package Importer
  • Author(s): Colin Watson
  • Date: 2011-07-15 10:58:09 UTC
  • mfrom: (1.2.11 sid)
  • Revision ID: james.westby@ubuntu.com-20110715105809-xa1wc5blrlkz870v
Tags: 73ubuntu1
* Resynchronise with Debian.  Remaining changes:
  - Disable automatic mounting of USB removable devices.
  - Mount floppies with 'exec' and 'utf8'.
  - Use the path of the file associated with a loop device in /etc/fstab,
    rather than the filesystem's UUID or the loop device path.
  - Always set the loop option for loop devices.
  - Remove critical system files from the existing filesystem before
    installing.
  - Preserve the UID and GID of the initial user, if possible.  Requires a
    patch to user-setup.
  - Check that all system partitions are formatted.
  - Stop adding removable devices to /etc/fstab, now that apt knows how to
    find CD-ROM devices using libudev.
  - Mount /proc with nodev,noexec,nosuid.
  - Notify user-setup if there is an encrypted home partition present.
* Stop creating /var/run and /var/lock on the root filesystem, now that
  Oneiric has migrated these to being symlinks into /run (LP: #810700).

Show diffs side-by-side

added added

removed removed

Lines of Context:
33
33
        options=$3
34
34
        shift; shift; shift
35
35
        mkdir -p /target$MEDIA
36
 
        if [ "$1" ]; then
 
36
        symlink_to_0=1
 
37
        if [ "`udpkg --print-os`" = kfreebsd ]; then
 
38
                symlink_to_0=""
 
39
        fi
 
40
        if [ "$1" ] && [ "$symlink_to_0" ] ; then
37
41
                rm_dir_or_link /target$MEDIA/$category
38
42
                ln -s ${category}0 /target$MEDIA/$category
39
43
        fi
40
44
        number=0
41
45
        while [ "$1" ]; do
42
46
                mount_point="$MEDIA/$category$number"
 
47
                if [ ! "$symlink_to_0" ] && [ "$number" = 0 ]; then
 
48
                        mount_point="$MEDIA/$category"
 
49
                fi
43
50
                addfstab "$1" "$mount_point" "$fs" "$options" 0 0
44
51
                rm_dir_or_link /target$mount_point
45
52
                mkdir -p /target$mount_point