6.51. Udev-145

The Udev package contains programs for dynamic creation of device nodes.

6.51.1. Environment Settings

This package requires compiler variables to be set for the target in the environment.

export CC="${CLFS_TARGET}-gcc"
export CXX="${CLFS_TARGET}-g++"
export AR="${CLFS_TARGET}-ar"
export AS="${CLFS_TARGET}-as"
export RANLIB="${CLFS_TARGET}-ranlib"
export LD="${CLFS_TARGET}-ld"
export STRIP="${CLFS_TARGET}-strip"

6.51.2. Installation of Udev

Prepare Udev for compilation:

./configure --build=${CLFS_HOST} --host=${CLFS_TARGET} \
    --exec-prefix="" --sysconfdir=/etc \
    --libexecdir=/lib/udev --libdir=/usr/lib \
    --disable-extras

Compile the package:

make

Install the package:

make DESTDIR=${CLFS} install

Install documentation:

install -v -m644 -D docs/writing_udev_rules/index.html \
    ${CLFS}/usr/share/doc/udev-145/index.html

Create a directory for storing firmware that can be loaded by udev:

install -dv ${CLFS}/lib/firmware

6.51.3. Contents of Udev

Installed programs: udevcontrol, udevd, udevinfo, udevmonitor, udevsend, udevtest, and udevtrigger
Installed directory: /etc/udev

Short Descriptions

udevcontrol

Configures a number of options for the running udevd daemon, such as the log level.

udevd

A daemon that reorders hotplug events before submitting them to udev, thus avoiding various race conditions

udevinfo

Allows users to query the udev database for information on any device currently present on the system; it also provides a way to query any device in the sysfs tree to help create udev rules

udevmonitor

Prints the event received from the kernel and the event which udev sends out after rule processing

udevsettle

Watches the Udev event queue and exits if all current uevents have been handled

udevtest

Simulates a udev run for the given device, and prints out the name of the node the real udev would have created or the name of the renamed network interface

udevtrigger

Walks the sysfs tree for devices that need to be added to the system.

ata_id

Provides Udev with a unique string and additional information (uuid, label) for an ATA drive

cdrom_id

Print the capabilities of a CDROM or DVDROM drive.

create_floppy_devices

Creates all possible floppy devices based on the CMOS type

dasd_id

Read the label from an s390 block device.

edd_id

Identify x86 disk drives from Enhanced Disk Drive calls.

firmware.sh

Script to load firmware for a device

path_id

Provide the shortest possible unique hardware path to a device

scsi_id

Retrieve or generate a unique SCSI identifier.

usb_id

Identify a USB block device.

vol_id

Probe filesystem type and read label and uuid.

/etc/udev

Contains udev configuration files, device permissions, and rules for device naming

/lib/udev

Contains udev helper programs and static devices which get copied to /dev when booted.