summaryrefslogtreecommitdiffstats
path: root/udev/Pkgfile
blob: 59ea480a8203e575f48e1555e4245c67b806eeda (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
# Description: Démon pour la gestion du matériel dans l'espace utilisateur
# URL: http://www.kernel.org/pub/linux/utils/kernel/hotplug/udev.html
# Maintainer: NuTyX core team
# Packager: thierryn1 at hispeed dot ch
# Depends on: libusb,usbutils,gobject-introspection,gperf,acl,pciutils
# Run on:

name=udev
version=182
release=1
_lfs_release=20100128
source=(http://www.kernel.org/pub/linux/utils/kernel/hotplug/$name-$version.tar.xz
	http://www.linuxfromscratch.org/lfs/downloads/development/udev-config-${_lfs_release}.tar.bz2)

build() {
	if ( pkginfo -i|grep "^glib " > /dev/null) then
		EXTRA="--with-pci-ids-path=/usr/share/pci.ids.gz --enable-udev_acl"
	else
		EXTRA="--disable-extras --disable-introspection --disable-hwdb --disable-keymap"
	fi
	cd udev-$version

	install -dv $PKG/lib/{firmware,udev/devices/{pts,shm}}
	ln -s /proc/self/fd $PKG/lib/udev/devices/fd
	ln -s /proc/self/fd/0 $PKG/lib/udev/devices/stdin
	ln -s /proc/self/fd/1 $PKG/lib/udev/devices/stdout
	ln -s /proc/self/fd/2 $PKG/lib/udev/devices/stderr
	ln -s /proc/kcore $PKG/lib/udev/devices/core

	BLKID_CFLAGS="-I/usr/include/blkid" \
	BLKID_LIBS="-L/lib -lblkid" \
	KMOD_CFLAGS="-I/usr/include" \
	KMOD_LIBS="-L/lib -lkmod" \
	./configure  --prefix=/usr \
		--with-rootlibdir=/lib \
		--docdir=/usr/share/doc/udev-$version \
		--sbindir=/sbin \
		--bindir=/sbin \
		--libdir=/usr/lib \
		--sysconfdir=/etc \
		--libexecdir=/lib \
		--enable-rule_generator \
		--with-systemdsystemunitdir=no \
		$EXTRA
	make 

	make install DESTDIR=$PKG mandir="/usr/share/man"
	cd ../udev-config-${_lfs_release}
	make DESTDIR=$PKG install
	make DESTDIR=$PKG install-doc
	rm -r $PKG/usr/share/gtk-doc
	rm -r $PKG/usr/share/doc/udev-$version
}