wok view pkg-config/receipt @ rev 24757

pkg-config: cheat configure
author Hans-G?nter Theisgen
date Fri Mar 18 06:53:58 2022 +0100 (2022-03-18)
parents 241fb98cab1c
children b01314c762e9
line source
1 # SliTaz package receipt.
3 PACKAGE="pkg-config"
4 VERSION="0.29.2"
5 CATEGORY="development"
6 SHORT_DESC="Free desktop packages manager."
7 MAINTAINER="pankso@slitaz.org"
8 LICENSE="GPL2"
9 TARBALL="$PACKAGE-$VERSION.tar.gz"
10 WEB_SITE="http://pkgconfig.freedesktop.org/wiki/"
11 WGET_URL="http://pkgconfig.freedesktop.org/releases/$TARBALL"
12 HOST_ARCH="i486 arm"
14 DEPENDS="glibc-base"
15 BUILD_DEPENDS="automake gcc libtool"
17 # Handle cross compilation.
18 case "$ARCH" in
19 arm) BUILD_DEPENDS="" ;;
20 esac
22 # What is the latest version available today?
23 current_version()
24 {
25 wget -O - ${WGET_URL%/*}/ 2>/dev/null | \
26 sed "/latest/d;/$PACKAGE-[0-9]/!d;/tar/!d;s|.*$PACKAGE-\\(.*\\).tar.*|\\1|" | sort -Vr | sed q
27 }
29 # Rules to configure and make the package.
30 compile_rules()
31 {
32 ln -s /usr/bin/automake /usr/bin/automake-1.15
33 sed -i 's/\$(LN).*pkg-config\$(EXEEXT) \$(host_tool)/echo \1/' Makefile*
34 case "$ARCH" in
35 arm)
36 ./configure \
37 --program-prefix=$TOOLPREFIX \
38 --build=i486-slitaz-linux \
39 --host=arm-slitaz-linux-gnueabi \
40 --cache-file=arm-linux.cache ;;
41 *)
42 ./configure \
43 --program-prefix=$TOOLPREFIX \
44 --build=$HOST_SYSTEM \
45 --host=$HOST_SYSTEM ;;
46 esac &&
47 make && make install
48 }
50 # Rules to gen a SliTaz package suitable for Tazpkg.
51 genpkg_rules()
52 {
53 mkdir -p $fs/usr/share
54 cp -a $install/usr/bin $fs/usr
55 cp -a $install/usr/share/aclocal $fs/usr/share
56 # This is the default pkg-config so make a symling for package that dont
57 # cross compile or search for /usr/bin/pkg-config.
58 cd $fs/usr/bin && ln -s ${TOOLPREFIX}pkg-config pkg-config
59 }