Mail archive
alpine-aports

Re: [alpine-aports] [PATCH] testing/stardict: new aport

From: Leonardo Arena <rnalrd_at_gmail.com>
Date: Mon, 10 Apr 2017 14:25:59 +0200

Hi,

On 06/04/2017 23:03, Taner Tas wrote:
> http://stardict-4.sourceforge.net/
> Cross-Platform and international dictionary Software
> ---
> testing/stardict/APKBUILD | 67 ++++++++++++++++++++++++++++++++++++++++++++
> testing/stardict/gcc46.patch | 11 ++++++++
> testing/stardict/glib2.patch | 36 ++++++++++++++++++++++++
> 3 files changed, 114 insertions(+)
> create mode 100644 testing/stardict/APKBUILD
> create mode 100644 testing/stardict/gcc46.patch
> create mode 100644 testing/stardict/glib2.patch
>
> diff --git a/testing/stardict/APKBUILD b/testing/stardict/APKBUILD
> new file mode 100644
> index 00000000..c8ce104a
> --- /dev/null
> +++ b/testing/stardict/APKBUILD
> _at_@ -0,0 +1,67 @@
> +# Contributor: Taner Tas <taner76_at_gmail.com>
> +# Maintainer: Taner Tas <taner76_at_gmail.com>
> +pkgname=stardict
> +pkgver=3.0.6
> +pkgrel=0
> +pkgdesc="Cross-Platform and international dictionary Software"
> +url="http://stardict-4.sourceforge.net/"
> +arch="all"
> +license="GPL"
> +depends="gtk+2.0 libsigc++ zlib"
> +makedepends="gtk+2.0-dev libsigc++-dev libxml2-dev gnome-doc-utils
> + gnome-common enchant-dev espeak-dev zlib-dev mariadb-dev gconf-dev"
> +install=""
> +subpackages="$pkgname-doc $pkgname-lang $pkgname-help::noarch"
> +source="http://downloads.sourceforge.net/project/stardict-4/${pkgver}/${pkgname}-${pkgver}.tar.bz2
> + gcc46.patch
> + glib2.patch"
> +
> +prepare() {
> + cd "$builddir"
> + local i
> + for i in $source; do
> + case $i in
> + *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
> + esac
> + done

Please use "default_prepare" instead of the "for" loop.

> + find dict/src/sigc++* -name \*.h -or -name \*.cc | xargs rm -f || return 1
> +}
> +
> +build() {
> + cd "$builddir"
> + export CXXFLAGS="$CXXLAGS -std=gnu++11"
> + ./autogen.sh

Autogen should be moved into prepare().

> + ./configure \
> + --build=$CBUILD \
> + --host=$CHOST \
> + --prefix=/usr \
> + --sysconfdir=/etc \
> + --mandir=/usr/share/man \
> + --localstatedir=/var \
> + --disable-gnome-support \
> + --disable-dictdotcn \
> + --disable-gucharmap \
> + --disable-scrollkeeper \
> + --disable-festival \
> + --disable-updateinfo \
> + --disable-gpe-support \
> + --disable-schemas-install || return 1
> + make || return 1
> +}
> +
> +package() {
> + cd "$builddir"
> + make DESTDIR="$pkgdir" install || return 1
> +}
> +


All "|| return 1" are no longer necessary since we use "set -e" in abuild.

Thanks!

|_eo






---
Unsubscribe:  alpine-aports+unsubscribe_at_lists.alpinelinux.org
Help:         alpine-aports+help_at_lists.alpinelinux.org
---
Received on Mon Apr 10 2017 - 14:25:59 UTC