Subject: [alpine-devel] new aport: libbsd

From: Francesco <[email-masked]>
Date: Tue, 4 Jan 2011 09:21:00 +0100

Please review and commit.
Thanks!

:: Francesco Colista
:: Email : [email-masked]
:: Jabber: [email-masked]
From 26602cab6d608ca5ba83a2b96871eec8042e524f Mon Sep 17 00:00:00 2001
From: Francesco Colista <[email-masked]>
Date: Tue, 4 Jan 2011 08:17:52 +0000
Subject: [PATCH] new aport

---
 testing/libbsd/APKBUILD |   35 +++++++++++++++++++++++++++++++++++
 1 files changed, 35 insertions(+), 0 deletions(-)
 create mode 100644 testing/libbsd/APKBUILD

diff --git a/testing/libbsd/APKBUILD b/testing/libbsd/APKBUILD
new file mode 100644
index 0000000..ea54453
--- /dev/null
+++ b/testing/libbsd/APKBUILD
@@ -0,0 +1,35 @@
+# Contributor: Francesco Colista <[email-masked]>
+# Maintainer: Francesco Colista <[email-masked]>
+
+pkgname=libbsd
+pkgver=0.2.0
+pkgrel=0
+pkgdesc="Provides useful functions commonly found on BSD systems like strlcpy()"
+arch="x86 x86_64"
+url="http://libbsd.freedesktop.org"
+license="custom"
+depends="uclibc-dev"
+makedepends=
+install=
+subpackages=""
+source="http://libbsd.freedesktop.org/releases/$pkgname-$pkgver.tar.gz"
+
+# append extra dependencies to -dev subpackage
+# remove if not used.
+# depends_dev="somepackage-dev"
+
+_builddir="$srcdir"/$pkgname-$pkgver
+
+build() {
+	cd "$_builddir"
+	
+	make exec_prefix=/usr includedir=/usr/include/libbsd || return 1
+}
+
+package() {
+	cd "$_builddir"
+
+	make exec_prefix=/usr includedir=/usr/include/libbsd DESTDIR=$pkgdir install
+}
+
+md5sums="c6d5413e76949b14e4bf13258e63d355  libbsd-0.2.0.tar.gz"
-- 
1.7.3.2

---

From: Natanael Copa <[email-masked]>
Date: Tue, 4 Jan 2011 13:09:16 +0100

Hi,

Please use git send-email when sending patches then i can apply the
directly from mutt rather than manually do 'save attachemnt', scp to
dev box, git am, rm <patch>.

http://alpinelinux.org/wiki/Development_using_git#Submitting_patches_to_the_alpine-devel_mailing_list

On Tue, 4 Jan 2011 09:21:00 +0100

> Subject: [PATCH] new aport

only 'new aport' in git commit log is not very helpful since it does
not show in the log what aport it is.

Please use 'testing/libbsd: new aport' as first line in commit.

Then its helpful to have the package description and url listed in the
commit message.

Then you can easily see and find info what the new package is about
when browsing the aports trere via cgit.
for example:
http://git.alpinelinux.org/cgit/aports/commit/?id=7269013bc00062d01ca5bb2ad4fd55cf5bcd9887

> +pkgdesc="Provides useful functions commonly found on BSD systems
> like strlcpy()" +arch="x86 x86_64"

never add uclibc-dev to depends (unless you have a good reason for it).
The uclibc-dev dependency is automatically pulled in by build-base
which is automatically added to all makedepends.

> +# depends_dev="somepackage-dev"

Those comments should be removed.
> +	make exec_prefix=/usr includedir=/usr/include/libbsd ||
> return 1 +}
> +
> +package() {
> +	cd "$_builddir"
> +
> +	make exec_prefix=/usr includedir=/usr/include/libbsd
> DESTDIR=$pkgdir install +}

separate package() function. good!

> +md5sums="c6d5413e76949b14e4bf13258e63d355  libbsd-0.2.0.tar.gz"

I looked at the build output and it created development files
(/usr/include/*.h /usr/lib/pkgconfig/ ) and doc files. I think you
should add:

subpackages="$pkgname-dev $pkgname-doc"

Can you please fix those things and resend the patch?

You can do: git reset HEAD^ to undo a commit or git commit --amend to
redo it.

Thanks!

-nc

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