Also you may want to add this to cook:

# Remove .pyc, .pyo, perllocal.pod and .packlist files from packages.
py_compiled_files_remove()
{
    echo "Removing all .pyc, .pyo, perllocal.pod, and .packlist files from
package"
    find $fs -type f -name "*.pyc" -delete 2>/dev/null
    find $fs -type f -name "*.pyo" -delete 2>/dev/null
    find $fs -type f -name "perllocal.pod" -delete 2>/dev/null
    find $fs -type f -name ".packlist" -delete 2>/dev/null
}

These files need to remove inorder to save space and cpu time. perllocal.pod
for example is in like every perl package with the same path. Trying to
remove frozen-bubble when you have 4 packages that need modifeds took like 5
mins. Anyway this files are safe to be removed since archlinux does with
each package.

On Sat, May 7, 2011 at 2:54 PM, Christopher Rogers
<[email protected]>wrote:

> I had to update the patch anyways. I
> <http://pastebin.com/fq6KFz30>http://pastebin.com/h2EdHjYd
>
> here is how i trying to do git with my cooker:
>
>                 pwd=$(pwd)
>                 url=${i#git|}
>                 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 <[email protected]>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/
>>
>>
>

Reply via email to