You are not logged in.

#1 2004-08-25 07:27:24

tehdely
Member
Registered: 2004-02-20
Posts: 148
Website

Make pacman chomp

Latest patch (for Pacman v2.9.2): here
Thanks to neotuli for adding color wink

[C********************]
[---c*****************]
[----C****************]
[----------c**********]
[-------------C*******]
[----------------c****]
[---------------------]

wink

Credit for this idea goes to Tim Goff.


[Arch GNUstep Repository] [ PKGBUILDS ]
[code][gnustep]
Server = ftp://blkwidow.lerp.com/pub/mirror/arch/gnustep[/code]

Offline

#2 2004-08-25 11:16:00

farphel
Forum Fellow
From: New Hampshire - USA
Registered: 2003-09-18
Posts: 250
Website

Re: Make pacman chomp

This is cute!  I hope Judd decides to include it (or at least make it a comman-line option). smile


Follow the link below, sign up, and accept one promotional offer.  If I can get five suckers (err... friends) to do this, I'll get a free iPod.  Then you too can try to get a free iPod. Thanks! http://www.freeiPods.com/?r=11363142

Offline

#3 2004-08-25 12:02:11

IceRAM
Member
From: Bucharest, Romania
Registered: 2004-03-04
Posts: 772
Website

Re: Make pacman chomp

or a /etc/pacman.conf option enabled by default
[users could (&won't) turn it off after they see it's beauty]]

Offline

#4 2004-08-25 12:38:29

netkrash
Member
From: Viña del Mar, Chile.
Registered: 2003-03-19
Posts: 95

Re: Make pacman chomp

I love it, i'll bug Judd to include it smile...

perhaps an easteregg big_smile


GNU/Linux: Share & Enjoy!

Offline

#5 2004-08-25 13:46:05

ravster
Member
From: Queen's U, Kingston, Canada
Registered: 2004-05-02
Posts: 285
Website

Re: Make pacman chomp

LOL lol  lol
It goes perfectly with the pacman name

Help me, I can't stop grinning lol

Offline

#6 2004-08-25 20:42:40

jsutnoni
Member
Registered: 2004-02-07
Posts: 105

Re: Make pacman chomp

how do I get this to work?


-=JsutNoni=-

Offline

#7 2004-08-25 21:27:32

sarah31
Member
From: Middle of Canada
Registered: 2002-08-20
Posts: 2,975
Website

Re: Make pacman chomp

cool way better and more useful than a gui pacman tongue


AKA uknowme

I am not your friend

Offline

#8 2004-08-26 06:11:23

jsutnoni
Member
Registered: 2004-02-07
Posts: 105

Re: Make pacman chomp

i still havnt been able to get this to work... anyone wanna help me install this? i have no clue how to do it.


-=JsutNoni=-

Offline

#9 2004-08-26 06:24:01

sarah31
Member
From: Middle of Canada
Registered: 2002-08-20
Posts: 2,975
Website

Re: Make pacman chomp

you will have to copy the diff in the first post and save it as, for example, chomp.patch. then copy it to the /var/abs/base/pacman. then edit the PKGBUILD adding:

patch -Np1 -i ../chomp.patch

just below this line:

cd $startdir/src/$pkgname-$pkgver


then run makepkg and install the resulting package.


AKA uknowme

I am not your friend

Offline

#10 2004-08-26 06:25:46

jsutnoni
Member
Registered: 2004-02-07
Posts: 105

Re: Make pacman chomp

exactly what i needed. thank you sarah31.


-=JsutNoni=-

Offline

#11 2004-08-26 06:28:43

jbNet
Member
From: Klamath Falls, OR, USA
Registered: 2004-08-12
Posts: 34

Re: Make pacman chomp

This is great! Please include it!

Offline

#12 2004-08-26 06:42:46

jsutnoni
Member
Registered: 2004-02-07
Posts: 105

Re: Make pacman chomp

This still didnt seem to work for me. I did notice this when building:

==> Starting build()...
patching file src/pacsync.c
Hunk #1 succeeded at 57 with fuzz 1.
Hunk #2 FAILED at 398.
Hunk #3 FAILED at 432.
2 out of 3 hunks FAILED -- saving rejects to file src/pacsync.c.rej
checking for gcc... gcc

-=JsutNoni=-

Offline

#13 2004-08-26 11:51:08

netkrash
Member
From: Viña del Mar, Chile.
Registered: 2003-03-19
Posts: 95

Re: Make pacman chomp

i have the same problem, and doesn't work sad


GNU/Linux: Share & Enjoy!

Offline

#14 2004-08-26 17:04:41

jsutnoni
Member
Registered: 2004-02-07
Posts: 105

Re: Make pacman chomp

anyone have any idea what might be causeing this?


-=JsutNoni=-

Offline

#15 2004-08-26 18:10:42

