Re: Cookutils development

[ Thread Index | Date Index | More lists.tuxfamily.org/slitaz Archives ]


I had to update the patch anyways. I
http://pastebin.com/h2EdHjYd

here is how i trying to do git with my cooker:

                pwd=$(pwd)
                url="">                pkgsrc=${SOURCE:-$PACKAGE}-$VERSION
                tarball=$pkgsrc.tar.lzma
                [ -x /usr/bin/git ] || (echo "ERROR: Install git." && exit 1)
                gettext "Getting source from git: "; echo $url
                gettext "Cloning to: "; echo "$pwd/$pkgsrc"
                if [ "$BRANCH" ]; then
                gettext "Getting branch: "; echo $BRANCH
                git clone $url $pkgsrc || (echo "ERROR: git clone $url" && exit 1)
                cd $pkgsrc
                git checkout $BRANCH || (echo "ERROR: branch $BRANCH doesn't exist" && exit 1)
                cd $pwd
                else
                    git clone $url $pkgsrc || (echo "ERROR: git clone $url" && exit 1)
                fi
                [ -d $pkgsrc/.git ] && rm -rf $pkgsrc/.git
                gettext "Creating tarball: "; echo "$tarball"
                tar -c $pkgsrc | lzma e $SRC/$tarball -si || exit 1
                rm -rf $pkgsrc ;;

It also added BRANCH support since thats used for download a know version. It in pcxr-svn receipt for you to check it out.

I also add support to rebuild source as .tar.lzma. Yiou need to rebuild sources in cook. Otherwise you can't COOK_OPT="!repack". You just force everything into .tar.lzma and things will not build right when it to be like original archive. Icedtead6-jdk is a good example of this.

On Sat, May 7, 2011 at 2:21 PM, Christophe Lincoln <pankso@xxxxxxxxxx> wrote:

Hi,

I open a new thread since we use differents one actually for developing
cookutils.

Christopher can you please send back your last link for the code about
tazdev. Also, I added support for git in cookutils, it work fine if
TARBALL is set otherwise it will dl each time and can't untar. I saure
they is few receipt using git and aufs dont compile but I did not look
at it for now.

For me the way I implemented hg|git is the KISS way:

  * Clone repo in cache package-version
  * Create a source package-version.tar.bz2
  * Mouve the tarball to SRC (compression in lzma
    before upload on mirror

And let cook/tazwok handle the tarball like all other packages.

- Christophe

---
SliTaz GNU/Linux Mailing list - http://www.slitaz.org/




Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/