Commit 3704cbf4 authored by A. Wilcox's avatar A. Wilcox Committed by Ariadne Conill

main/gtk+2.0: modernise, explicit configure, license

parent 210b3f7f
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=gtk+2.0
pkgver=2.24.31
pkgrel=0
pkgrel=1
subpkg=gtk-update-icon-cache
pkgdesc="The GTK+ Toolkit (v2)"
url="https://www.gtk.org/"
install="$pkgname.post-install $pkgname.post-upgrade $pkgname.post-deinstall"
triggers="$subpkg.trigger=/usr/share/icons/*"
arch="all"
license="LGPL"
options="!check" # Requires xvfb, resulting in eventual circular dependency
license="LGPL-2.0+"
subpackages="$pkgname-dev $pkgname-doc $pkgname-lang $subpkg:icon_cache"
depends="shared-mime-info gtk-update-icon-cache"
......@@ -30,9 +31,9 @@ makedepends="
$depends_dev
cups-dev
expat-dev
gdk-pixbuf-dev
gdk-pixbuf-dev
gettext-dev
glib-dev
glib-dev
gnutls-dev
gobject-introspection-dev
gtk-doc
......@@ -51,16 +52,11 @@ source="https://download.gnome.org/sources/gtk+/${pkgver%.*}/gtk+-$pkgver.tar.xz
gtk2-fixdso.patch
"
builddir="$srcdir"/gtk+-$pkgver
_builddir="$srcdir"/gtk+-$pkgver
prepare() {
local i
cd "$_builddir"
for i in $source; do
case $i in
*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
esac
done
cd "$builddir"
default_prepare
libtoolize --force \
&& aclocal -I m4 \
&& autoconf \
......@@ -68,7 +64,7 @@ prepare() {
}
build() {
cd "$_builddir"
cd "$builddir"
./configure \
--build=$CBUILD \
--host=$CHOST \
......@@ -78,32 +74,34 @@ build() {
--with-xinput=yes \
--without-libjasper \
--with-included-loaders=png \
|| return 1
--with-gdktarget=x11 \
--enable-cups \
--enable-man
# https://bugzilla.gnome.org/show_bug.cgi?id=655517
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool || return 1
make || return 1
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
make
}
package() {
cd "$_builddir"
make DESTDIR="$pkgdir" install || return 1
cd "$builddir"
make DESTDIR="$pkgdir" install
}
dev() {
mkdir -p "$subpkgdir"/usr/bin "$subpkgdir"/usr/share/
mv "$pkgdir"/usr/share/gtk-2.0 "$subpkgdir"/usr/share/ || return 1
mv "$pkgdir"/usr/share/gtk-2.0 "$subpkgdir"/usr/share/
default_dev
replaces="gtk+2.0"
mv "$pkgdir"/usr/bin/gtk-builder-convert \
"$pkgdir"/usr/bin/gtk-demo \
"$subpkgdir"/usr/bin || return 1
"$subpkgdir"/usr/bin
}
icon_cache() {
depends="hicolor-icon-theme"
mkdir -p "$subpkgdir"/usr/bin
mv "$pkgdir"/usr/bin/"$subpkg" "$subpkgdir"/usr/bin || return 1
mv "$pkgdir"/usr/bin/"$subpkg" "$subpkgdir"/usr/bin
}
sha512sums="75b846661308d94b5236e7e1c367deabf57753792ca87e92f9769822dd5ec90e00cd8d5574adcc12162e3702e1ae6dc152278a1d218f9bd9e4d1c8dc1dd520c1 gtk+-2.24.31.tar.xz
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment