summaryrefslogtreecommitdiff
path: root/libre/faenza-icon-theme-libre/PKGBUILD
blob: 81a1ec73e8d559c64a6226e2f6c962cba4f09e37 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
# $Id: PKGBUILD 82319 2013-01-14 22:07:03Z thestinger $
# Maintainer (Arch): Daniel Micay <danielmicay@gmail.com>
# Contributor (Arch): Elia Notarangelo <elia.notarangelo AT gmail DOT com>
# Contributor (Arch): Frikilinux <frikilinux at frikilinux.com.ar>
# Contributor (Arch): graysky <graysky AT archlinux DOT us>
# Contributor (Arch): Samsagax <samsagax AT gmail DOT com>
# Contributor (Arch): simongmzlj <simongmzlj AT gmail DOT com>
# Maintainer: André Silva <emulatorman@parabola.nu>
# Contributor: Jorge Araya Navarro <elcorreo@deshackra.com>
# Contributor: Márcio Silva <coadde@parabola.nu>

_pkgname=faenza-icon-theme
pkgname=faenza-icon-theme-libre
pkgver=1.3.1
pkgrel=2.1
pkgdesc="Icon theme designed for Equinox GTK theme, without nonfree distros and application icons (Parabola rebranded)"
url="http://gnome-look.org/content/show.php/Faenza?content=128143"
license=('GPL3')
arch=('any')
replaces=($_pkgname)
conflicts=($_pkgname)
provides=($_pkgname=$pkgver)
options=(!strip)
makedepends=('librsvg')
source=("http://ppa.launchpad.net/tiheum/equinox/ubuntu/pool/main/f/$_pkgname/${_pkgname}_${pkgver}.tar.gz"
        'distributor-logo-parabola.svg'
        'start-here-parabola-symbolic.svg')
md5sums=('b5339b70cbb821b583499e725957b150'
         '0dfb27e36d60266d8f4c3ea763ec1694'
         'e2301755fc4c552cfee7de72b6ed775a')

prepare() {
 cd "$srcdir/$_pkgname-1.3"
 rm -rv debian

 # remove nonfree distros and application logos
 for nonfree in archlinux debian fedora frugalware gentoo linux-mint mandriva opensuse redhat slackware ubuntu flash rpmdrake novell skype; do
  find -name *$nonfree* -delete
 done

  # add the Parabola GNU/Linux-libre logos to the source code
  cp -a "$srcdir/distributor-logo-parabola.svg" Faenza/places/scalable
  cp -a "$srcdir/distributor-logo-parabola.svg" Faenza/places/scalable/start-here-parabola.svg
  cp -a "$srcdir/start-here-parabola-symbolic.svg" Faenza/places/scalable

  for size in 22 24 32 48 64 96; do
   rsvg-convert -w $size -h $size -o Faenza/places/$size/distributor-logo-parabola.png "$srcdir/distributor-logo-parabola.svg"
   rsvg-convert -w $size -h $size -o Faenza/places/$size/start-here-parabola.png "$srcdir/distributor-logo-parabola.svg"
   rsvg-convert -w $size -h $size -o Faenza/places/$size/start-here-parabola-symbolic.png "$srcdir/start-here-parabola-symbolic.svg"

   ln -sf Faenza/places/$size/distributor-logo-parabola.png Faenza/places/$size/parabola-logo.png
   ln -sf Faenza/places/scalable/distributor-logo-parabola.svg parabola-logo.svg
   ln -sf Faenza/places/scalable/start-here-parabola.svg Faenza-Dark/places/scalable/start-here-parabola.svg
   ln -sf Faenza/places/scalable/start-here-parabola-symbolic.svg  Faenza-Dark/places/scalable/start-here-parabola-symbolic.svg
  done
}

package() {
  cd "$srcdir/$_pkgname-1.3"
  mkdir -p "$pkgdir/usr/share/icons" "$pkgdir/usr/lib" "$pkgdir/usr/share"

  cp -rf Faenza{,-Dark,-Darkest,-Darker,-Ambiance,-Radiance} "$pkgdir/usr/share/icons/"
  cp -rf rhythmbox "$pkgdir/usr/lib/"
  cp -rf emesene "$pkgdir/usr/share/"

  # set the Parabola GNU/Linux-libre Distributor and start menu logo
  for theme in Faenza{,-Dark}; do
    for size in 22 24 32 48 64 96; do
      cd "$pkgdir/usr/share/icons/$theme/places/$size/"
      # no distributor-logo for Faenza-Dark
      [[ $theme == Faenza ]] && ln -sf distributor-logo{-parabola,}.png
      ln -sf start-here{-parabola,}.png
    done
    cd "$pkgdir/usr/share/icons/$theme/places/scalable/"
    # no distributor-logo for Faenza-Dark
    [[ $theme == Faenza ]] && ln -sf distributor-logo{-parabola,}.svg
    ln -sf start-here{-parabola,}.svg
    ln -sf start-here{-parabola-symbolic,-symbolic}.svg
  done
}