updated on Mon Jan 23 00:00:36 UTC 2012
[aur-mirror.git] / firestarter-gtkstatusicon / PKGBUILD
blob9a272c1253701477eac5a6a820e8186cb7ac660f
1 # Maintainer: Phillip Smith <fukawi2@NO-SPAM.gmail.com>
2 # Maintainer: Ska <skatiger@gmail.com>
3 # http://github.com/fukawi2/aur-packages
5 ### I AM ONLY THE PACKAGER, NOT THE DEVELOPER
6 ### Please ask support questions about this software in one of:
7 ###   1) The AUR comments; OR
8 ###   2) Upstream forums/maillist etc; OR
9 ###   3) The ArchLinux forums
10 ### I do not always know enough about the software itself, or don't have the
11 ### time to promptly respond to direct emails.
12 ### If you have found a problem with the package/PKGBUILD (as opposed to
13 ### the software) then please do email me or post an AUR comment.
15 pkgname=firestarter-gtkstatusicon
16 pkgver=1.0.3
17 pkgrel=101
18 _basename=firestarter
19 pkgdesc="GUI fron-end for iptables"
20 arch=('i686' 'x86_64')
21 license=('GPLv2')
22 depends=('iptables' 'gtk2' 'libgnome' 'libgnomeui' 'libglade' 'pango' 'gksu' 'perl-xml-parser')
23 makedepends=('patch')
24 url="http://www.fs-security.com/"
25 conflicts=('firestarter')
26 install="${_basename}.install"
27 source=("http://downloads.sourceforge.net/firestarter/$_basename-$pkgver.tar.gz"
28         'rc.firestarter'
29         '18_fix_memleak.patch'
30         '20-net-tools-ifconfig-format-change.patch'
31         'events-log-fix.patch'
32         'menu-toolbar-icons-fix.patch'
33         'firestarter-gtkstatusicon.patch')
34 md5sums=('f46860a9e16dac4b693bd05f16370b03'
35          '76ece068fa966c70b0764ec9e644edf5'
36          'b31efd1caf430d979e26abb2618a3659'
37          '7bcd40b3690e3833078ea31a8a9935f1'
38          'acd91fefe00edb41dd38fcc91567707f'
39          'ea9cd9b92939c554b26ccdfe735a2d90'
40          'c656553aab6a312d1a1e9b4cfc5e9a36')
42 build() {
43   cd $srcdir/$_basename-$pkgver
44   
45   # Apply patches to fix things
46   # Transparent tray icon (from Ubuntu launchpad)
47 #  patch -Np1 -i "$srcdir/12_firestarter_transparent_icon.patch"
48   # fix GUI crashes on newer Gnome libs (from Ubuntu launchpad)
49   patch -Np1 -i "$srcdir/18_fix_memleak.patch"
50   # patch to use the new 'ifconfig' from net-tools (thanks to Joeny Ang)
51   patch -Np1 -i "$srcdir/20-net-tools-ifconfig-format-change.patch"
52   
53   # Replace kernel.log with iptables.log
54   patch -Np1 -i ../events-log-fix.patch
55   
56   # menu-toolbar-icons-fix.patch: fixed a couple menu and toolbar icons to follow GTK theme
57   patch -Np1 -i ../menu-toolbar-icons-fix.patch
59   # firestarter-gtkstatusicon.patch: use gtkstatusicon replace eggtrayicon
60   patch -Np1 -i ../firestarter-gtkstatusicon.patch
61   
62   # Configure, Build and Install to $pkgdir
63   #configure 
64   ./autogen.sh \
65     --prefix=/usr \
66     --sysconfdir=/etc \
67     --localstatedir=/var
68   
69   make
72 package() {
73   cd $srcdir/$_basename-$pkgver
75   make GCONF_DISABLE_MAKEFILE_SCHEMA_INSTALL=1 DESTDIR=${pkgdir} install
76   
77   # Create default empty ruleset and fix permissions
78   mkdir ${pkgdir}/etc/firestarter/outbound/
79   touch ${pkgdir}/etc/firestarter/outbound/allow-service
80   chown -R root:root ${pkgdir}/etc/firestarter/
82   # Install rc.init script
83   install -D -m755 ${srcdir}/rc.firestarter ${pkgdir}/etc/rc.d/firestarter
84   
85   # Fix the desktop launcher to run with root permission using gksudo.
86   sed -i "s|Exec=|TryExec=gksu\n\0gksu |" \
87     ${pkgdir}/usr/share/gnome/apps/Internet/firestarter.desktop
88   
89   # Move the .desktop file to a standard location
90   install -Dm644 $pkgdir/usr/share/gnome/apps/Internet/${_basename}.desktop $pkgdir/usr/share/applications/${_basename}.desktop
91   rm -rf $pkgdir/usr/share/gnome
92   
93   # Merge Schema files to /usr/share/gconf so the .install file
94   # can update the database at install time.
95   mkdir -p ${pkgdir}/usr/share/gconf/schemas
96   gconf-merge-schema ${pkgdir}/usr/share/gconf/schemas/${_basename}.schemas \
97     ${srcdir}/${_basename}-${pkgver}/*.schemas
98   rm -Rf ${pkgdir}/etc/gconf
101 # vim:set ts=2 sw=2 et: