diff options
author | Bruce Dubbs <bdubbs@linuxfromscratch.org> | 2012-09-01 02:31:13 +0000 |
---|---|---|
committer | Bruce Dubbs <bdubbs@linuxfromscratch.org> | 2012-09-01 02:31:13 +0000 |
commit | b2b1e1aa5fe437877a7ec9f7d861e215c956ebb9 (patch) | |
tree | e79563b34728d0e475dbf5d73da4e5cd1a278de6 /udev-lfs/contrib/debian/83-cdrom-symlinks.rules | |
parent | 166497f2c69435a594f9992ad55857112eb44127 (diff) |
Move directory to make build easier
git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@9973 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689
Diffstat (limited to 'udev-lfs/contrib/debian/83-cdrom-symlinks.rules')
-rw-r--r-- | udev-lfs/contrib/debian/83-cdrom-symlinks.rules | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/udev-lfs/contrib/debian/83-cdrom-symlinks.rules b/udev-lfs/contrib/debian/83-cdrom-symlinks.rules new file mode 100644 index 000000000..4713c0b92 --- /dev/null +++ b/udev-lfs/contrib/debian/83-cdrom-symlinks.rules @@ -0,0 +1,12 @@ +# /etc/udev/rules.d/83-cdrom-symlinks.rules: Determine CD drive capability. + +ACTION!="add", GOTO="cd_aliases_generator_end" +SUBSYSTEM!="block", GOTO="cd_aliases_generator_end" +ENV{GENERATED}=="?*", GOTO="cd_aliases_generator_end" + +# Fail the uevent if the autogenerated rules cannot be saved +ENV{ID_CDROM}=="?*", PROGRAM="/bin/grep -c ' / [^[:space:]]* rw' /proc/mounts", RESULT!="2", RUN+="/bin/false", GOTO="cd_aliases_generator_end" + +ENV{ID_CDROM}=="?*", PROGRAM="write_cd_aliases", SYMLINK+="%c" + +LABEL="cd_aliases_generator_end" |