wok-current view mercurial-python3/receipt @ rev 25788

Mass update to fix build with gcc10 and up others packages
author Stanislas Leduc <shann@slitaz.org>
date Tue Sep 30 07:43:04 2025 +0000 (3 weeks ago)
parents
children
line source
1 # SliTaz package receipt.
3 PACKAGE="mercurial-python3"
4 SOURCE="mercurial"
5 VERSION="6.1.1"
6 CATEGORY="development"
7 SHORT_DESC="Revision tools system."
8 MAINTAINER="pankso@slitaz.org"
9 LICENSE="GPL2"
10 WEB_SITE="https://www.mercurial-scm.org/"
12 TARBALL="$SOURCE-$VERSION.tar.gz"
13 WGET_URL="${WEB_SITE}release/$TARBALL"
15 PROVIDE="hg"
16 SUGGESTED="cacerts"
17 DEPENDS="libssl patch python3"
18 BUILD_DEPENDS="openssl-dev patch python3-dev"
20 CONFIG_FILES="/etc/mercurial/hgweb.config"
22 HOST_ARCH="i486 arm x86_64"
24 # What is the latest version available today?
25 current_version()
26 {
27 wget -O - ${WGET_URL%/*} 2>/dev/null | \
28 sed "/snapshot/d;/latest/d;/$PACKAGE-/!d;/tar/!d;s|.*$PACKAGE-\\(.*\\).tar.*\".*|\\1|" | sort -Vr | sed q
29 }
31 # Rules to configure and make the package.
32 compile_rules()
33 {
34 # Cross compilation hack to avoid using compiler which build python
35 # itself.
36 case "$ARCH" in
37 arm*)
38 mv /usr/bin/i486-slitaz-linux-gcc /tmp &&
39 ln -s /cross/${ARCH}/tools/bin/${HOST_SYSTEM}-gcc \
40 /usr/bin/i486-slitaz-linux-gcc ;;
41 esac &&
43 python3 setup.py install \
44 --root="$DESTDIR" \
45 --optimize=1 &&
46 mkdir -p $DESTDIR/usr/share/examples/mercurial &&
47 cp -a $src/hgweb.cgi $DESTDIR/usr/share/examples/mercurial &&
49 case "$ARCH" in
50 arm*)
51 rm /usr/bin/i486-slitaz-linux-gcc &&
52 mv /tmp/i486-slitaz-linux-gcc /usr/bin ;;
53 esac
54 }
56 # Rules to gen a SliTaz package suitable for Tazpkg.
57 genpkg_rules()
58 {
59 mkdir -p $fs/usr/bin
61 cp -a $install/usr/bin/hg $fs/usr/bin/hg-python3
62 cp -a $install/usr/lib $fs/usr
64 chown -R root.root $fs
65 }