Subject: [alpine-devel] extra/cutter

From: Michael Mason <[email-masked]>
Date: Fri, 20 Feb 2009 21:22:01 +0000

Please apply.
I hope this is the correct one from the list...

---

From: Natanael Copa <[email-masked]>
Date: Mon, 23 Feb 2009 13:55:07 +0100

> I hope this is the correct one from the list...

Looks good. please see the comments below.

> 
> 
> 
> 
> 
> 
> differences
> between files
> attachment
> (0001-Adding-cutter-APKBUILD.patch)
> 
> From 441815fe3fab31dd4c39f1211690d92252df0bff Mon Sep 17 00:00:00 2001
> From: ms13sp <[email-masked]>
> Date: Fri, 20 Feb 2009 21:18:33 +0000
> Subject: [PATCH] Adding cutter APKBUILD
> 
> ---
>  extra/cutter/APKBUILD |   30 ++++++++++++++++++++++++++++++
>  1 files changed, 30 insertions(+), 0 deletions(-)
>  create mode 100644 extra/cutter/APKBUILD
> 
> diff --git a/extra/cutter/APKBUILD b/extra/cutter/APKBUILD
> new file mode 100644
> index 0000000..66c8a43
> --- /dev/null
> +++ b/extra/cutter/APKBUILD
> @@ -0,0 +1,30 @@
> +# Contributor: ms13sp <[email-masked]>
> +# Maintainer: ms13sp <[email-masked]>
> +pkgname=cutter
> +pkgver=1.03
> +pkgrel=0
> +pkgdesc="An open source program that allows Linux firewall administrators to abort TCP/IP connections routed over the firewall or router on which it is run."

I feel this is a bit to long. Could we shorten down the description? Not
critical, but would be nice.

> +url="http://www.lowth.com/cutter"
> +license="GPL"
> +depends=""

nclab01:~/aports/extra/cutter$ scanelf -Rn pkg/
 TYPE   NEEDED FILE 
ET_DYN libc.so.0,ld-uClibc.so.0 pkg/usr/sbin/cutter 

uclibc needs to be in depends.

> +makedepends=""
> +install=
> +subpackages=""
> +source="http://www.lowth.com/cutter/software/$pkgname-$pkgver.tgz"
> +
> +build() {
> +       cd "$srcdir/$pkgname-$pkgver"
> +       #no make install and no configure script
> +
> +       make || return 1
> +       
> +       mkdir -p "$pkgdir"/usr/sbin/ 
> +       
> +       install -m755 -D "$srcdir"/"$pkgname"-"$pkgver"/"$pkgname" "$pkgdir"/usr/sbin/"$pkgname"
                                    ^^^
you dont really need "" around pkgname and pkgver since those are not
allowed to have spaces. They dont hurt though. Dirs should always have
them or things will go wrong if there are spaces in the path somewhere.

Also, since you already are in $srcdir/$pkgname-$pkgdir you could have
done:

install -m755 -D cutter "$pkgdir"/usr/sbin/cutter

(i use cutter since its the name of the binary file, not the package
itself. but that is just a question of taste. $pkgname there is fully
ok.)

> +       
> +       #make DESTDIR="$pkgdir" install
> +       # install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname
> +       # install -m644 -D "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname

those are dead code and should preferrible be removed.

> +}
> +
> +md5sums="50093db9b64277643969ee75b83ebbd1  cutter-1.03.tgz"
> -- 
> 1.6.1.3

I commit as is. Please send a new patch that at least adds uclibc to
depends. the rest of the suggestions are optional. 

-nc

---
Unsubscribe:  [email-masked]
Help:         [email-masked]
---