wok view glib/receipt @ rev 16319

ARM: add mpfr + mpc-library (to cook native ARM gcc) and try to fix glib (gtk crashe are from libgobject-2.0.so.0)
author Christophe Lincoln <pankso@slitaz.org>
date Wed Apr 09 20:51:15 2014 +0200 (2014-04-09)
parents 73fb2ebfd59a
children 557291b407c6
line source
1 # SliTaz package receipt.
3 PACKAGE="glib"
4 VERSION="2.32.4"
5 CATEGORY="x-window"
6 SHORT_DESC="C routines."
7 MAINTAINER="pankso@slitaz.org"
8 LICENSE="GPL2"
9 TARBALL="$PACKAGE-$VERSION.tar.xz"
10 WEB_SITE="http://www.gtk.org/"
11 WGET_URL="$GNOME_MIRROR/$PACKAGE/${VERSION:0:4}/$TARBALL"
12 HOST_ARCH="i486 arm"
14 CROSS_BUGS="arm: glib 2.32.4 error: cannot compute alignment of guint32"
16 DEPENDS="pcre libffi libxml2 elfutils"
17 BUILD_DEPENDS="pcre-dev libffi-dev gettext zlib-dev perl python-dev \
18 elfutils-dev libxml2-dev libxml2-tools automake"
20 # Handle SliTaz arch
21 case "$SLITAZ_ARCH" in
22 arm*) VERSION="2.34.3" ;;
23 esac
25 # Handle cross comilation. Use host Perl, Python, etc
26 case "$ARCH" in
27 arm*)
28 VERSION="2.34.3"
29 TARBALL="$PACKAGE-$VERSION.tar.xz"
30 WGET_URL="$GNOME_MIRROR/$PACKAGE/${VERSION:0:4}/$TARBALL"
31 BUILD_DEPENDS="pcre-dev libffi-dev zlib-dev elfutils-dev libxml2-dev" ;;
32 esac
34 # Rules to configure and make the package.
35 compile_rules()
36 {
37 case "$ARCH" in
38 i?86)
39 ./configure \
40 --sysconfdir=/etc \
41 --with-pcre=system \
42 $CONFIGURE_ARGS ;;
43 arm*)
44 # Native ARM build --> if ARCH != SLITAZ_ARCH ?
45 export LD_LIBRARY_PATH=/cross/$ARCH/sysroot/usr/lib:/usr/lib:/lib
46 export PKG_CONFIG_LIBPATH=/cross/$ARCH/sysroot/usr/lib/pkgconfig
48 # Glib
49 export glib_cv_stack_grows=${glib_cv_stack_grows=no}
50 export glib_cv_uscore=${glib_cv_uscore=no}
51 export ac_cv_func_posix_getpwuid_r=${ac_cv_func_posix_getpwuid_r=no}
52 export ac_cv_func_posix_getgrgid_r=${ac_cv_func_posix_getgrgid_r=no}
53 export ac_cv_type_long_long=${ac_cv_type_long_long=yes}
54 CC="$HOST_SYSTEM-gcc" \
55 LIBTOOL="$HOST_SYSTEM-libtool" \
56 ./configure \
57 --sysconfdir=/etc \
58 --with-pcre=system \
59 --build=i486-slitaz-linux \
60 --host=arm-slitaz-linux-gnueabi \
61 --enable-shared=yes \
62 --enable-static=yes ;;
63 esac &&
64 make && make install
65 }
67 # Rules to gen a SliTaz package suitable for Tazpkg.
68 genpkg_rules()
69 {
70 mkdir -p $fs/usr/lib
71 cp -a $install/usr/bin $fs/usr
72 cp -a $install/usr/lib/*.so* $fs/usr/lib
74 # Split gio --> libgio
75 rm $fs/usr/lib/libgio*
77 # Python codegen, tester, Perl mkenums --> glib-dev
78 for bin in gdbus-codegen gtester* glib-mkenums
79 do
80 rm $fs/usr/bin/$bin
81 done
83 # Cook packages that want glib.
84 for w in libgio libgio-dev
85 do
86 [ -x "/usr/bin/cook" ] && echo cook $w
87 done
88 }