# HG changeset patch # User Christophe Lincoln # Date 1393112149 -3600 # Node ID f6332424127f4b88e396ed6b37b87465bfec40ee # Parent 159df010240c5d274f83c1a2a6fdb90e89cd4185 Make lzma cross compile and fix libxml2 diff -r 159df010240c -r f6332424127f libxml2/receipt --- a/libxml2/receipt Sat Feb 22 23:10:15 2014 +0100 +++ b/libxml2/receipt Sun Feb 23 00:35:49 2014 +0100 @@ -16,8 +16,11 @@ # When cross compiling Python is installed in chroot and is used # by cross tools, cook dont need to install it in /usr/cross/arm +# Building with LZMA support is buggy and build fails case "$ARCH" in - arm) BUILD_DEPENDS="" ;; + arm) + BUILD_DEPENDS="" + ARCH_ARGS="--without-lzma" ;; esac # Rules to configure and make the package. @@ -26,7 +29,6 @@ # and binaries are splited into libxml2-tools compile_rules() { - cd $src autoreconf -fi ./configure \ --prefix=/usr \ @@ -35,7 +37,7 @@ --with-html-dir=/usr/share/doc \ --with-threads \ --with-history \ - $CONFIGURE_ARGS && + $CONFIGURE_ARGS $ARCH_ARGS && make && make DESTDIR=$DESTDIR install 2>&1 | grep -v "can't stat './..html':" } diff -r 159df010240c -r f6332424127f lzlib-dev/receipt --- a/lzlib-dev/receipt Sat Feb 22 23:10:15 2014 +0100 +++ b/lzlib-dev/receipt Sun Feb 23 00:35:49 2014 +0100 @@ -8,6 +8,7 @@ LICENSE="LGPL2.1" WEB_SITE="http://sourceforge.net/projects/sevenzip/" WANTED="lzma" +HOST_ARCH="i486 arm" # Rules to gen a SliTaz package suitable for Tazpkg. genpkg_rules() diff -r 159df010240c -r f6332424127f lzlib/receipt --- a/lzlib/receipt Sat Feb 22 23:10:15 2014 +0100 +++ b/lzlib/receipt Sun Feb 23 00:35:49 2014 +0100 @@ -9,6 +9,7 @@ WEB_SITE="http://sourceforge.net/projects/sevenzip/" DEPENDS="zlib gcc-lib-base" WANTED="lzma" +HOST_ARCH="i486 arm" # Rules to gen a SliTaz package suitable for Tazpkg. genpkg_rules() diff -r 159df010240c -r f6332424127f lzma/receipt --- a/lzma/receipt Sat Feb 22 23:10:15 2014 +0100 +++ b/lzma/receipt Sun Feb 23 00:35:49 2014 +0100 @@ -10,51 +10,25 @@ WEB_SITE="http://sourceforge.net/projects/sevenzip/" WGET_URL="$SF_MIRROR/sevenzip/$TARBALL" TAGS="compression archive" +HOST_ARCH="i486 arm" DEPENDS="lzlib zlib gcc-lib-base" -# Rules to compile & install the temporary toolchain. -cook_tmp_toolchain() +# Rules to configure and make the package. +compile_rules() { - # Put & configure the home-script as needed for tmp toolchain. - rm /tools/usr/bin/lzma /tools/usr/bin/unlzma /tools/usr/bin/lzcat - cp stuff/lzma /tools/usr/bin - chmod 755 /tools/usr/bin/lzma - ln -s /tools/usr/bin/lzma /tools/usr/bin/unlzma - ln -s /tools/usr/bin/lzma /tools/usr/bin/lzcat - sed 's~/usr~/tools/usr~' -i /tools/usr/bin/lzma - - cd $src if [ ! -f done.lzlib.u ]; then patch -p0 < $stuff/lzlib.u || return 1 touch done.lzlib.u fi cd CPP/7zip/Compress/LZMA_Alone - - # Remove copyright message. - sed '/MY_VERSION_COPYRIGHT_DATE/d' -i LzmaAlone.cpp - - make -f makefile.gcc lzma 2> /dev/null - { make -f makefile.gcc liblz.so.1.0.0 && - make -f makefile.gcc lzma - } || return 1 - - cp -a lzma-shared /tools/usr/bin/lzma-alone - cp -a liblz.so.1.0.0 /tools/lib - ln -s /tools/lib/liblz.so.1.0.0 /tools/lib/liblz.so - ln -s /tools/lib/liblz.so.1.0.0 /tools/lib/liblz.so.1 -} - - -# Rules to configure and make the package. -compile_rules() -{ - cd $src - if [ ! -f done.lzlib.u ]; then - patch -p0 < $stuff/lzlib.u || return 1 - touch done.lzlib.u - fi - cd CPP/7zip/Compress/LZMA_Alone + + # Handle cross compilation + case "$ARCH" in + arm) + sed -i s'/g++/arm-slitaz-linux-gnueabi-c++/' makefile.gcc + sed -i s'/gcc/arm-slitaz-linux-gnueabi-gcc/' makefile.gcc ;; + esac # Remove copyright message. sed '/MY_VERSION_COPYRIGHT_DATE/d' -i LzmaAlone.cpp