jbNet
Member
From: Klamath Falls, OR, USA
Registered: 2004-08-12
Posts: 34

Re: Make pacman chomp

maybe the patch needs to be updated for 2.8.4? is this against 2.8.3?

edit: actually no... looks like he did this w/ 2.8.4

Offline

#16 2004-08-26 18:13:00

jsutnoni
Member
Registered: 2004-02-07
Posts: 105

Re: Make pacman chomp

jbNet wrote:

maybe the patch needs to be updated for 2.8.4? is this against 2.8.3?

diff -Naur orig/pacman-2.8.4/src/pacsync.c pacman-2.8.4/src/pacsync.c
--- orig/pacman-2.8.4/src/pacsync.c     2004-07-16 20:16:35.000000000 -0500
+++ pacman-2.8.4/src/pacsync.c  2004-08-25 03:40:13.000000000 -0500 

Im guessing its for 2.8.4


-=JsutNoni=-

Offline

#17 2004-08-26 20:08:38

tehdely
Member
Registered: 2004-02-20
Posts: 148
Website

Re: Make pacman chomp

The patch is against 2.8.4, latest pacman.  If it's failing, you probably haven't synced your abs tree in a while.  Run abs, clean out the src and pkg directories in /var/abs/base/pacman, run 'makepkg -o', apply the patch, then run 'makepkg -e'.


wink


[Arch GNUstep Repository] [ PKGBUILDS ]
[code][gnustep]
Server = ftp://blkwidow.lerp.com/pub/mirror/arch/gnustep[/code]

Offline

#18 2004-08-26 20:11:36

jsutnoni
Member
Registered: 2004-02-07
Posts: 105

Re: Make pacman chomp

i ran abs for the first time when trying this patch. Ill give it ago jsut like you suggested though. thanks.


-=JsutNoni=-

Offline

#19 2004-08-26 20:24:43

jbNet
Member
From: Klamath Falls, OR, USA
Registered: 2004-08-12
Posts: 34

Re: Make pacman chomp

tehdely wrote:

The patch is against 2.8.4, latest pacman.  If it's failing, you probably haven't synced your abs tree in a while.  Run abs, clean out the src and pkg directories in /var/abs/base/pacman, run 'makepkg -o', apply the patch, then run 'makepkg -e'.

Actually I'm just trying to patch it against ftp://ftp.archlinux.org/other/pacman/pa … 8.4.tar.gz

the md5 of the .tar.gz I'm using is: c674c5f15fd71acf930255265ee2e15d
the md5 of the chomp.patch I'm using: 9a9702651f9c8c102655884bb89003fb

I generated the chomp.patch by copy/pasting from mozilla... if I used konqueror it added a space to every line... and I also included an extra line return at the end of the file to leave one blank line

This is what I'm doing:
$ tar zvxf pacman-2.8.4.tar.gz
$ cd pacman-2.8.4
$ patch -p1 < ../chomp.patch
patching file src/pacsync.c
Hunk #1 succeeded at 57 with fuzz 1.
Hunk #2 FAILED at 398.
Hunk #3 FAILED at 432.
2 out of 3 hunks FAILED -- saving rejects to file src/pacsync.c.rej

Here is the pacsync.c.rej:

***************
*** 393,398 ****
         struct timeval t1;
         float timediff;
  
         gettimeofday(&t1, NULL);
         if(xfered+offset == fsz) {
                 t = t0;
--- 398,406 ----
         struct timeval t1;
         float timediff;
  
+        static struct mouth mouth;
+        static unsigned int lastcur = 0;
+ 
         gettimeofday(&t1, NULL);
         if(xfered+offset == fsz) {
                 t = t0;
***************
*** 424,436 ****
         printf(" %s [", sync_fnm);
         cur = (int)((maxcols-64)*pct/100);
         for(i = 0; i < maxcols-64; i++) {
-                (i < cur) ? printf("#") : printf(" ");
         }
         if(rate > 1000) {
                 printf("] %3d%%  %6dK  %6.0fK/s  %02d:%02d:%02dr", pct, ((xfered+offset) / 1024), rate, eta_h, eta_m, eta_s);
         } else {
                 printf("] %3d%%  %6dK  %6.1fK/s  %02d:%02d:%02dr", pct, ((xfered+offset) / 1024), rate, eta_h, eta_m, eta_s);
         }
         fflush(stdout);
         return(1);
  }
--- 432,448 ----
         printf(" %s [", sync_fnm);
         cur = (int)((maxcols-64)*pct/100);
         for(i = 0; i < maxcols-64; i++) {
+                (i < cur) ? printf("-") : (i == cur) ? ((lastcur == cur) ?
+                        (mouth.open ? printf("C") : printf("c")) :
+                        (++mouth.open ? printf("C") : printf("c"))) :
+                        printf("*");
         }
         if(rate > 1000) {
                 printf("] %3d%%  %6dK  %6.0fK/s  %02d:%02d:%02dr", pct, ((xfered+offset) / 1024), rate, eta_h, eta_m, eta_s);
         } else {
                 printf("] %3d%%  %6dK  %6.1fK/s  %02d:%02d:%02dr", pct, ((xfered+offset) / 1024), rate, eta_h, eta_m, eta_s);
         }
+        lastcur = cur;
         fflush(stdout);
         return(1);
  }

