wok-next annotate util-linux/receipt @ rev 19766
Up cookutils.
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Mon Jun 12 11:40:38 2017 +0300 (2017-06-12) |
parents | e7e59838b371 |
children | f463de72afe3 |
rev | line source |
---|---|
al@19741 | 1 # SliTaz package receipt v2. |
pankso@12480 | 2 |
pankso@12480 | 3 PACKAGE="util-linux" |
al@19741 | 4 VERSION="2.30.0" |
pankso@12480 | 5 CATEGORY="meta" |
al@19741 | 6 SHORT_DESC="Random collection of Linux utilities" |
pankso@12480 | 7 MAINTAINER="pankso@slitaz.org" |
al@19253 | 8 LICENSE="GPL2 LGPL2.1 BSD PublicDomain" |
al@19253 | 9 WEB_SITE="https://en.wikipedia.org/wiki/Util-linux" |
pankso@12927 | 10 HOST_ARCH="i486 arm" |
pankso@12480 | 11 |
al@19741 | 12 TARBALL="$PACKAGE-${VERSION%.0}.tar.xz" |
al@19741 | 13 WGET_URL="https://www.kernel.org/pub/linux/utils/util-linux/v${VERSION%.*}/$TARBALL" |
al@19568 | 14 |
al@19613 | 15 BUILD_DEPENDS="libcap-dev readline-dev python-dev glib gtk-doc \ |
al@19574 | 16 libxslt gettext ncurses-dev zlib-dev" |
al@19741 | 17 COOKOPTS="!menus" |
al@19568 | 18 SPLIT="util-linux-bash-completion util-linux-blkid util-linux-blkid-dev \ |
al@19568 | 19 util-linux-blockdev util-linux-cfdisk util-linux-column util-linux-cramfs \ |
al@19568 | 20 util-linux-eject util-linux-fdisk util-linux-fdisk-dev util-linux-flock \ |
al@19568 | 21 util-linux-getopt util-linux-manpages util-linux-minix util-linux-mkfs \ |
al@19568 | 22 util-linux-mount util-linux-mount-dev util-linux-partx util-linux-setterm \ |
al@19568 | 23 util-linux-sfdisk util-linux-smartcols util-linux-smartcols-dev \ |
al@19741 | 24 util-linux-uuid util-linux-uuid-dev util-linux-whereis util-linux-misc" |
pankso@12480 | 25 |
pankso@12480 | 26 # Rules to configure and make the package. |
pankso@12480 | 27 compile_rules() |
pankso@12480 | 28 { |
pankso@12927 | 29 # Fix undeclared 'LINE_MAX' |
pankso@12927 | 30 case "$ARCH" in |
pankso@12927 | 31 arm) sed -i s'|LINE_MAX|25|' text-utils/*.c ;; |
pankso@12927 | 32 esac |
al@19253 | 33 |
al@19568 | 34 mkdir -p $install/var/lib/hwclock |
pankso@12480 | 35 ./configure \ |
al@19568 | 36 ADJTIME_PATH=/var/lib/hwclock/adjtime \ |
al@19741 | 37 --docdir=/usr/share/doc/util-linux-$VERSION \ |
al@19568 | 38 --disable-static \ |
al@19568 | 39 --without-systemd \ |
al@19568 | 40 --without-systemdsystemunitdir && |
al@19741 | 41 make && make install || exit 1 |
al@19741 | 42 |
al@19741 | 43 mkdir -p $install/usr/share/applications |
al@19741 | 44 cp $stuff/cfdisk.desktop $install/usr/share/applications |
pankso@12480 | 45 } |
al@19741 | 46 |
al@19741 | 47 # Rules to gen a SliTaz package suitable for Tazpkg. |
al@19741 | 48 genpkg_rules() |
al@19741 | 49 { |
al@19741 | 50 case ${PACKAGE#util-linux-} in |
al@19741 | 51 bash-completion) |
al@19741 | 52 copy bash-completion/ |
al@19741 | 53 CAT="shells|BASH completions" |
al@19741 | 54 DEPENDS="bash" |
al@19741 | 55 ;; |
al@19741 | 56 blkid) |
al@19741 | 57 copy lsblk blkid libblkid.so* |
al@19741 | 58 CAT="base-system|blkid utility" |
al@19741 | 59 DEPENDS="glibc-base util-linux-mount util-linux-smartcols \ |
al@19741 | 60 util-linux-uuid" |
al@19741 | 61 ;; |
al@19741 | 62 blkid-dev) |
al@19741 | 63 copy blkid.h blkid.pc libblkid.*a |
al@19741 | 64 CAT="development|blkid development files" |
al@19741 | 65 DEPENDS="util-linux-blkid util-linux-uuid-dev" |
al@19741 | 66 ;; |
al@19741 | 67 blockdev) |
al@19741 | 68 copy blockdev |
al@19741 | 69 CAT="base-system|blockdev utility" |
al@19741 | 70 DEPENDS="glibc-base" |
al@19741 | 71 ;; |
al@19741 | 72 cfdisk) |
al@19741 | 73 cook_copy_files cfdisk cfdisk.desktop |
al@19741 | 74 CAT="system-tools|cfdisk utility" |
al@19741 | 75 DEPENDS="glibc-base ncurses util-linux-blkid util-linux-fdisk \ |
al@19741 | 76 util-linux-mount util-linux-smartcols util-linux-uuid" |
al@19741 | 77 ;; |
al@19741 | 78 column) |
al@19741 | 79 copy column col colrm colcrt |
al@19741 | 80 CAT="base-system|column utility" |
al@19741 | 81 DEPENDS="glibc-base" |
al@19741 | 82 ;; |
al@19741 | 83 cramfs) |
al@19741 | 84 copy *.cramfs |
al@19741 | 85 CAT="system-tools|cramfs utilities" |
al@19741 | 86 DEPENDS="glibc-base zlib" |
al@19741 | 87 ;; |
al@19741 | 88 eject) |
al@19741 | 89 copy eject |
al@19741 | 90 CAT="base-system|eject utility" |
al@19741 | 91 DEPENDS="glibc-base util-linux-blkid util-linux-mount \ |
al@19741 | 92 util-linux-uuid" |
al@19741 | 93 ;; |
al@19741 | 94 fdisk) |
al@19741 | 95 copy fdisk libfdisk.so* |
al@19741 | 96 CAT="system-tools|fdisk utility" |
al@19741 | 97 DEPENDS="glibc-base ncurses readline util-linux-blkid \ |
al@19741 | 98 util-linux-smartcols util-linux-uuid" |
al@19741 | 99 ;; |
al@19741 | 100 fdisk-dev) |
al@19741 | 101 copy libfdisk.h libfdisk.*a fdisk.pc |
al@19741 | 102 CAT="development|fdisk utility development files" |
al@19741 | 103 DEPENDS="util-linux-fdisk util-linux-blkid-dev util-linux-uuid-dev" |
al@19741 | 104 ;; |
al@19741 | 105 flock) |
al@19741 | 106 copy flock lslocks |
al@19741 | 107 CAT="base-system|flock utility" |
al@19741 | 108 DEPENDS="glibc-base" |
al@19741 | 109 ;; |
al@19741 | 110 getopt) |
al@19741 | 111 copy getopt |
al@19741 | 112 CAT="base-system|getopt utility" |
al@19741 | 113 DEPENDS="glibc-base" |
al@19741 | 114 ;; |
al@19741 | 115 manpages) |
al@19741 | 116 copy man/ |
al@19741 | 117 CAT="doc|manual pages" |
al@19741 | 118 DEPENDS=" " |
al@19741 | 119 ;; |
al@19741 | 120 minix) |
al@19741 | 121 copy *.minix |
al@19741 | 122 CAT="system-tools|minix utilities" |
al@19741 | 123 DEPENDS="glibc-base" |
al@19741 | 124 ;; |
al@19741 | 125 mkfs) |
al@19741 | 126 copy mk* |
al@19741 | 127 rm -r $fs/usr |
al@19741 | 128 CAT="base-system|mkfs utilities" |
al@19741 | 129 DEPENDS="glibc-base util-linux-blkid util-linux-uuid zlib" |
al@19741 | 130 ;; |
al@19741 | 131 mount) |
al@19741 | 132 copy findmnt mount libmount.so* mountpoint umount |
al@19741 | 133 CAT="base-system|mount utilities" |
al@19741 | 134 DEPENDS="glibc-base util-linux-blkid util-linux-uuid \ |
al@19741 | 135 util-linux-smartcols" |
al@19741 | 136 ;; |
al@19741 | 137 mount-dev) |
al@19741 | 138 copy libmount.h libmount.*a mount.pc |
al@19741 | 139 CAT="development|mount utilities development files" |
al@19741 | 140 DEPENDS="util-linux-mount util-linux-blkid-dev util-linux-uuid-dev" |
al@19741 | 141 ;; |
al@19741 | 142 partx) |
al@19741 | 143 copy addpart delpart partx resizepart |
al@19741 | 144 CAT="system-tools|partx utilities" |
al@19741 | 145 DEPENDS="glibc-base util-linux-blkid util-linux-uuid \ |
al@19741 | 146 util-linux-smartcols" |
al@19741 | 147 ;; |
al@19741 | 148 setterm) |
al@19741 | 149 copy setterm |
al@19741 | 150 CAT="base-system|setterm utility" |
al@19741 | 151 DEPENDS="glibc-base ncurses" |
al@19741 | 152 ;; |
al@19741 | 153 sfdisk) |
al@19741 | 154 copy sfdisk |
al@19741 | 155 CAT="system-tools|sfdisk utility" |
al@19741 | 156 DEPENDS="glibc-base ncurses readline util-linux-blkid \ |
al@19741 | 157 util-linux-fdisk util-linux-smartcols util-linux-uuid" |
al@19741 | 158 ;; |
al@19741 | 159 smartcols) |
al@19741 | 160 copy libsmartcols.so* |
al@19741 | 161 CAT="system-tools|smartcols library" |
al@19741 | 162 DEPENDS="glibc-base" |
al@19741 | 163 ;; |
al@19741 | 164 smartcols-dev) |
al@19741 | 165 copy libsmartcols.h libsmartcols.*a smartcols.pc |
al@19741 | 166 CAT="development|smartcols library development files" |
al@19741 | 167 DEPENDS="util-linux-smartcols" |
al@19741 | 168 ;; |
al@19741 | 169 uuid) |
al@19741 | 170 copy libuuid.so* uuidgen uuidd |
al@19741 | 171 CAT="base-system|uuid utility and library" |
al@19741 | 172 DEPENDS="glibc-base" |
al@19741 | 173 ;; |
al@19741 | 174 uuid-dev) |
al@19741 | 175 copy uuid.h libuuid.*a uuid.pc |
al@19741 | 176 CAT="development|uuid utility and library development files" |
al@19741 | 177 DEPENDS="util-linux-uuid" |
al@19741 | 178 ;; |
al@19741 | 179 whereis) |
al@19741 | 180 copy whereis |
al@19741 | 181 CAT="base-system|whereis utility" |
al@19741 | 182 DEPENDS="glibc-base" |
al@19741 | 183 ;; |
al@19741 | 184 misc) |
al@19741 | 185 copy @std @dev |
al@19741 | 186 for i in $taz/*/files.list; do |
al@19741 | 187 while read j; do |
al@19741 | 188 rm $fs$j; rmdir $fs$(basename $j) |
al@19741 | 189 done < $i |
al@19741 | 190 done 2>/dev/null |
al@19741 | 191 CAT="system-tools|misc utilities" |
al@19741 | 192 ;; |
al@19741 | 193 esac |
al@19741 | 194 |
al@19741 | 195 if [ "$PACKAGE" != 'util-linux-bash-completion' -a -d "$fs/usr/share/bash-completion" ]; then |
al@19741 | 196 rm -r $fs/usr/share/bash-completion |
al@19741 | 197 rmdir --parents --ignore-fail-on-non-empty $fs/usr/share |
al@19741 | 198 fi |
al@19741 | 199 } |