wok diff binutils223/receipt @ rev 25591
enet: update wget_url
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Thu Jun 22 11:01:59 2023 +0000 (14 months ago) |
parents | |
children | b81ceff0b056 |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/binutils223/receipt Thu Jun 22 11:01:59 2023 +0000 1.3 @@ -0,0 +1,91 @@ 1.4 +# SliTaz package receipt. 1.5 + 1.6 +PACKAGE="binutils223" 1.7 +SOURCE="binutils" 1.8 +VERSION="2.23.1" 1.9 +CATEGORY="development" 1.10 +TAGS="assembler linker" 1.11 +SHORT_DESC="GNU assembler, linker and binary utilities." 1.12 +MAINTAINER="pankso@slitaz.org" 1.13 +LICENSE="GPL2" 1.14 +WEB_SITE="https://www.gnu.org/software/binutils/" 1.15 + 1.16 +TARBALL="$SOURCE-$VERSION.tar.bz2" 1.17 +#WGET_URL="https://www.kernel.org/pub/linux/devel/binutils/$TARBALL" 1.18 +WGET_URL="http://ftp.gnu.org/gnu/$SOURCE/$TARBALL" 1.19 + 1.20 +PROVIDE="libbfd" 1.21 +DEPENDS="flex glibc zlib" 1.22 +BUILD_DEPENDS="glibc-dev texinfo zlib-dev" 1.23 + 1.24 +HOST_ARCH="i486 arm" 1.25 + 1.26 +# Handle cross compilation. 1.27 +case "$ARCH" in 1.28 + arm) BUILD_DEPENDS="" ;; 1.29 +esac 1.30 + 1.31 +# @maintainer: Please update also: libbfd 1.32 + 1.33 +# What is the latest version available today? 1.34 +current_version() 1.35 +{ 1.36 + wget -O - ${WGET_URL%/*} 2>/dev/null | \ 1.37 + sed "/latest/d;/$PACKAGE-/!d;/tar/!d;s|.*$PACKAGE-\\(.*\\).tar.*\".*|\\1|" | sort -Vr | sed q 1.38 +} 1.39 + 1.40 +# Rules to configure and make the package. 1.41 +compile_rules() 1.42 +{ 1.43 + case "$ARCH" in 1.44 + i?86) ARCH_ARGS="--disable-werror --enable-64-bit-bfd" ;; 1.45 + esac 1.46 + 1.47 + mkdir ../binutils-build && 1.48 + cd ../binutils-build && 1.49 + $src/configure \ 1.50 + --program-prefix=$TOOLPREFIX \ 1.51 + --program-suffix=-2.23 \ 1.52 + --enable-shared \ 1.53 + --disable-initfini-array \ 1.54 + --with-bugurl="http://bugs.slitaz.org/" \ 1.55 + $CONFIGURE_ARGS \ 1.56 + $ARCH_ARGS && 1.57 + make tooldir=/usr && 1.58 + make install tooldir=/usr && 1.59 + # This is the default binutils, so create symlinks to the target platform 1.60 + # binutil binaries. Delete duplicate binaries to save space. 1.61 + for binutil in $(ls -1 $DESTDIR/usr/bin | grep "${TOOLPREFIX}") 1.62 + do 1.63 + path="$DESTDIR/usr/bin/$(echo "$binutil" | sed "s:$TOOLPREFIX::g")" 1.64 + if [ -e $path ] 1.65 + then 1.66 + rm -f $path 1.67 + fi 1.68 + ln -s $binutil $path 1.69 + done 1.70 +} 1.71 + 1.72 +# Rules to gen a SliTaz package suitable for Tazpkg. 1.73 +genpkg_rules() 1.74 +{ 1.75 + cook_copy_folders bin 1.76 + cook_copy_folders include 1.77 + cook_copy_files *.a 1.78 + cook_copy_files *.so* 1.79 + 1.80 + # libiberty.h 1.81 + cp -a $src/include/libiberty.h $fs/usr/include 1.82 + 1.83 + # Remove 'strings' (Busybox). 1.84 + #rm $fs/usr/lib/libiberty.a 1.85 + rm $fs/usr/bin/strings* 1.86 + rm $fs/usr/bin/*-strings* 1.87 + 1.88 + # Remove build directory (cookutils and tazwok path). 1.89 + rm -rf $WOK/$PACKAGE/source/$PACKAGE-build 1.90 + rm -rf $WOK/$PACKAGE/$PACKAGE-build 1.91 + 1.92 + chown -R root:root $fs/usr/include/libiberty.h 1.93 + chmod 644 $fs/usr/include/libiberty.h 1.94 +}