I don't see why it's not patching it... maybe some strange whitespace problem? Maybe you could post a working .patch somewhere.

Offline

#20 2004-08-26 21:30:56

jsutnoni
Member
Registered: 2004-02-07
Posts: 105

Re: Make pacman chomp

i resynced abs, ran makepkg -o and then makepkg -e. I dont seem to be getting the errors, but i still get no chomping.


-=JsutNoni=-

Offline

#21 2004-08-26 21:32:44

jbNet
Member
From: Klamath Falls, OR, USA
Registered: 2004-08-12
Posts: 34

Re: Make pacman chomp

jsutnoni wrote:

i resynced abs, ran makepkg -o and then makepkg -e. I dont seem to be getting the errors, but i still get no chomping.

you didn't say anything about applying the patch... did you?

Offline

#22 2004-08-26 21:36:17

jsutnoni
Member
Registered: 2004-02-07
Posts: 105

Re: Make pacman chomp

yes i did apply the patch. it looks like this:

build() {
  cd $startdir/src/$pkgname-$pkgver
  patch -Np1 -i ../chomp.patch
  ./configure --prefix=/usr
  make || return 1

-=JsutNoni=-

Offline

#23 2004-08-26 21:39:59

jsutnoni
Member
Registered: 2004-02-07
Posts: 105

Re: Make pacman chomp

found the error... i dont get it?!?!


-=JsutNoni=-

Offline

#24 2004-08-26 21:41:05

tehdely
Member
Registered: 2004-02-20
Posts: 148
Website

Re: Make pacman chomp

OK, if this doesn't make your pacman chomp, then I blame sunspots.

# $Id: PKGBUILD,v 1.99 2004/08/23 06:55:12 judd Exp $
# Maintainer: judd <jvinet@zeroflux.org>
pkgname=pacman
pkgver=2.8.4
pkgrel=2
pkgdesc="A .tar.gz based package manager with dependency support"
url="http://www.archlinux.org/pacman"
backup=('etc/pacman.conf' 'etc/makepkg.conf' 'etc/abs/abs.conf')
makedepends=('libtar')
install=pacman.install
source=(ftp://ftp.archlinux.org/other/pacman/$pkgname-$pkgver.tar.gz 
  http://www.archlinux.org/pacman/sortmirrors.pl 
  supfile.arch supfile.extra supfile.unstable abs abs.conf 
  http://delysid.frap.net/chomp.diff)
md5sums=('c674c5f15fd71acf930255265ee2e15d' '005d82a4832b5273450e556f30010414'
         '2c564a8760ec0dac96082f1855d153d1' 'f83885f6c431e4e7f8b131fe444ac0d2'
         '9a44663da93a07c8df42741ea0e41930' '0025f9f786d50201951fc7444207a089'
         '5dfcce0aa5e121936c002e555d6fb55e' '0c627d9e9527b05c146aeeb7f289199a')

build() {
  cd $startdir/src/$pkgname-$pkgver
  patch -Np1 < $startdir/src/chomp.diff
  ./configure --prefix=/usr
  make || return 1
  make DESTDIR=$startdir/pkg install
  mkdir -p $startdir/pkg/var/abs/local
  install -D -m755 ../sortmirrors.pl $startdir/pkg/usr/bin/sortmirrors.pl
  install -D -m755 ../abs $startdir/pkg/usr/bin/abs
  install -D -m644 ../abs.conf $startdir/pkg/etc/abs/abs.conf
  install -D -m644 ../supfile.arch $startdir/pkg/etc/abs/supfile.arch
  install -D -m644 ../supfile.extra $startdir/pkg/etc/abs/supfile.extra
  install -D -m644 ../supfile.unstable $startdir/pkg/etc/abs/supfile.unstable
  sed -i "s|i686|$CARCH|g" $startdir/pkg/etc/pacman.d/*
}

[Arch GNUstep Repository] [ PKGBUILDS ]
[code][gnustep]
Server = ftp://blkwidow.lerp.com/pub/mirror/arch/gnustep[/code]

Offline

#25 2004-08-26 21:45:21

jsutnoni
Member
Registered: 2004-02-07
Posts: 105

Re: Make pacman chomp

what was i doing wrong? id like to know so it dont happen again.


-=JsutNoni=-

Offline

Board footer

Powered by FluxBB