summaryrefslogtreecommitdiff
path: root/udev/Pkgfile
blob: a23c8e50b52ada2d3928a0c263bb968b4198dd7e (plain)
    1 # Description: Userspace device management daemon
    2 # URL: http://www.kernel.org/pub/linux/utils/kernel/hotplug/udev.html
    3 # Maintainer: CRUX System Team, core-ports at crux dot nu
    4 
    5 name=udev
    6 version=129
    7 release=1
    8 source=(ftp://ftp.kernel.org/pub/linux/utils/kernel/hotplug/$name-$version.tar.bz2 \
    9 	http://crux.nu/files/distfiles/udev-config-20080217.tar.bz2 \
   10 	start_udev cdrom.rules cdsymlinks)
   11 
   12 build() {
   13 	local extras="extras/ata_id \
   14 			extras/cdrom_id \
   15 			extras/edd_id \
   16 			extras/firmware \
   17 			extras/floppy \
   18 			extras/path_id \
   19 			extras/scsi_id \
   20 			extras/usb_id \
   21 			extras/volume_id"
   22 
   23 	cd udev-$version
   24 
   25 	./configure --prefix=/usr --exec-prefix= --sysconfdir=/etc
   26 
   27 	make EXTRAS="$extras"
   28 	make install DESTDIR=$PKG mandir="/usr/man" EXTRAS="$extras"
   29 
   30 	pushd $SRC/udev-config-20080217
   31 	make DESTDIR=$PKG RULES_DIR=/lib/udev/rules.d install
   32 	popd
   33 
   34 	mkdir -p $PKG/lib/{firmware,udev/devices/{pts,shm}}
   35 	mknod -m 600 $PKG/lib/udev/devices/console c 5 1
   36 	mknod -m 666 $PKG/lib/udev/devices/null c 1 3
   37 	mknod -m 666 $PKG/lib/udev/devices/zero c 1 5
   38 	ln -s /proc/self/fd $PKG/lib/udev/devices/fd
   39 	ln -s /proc/self/fd/0 $PKG/lib/udev/devices/stdin
   40 	ln -s /proc/self/fd/1 $PKG/lib/udev/devices/stdout
   41 	ln -s /proc/self/fd/2 $PKG/lib/udev/devices/stderr
   42 	ln -s /proc/kcore $PKG/lib/udev/devices/core
   43 	install -m 0755 $SRC/start_udev $PKG/sbin
   44 	install -m 0755 $SRC/cdsymlinks $PKG/lib/udev/
   45 	install -m 644 rules/rules.d/[0-9]* $PKG/lib/udev/rules.d/
   46 	install -m 644 $SRC/cdrom.rules $PKG/lib/udev/rules.d/61-cdrom.rules
   47 
   48 	# Comment uucp lines in default rules
   49 	sed -i 's|.*uucp.*|#&|g' $PKG/lib/udev/rules.d/50-udev-default.rules
   50 	sed -i 's|.*uucp.*|#&|g' $PKG/lib/udev/rules.d/55-lfs.rules
   51 
   52 	# Keep udevinfo for legacy support
   53 	mkdir -p $PKG/usr/bin
   54 	ln -s /sbin/udevadm $PKG/usr/bin/udevinfo
   55 }

Generated by cgit