wok-6.x annotate coreutils/receipt @ rev 24415

Add some current_version
author Pascal Bellard <pascal.bellard@slitaz.org>
date Thu Feb 10 18:04:02 2022 +0000 (2022-02-10)
parents 9b6a3a5c1a07
children 3b252eb4d26a
rev   line source
pankso@15 1 # SliTaz package receipt.
pankso@15 2
pankso@15 3 PACKAGE="coreutils"
Hans-G?nter@22616 4 VERSION="8.31"
pankso@211 5 CATEGORY="system-tools"
pankso@15 6 SHORT_DESC="Utilities for using and setting the basic system."
pankso@15 7 MAINTAINER="pankso@slitaz.org"
pascal@14999 8 LICENSE="GPL3"
al@19215 9 WEB_SITE="https://www.gnu.org/software/coreutils/coreutils.html"
Hans-G?nter@22616 10
slaxemulator@7244 11 TARBALL="$PACKAGE-$VERSION.tar.xz"
Hans-G?nter@22616 12 WGET_URL="https://ftp.gnu.org/gnu/$PACKAGE/$TARBALL"
pascal@14074 13
al@19215 14 SIBLINGS="coreutils-multicall"
Hans-G?nter@22616 15 SPLIT="coreutils-character coreutils-command coreutils-conditions
Hans-G?nter@22616 16 coreutils-context-system coreutils-context-user
Hans-G?nter@22616 17 coreutils-context-working coreutils-directory coreutils-disk
Hans-G?nter@22616 18 coreutils-file-attributes coreutils-file-format
Hans-G?nter@22616 19 coreutils-file-output-full coreutils-file-output-part
Hans-G?nter@22616 20 coreutils-file-sort coreutils-file-special coreutils-file-summarize
Hans-G?nter@22616 21 coreutils-line coreutils-numeric coreutils-operations
Hans-G?nter@22616 22 coreutils-path coreutils-print coreutils-redirection"
Hans-G?nter@22616 23 DEPENDS="acl attr glibc-base gmp"
Hans-G?nter@22616 24 BUILD_DEPENDS="automake gmp-dev libcap-dev xz"
pankso@15 25
pascal@24415 26 # What is the latest version available today?
pascal@24415 27 current_version()
pascal@24415 28 {
pascal@24415 29 wget -O - ${WGET_URL%/*} 2>/dev/null | \
pascal@24415 30 sed '/latest/d;/coreutils-/!d;/tar/!d;s|.*coreutils-||;s|.tar.*||' | sort -Vr | sed q
pascal@24415 31 }
pascal@24415 32
pankso@15 33 # Rules to configure and make the package.
pankso@15 34 compile_rules()
pankso@15 35 {
al@19215 36 # LFS: Coreutils Internationalization Fixes Patch
Hans-G?nter@22616 37 # patch -Np1 -i $stuff/coreutils-8.25-i18n-2.patch
Hans-G?nter@22616 38
al@19215 39 # SliTaz: show extended info touching CPU via uname
al@19215 40 patch -p1 -i $stuff/uname.u
rcx@3574 41
al@19215 42 autoreconf -fi
pankso@4080 43
Hans-G?nter@22616 44 # bypass checking whether mknod can create fifo without root privileges
Hans-G?nter@22616 45 export FORCE_UNSAFE_CONFIGURE=1
Hans-G?nter@22616 46
Hans-G?nter@22616 47 ./configure $CONFIGURE_ARGS &&
Hans-G?nter@22616 48 make &&
Hans-G?nter@22616 49 make install
pankso@4080 50
al@19215 51 # LFS: Move programs to the locations specified by the FHS
Hans-G?nter@22616 52 mkdir -p $install/bin
Hans-G?nter@22616 53 mkdir -p $install/usr/sbin
Hans-G?nter@22616 54 mkdir -p $install/usr/share/man/man8
Hans-G?nter@22616 55
al@19215 56 for i in cat chgrp chmod chown cp date dd df echo false ln ls mkdir \
Hans-G?nter@22616 57 mknod mv pwd rm rmdir stty sync true uname
Hans-G?nter@22616 58 do
Hans-G?nter@22616 59 mv $install/usr/bin/$i $install/bin
Hans-G?nter@22616 60 done
Hans-G?nter@22616 61 mv $install/usr/bin/chroot $install/usr/sbin
al@19215 62 mv $install/usr/share/man/man1/chroot.1 \
Hans-G?nter@22616 63 $install/usr/share/man/man8/chroot.8
Hans-G?nter@22616 64
al@19215 65 sed -i 's|"1"|"8"|' $install/usr/share/man/man8/chroot.8
al@19215 66
al@19215 67 find $install/usr/share/man -type f -exec gzip -9 \{\} \;
pankso@15 68 }
pankso@15 69
pankso@15 70 # Rules to gen a SliTaz package suitable for Tazpkg.
pankso@15 71 genpkg_rules()
pankso@15 72 {
al@19215 73 # A set of binaries looks intriguing, isn't it?
al@19215 74 # For what is this package with exactly these binaries?
al@19215 75
Hans-G?nter@22616 76 mkdir -p $fs/usr/bin
Hans-G?nter@22616 77 mkdir -p $fs/bin
al@19215 78
al@19215 79 cd $install/usr/bin
Hans-G?nter@22616 80 for i in base64 csplit factor fmt join od paste ptx shred shuf \
Hans-G?nter@22616 81 split users groups
Hans-G?nter@22616 82 do
Hans-G?nter@22616 83 cp -a $i $fs/usr/bin
Hans-G?nter@22616 84 done
al@19215 85
Hans-G?nter@22616 86 cp -a $install/bin/cp $fs/bin
pankso@15 87 }
pankso@15 88
domcox@14131 89 post_install()
domcox@14131 90 {
al@19215 91 # Remove Busybox applet in order to not clash with
al@19215 92 # /usr/bin/base64 from this package.
al@19215 93 rm "$1/bin/base64"
pankso@15 94 }
pankso@3435 95
pankso@3435 96 post_remove()
pankso@3435 97 {
al@19215 98 ln -s busybox "$1/bin/base64"
al@19215 99 ln -s busybox "$1/bin/cp"
al@19215 100 ln -s /bin/busybox "$1/usr/bin/groups"
al@19215 101 ln -s /bin/busybox "$1/usr/bin/od"
al@19215 102 ln -s /bin/busybox "$1/usr/bin/split"
al@19215 103 ln -s /bin/busybox "$1/usr/bin/users"
pankso@3435 104 }