Creating device files

Installing MAKEDEV

Install MAKEDEV by running the following commands:



root:MAKEDEV-2.3.1# cp MAKEDEV $LFS/dev
root:MAKEDEV-2.3.1# chmod 755 $LFS/dev/MAKEDEV

Creating the /dev entries

Create the device files by running the following commands:



root:~# cd $LFS/dev
root:dev# ./MAKEDEV -v generic

Please note that this script dates back from 1997 and therefore can be outdated and not support newer hardware. If you need device files which aren't known by this script please read the Documentation/devices.txt file in a Linux source tree. This file lists all the major and minor numbers for all the device files that the kernel knows about. With this list you can create such device files yourself. See the mknod man page for more information on how to make device files yourself.