wok-next annotate eudev/receipt @ rev 20454
Choose between libpng16 and libpng12
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Wed Feb 28 17:32:31 2018 +0200 (2018-02-28) |
parents | 90a5eb560fd6 |
children | 757d032c55c7 |
rev | line source |
---|---|
al@19741 | 1 # SliTaz package receipt v2. |
tcg@17143 | 2 |
tcg@17143 | 3 PACKAGE="eudev" |
al@19866 | 4 VERSION="3.2.4" |
tcg@17143 | 5 CATEGORY="base-system" |
al@19582 | 6 SHORT_DESC="Programs for dynamic creation of device nodes" |
tcg@17143 | 7 MAINTAINER="tcg.thegamer@gmail.com" |
pascal@17147 | 8 LICENSE="GPL2" |
al@19582 | 9 WEB_SITE="http://dev.gentoo.org/~blueness/eudev/" |
al@19863 | 10 LFS="http://www.linuxfromscratch.org/lfs/view/stable/chapter06/eudev.html" |
tcg@17143 | 11 |
al@19582 | 12 TARBALL="$PACKAGE-$VERSION.tar.gz" |
al@19582 | 13 WGET_URL="${WEB_SITE}$TARBALL" |
al@19866 | 14 TARBALL_MD5="66acef4c6094aab4aced7ae83b74b0d2" |
al@19582 | 15 |
al@19866 | 16 BUILD_DEPENDS="gobject-introspection-dev util-linux-blkid-dev gperf kmod-dev" |
al@19741 | 17 SPLIT="eudev-dev" |
tcg@17143 | 18 |
al@20436 | 19 compile_rules() { |
al@19582 | 20 sed -r -i 's|/usr(/bin/test)|\1|' test/udev-test.pl |
al@19741 | 21 sed -i '/keyboard_lookup_key/d' src/udev/udev-builtin-keyboard.c |
al@19582 | 22 cat > config.cache <<"EOF" |
al@19582 | 23 HAVE_BLKID=1 |
al@19582 | 24 BLKID_LIBS="-lblkid" |
al@19741 | 25 BLKID_CFLAGS="-I/include" |
al@19582 | 26 EOF |
al@19582 | 27 |
tcg@17143 | 28 ./configure \ |
al@19582 | 29 --bindir=/sbin \ |
al@19582 | 30 --sbindir=/sbin \ |
al@19582 | 31 --libdir=/usr/lib \ |
pascal@17147 | 32 --sysconfdir=/etc \ |
al@19582 | 33 --libexecdir=/lib \ |
al@19582 | 34 --with-rootprefix= \ |
al@19582 | 35 --with-rootlibdir=/lib \ |
al@19582 | 36 --enable-manpages \ |
al@19582 | 37 --disable-static \ |
al@19582 | 38 --config-cache \ |
al@19866 | 39 --enable-kmod \ |
tcg@17143 | 40 $CONFIGURE_ARGS && |
tcg@17143 | 41 make && |
al@19582 | 42 make install |
al@19741 | 43 |
al@19741 | 44 cp $stuff/*.rules $install/etc/udev/rules.d |
al@19866 | 45 cp -a $stuff/udev/* $install/lib/udev |
al@19863 | 46 |
al@19866 | 47 mkdir -p "$install/lib/firmware" "$install/lib/udev/keymaps/force-release" |
al@19866 | 48 |
al@19866 | 49 chown -R root:root $install |
al@19741 | 50 |
al@19741 | 51 # https://docs.oracle.com/cd/E37670_01/E41138/html/ch07s03.html |
al@19741 | 52 # /lib/udev/rules.d : default rules files. Do not edit these files. |
al@19741 | 53 # /etc/udev/rules.d : customized rules files. You can modify these files |
al@19741 | 54 # Rules files in /etc/udev/rules.d override files of the same name |
al@19741 | 55 # in /lib/udev/rules.d. |
tcg@17143 | 56 } |
tcg@17143 | 57 |
al@20436 | 58 genpkg_rules() { |
al@19741 | 59 case $PACKAGE in |
al@19741 | 60 eudev) |
al@19741 | 61 copy @std |
al@19866 | 62 DEPENDS="kmod liblzma util-linux-blkid util-linux-uuid zlib dbus" |
al@19880 | 63 PROVIDE="udev" |
al@20436 | 64 TAGS="LFS" |
al@19741 | 65 ;; |
al@19741 | 66 eudev-dev) |
al@19741 | 67 copy @dev |
al@19880 | 68 PROVIDE="udev-dev" |
al@19741 | 69 ;; |
al@19741 | 70 esac |
al@19741 | 71 } |
tcg@17143 | 72 |
al@19863 | 73 post_install_eudev() { |
tcg@17143 | 74 # Create some devices and directories that Udev cannot handle |
tcg@17143 | 75 # due to them being required very early in the boot process |
al@19741 | 76 mkdir -p "$1/lib/udev/devices/pts" |
al@19741 | 77 mkdir -p "$1/lib/udev/devices/shm" |
al@19741 | 78 [ -e "$1/lib/udev/devices/null" ] || mknod -m 0666 "$1/lib/udev/devices/null" c 1 3 |
tcg@17143 | 79 |
al@18663 | 80 # Sanity check for udev+ldap boot |
al@20347 | 81 grep GROUP= "$1"/etc/udev/rules.d/* "$1"/lib/udev/rules.d/* 2>/dev/null | \ |
al@19741 | 82 sed 's/.*GROUP="\([a-zA-Z0-9]*\)".*/\1/' | sort | uniq | \ |
al@19863 | 83 while read x; do |
al@18663 | 84 grep -q ^$x: "$1/etc/group" || chroot "$1/" addgroup -S $x |
al@18663 | 85 done |
al@18663 | 86 |
al@20347 | 87 grep OWNER= "$1"/etc/udev/rules.d/* "$1"/lib/udev/rules.d/* 2>/dev/null | \ |
al@19741 | 88 sed 's/.*OWNER="\([a-zA-Z0-9]*\)".*/\1/' | sort | uniq | \ |
al@19863 | 89 while read x; do |
al@18663 | 90 grep -q ^$x: "$1/etc/passwd" || chroot "$1/" adduser -S -D -H $x |
al@18663 | 91 done |
tcg@17143 | 92 } |
al@20443 | 93 |