Contents of /trunk/extras/firewalld/firewalld-0.2.5-r1.smage2
Parent Directory
|
Revision Log
Revision 12150 -
(show annotations)
(download)
Tue May 8 22:05:10 2012 UTC (12 years, 1 month ago) by niro
File size: 2585 byte(s)
Tue May 8 22:05:10 2012 UTC (12 years, 1 month ago) by niro
File size: 2585 byte(s)
-use autogen.sh
1 | # $Id$ |
2 | |
3 | PNAME="firewalld" |
4 | PVER="0.2.5" |
5 | PBUILD="r1" |
6 | |
7 | SPLIT_PACKAGES="firewalld firewalld-applet" |
8 | |
9 | PCAT="net-misc" |
10 | |
11 | DESCRIPTION="A firewall service daemon with D-BUS interface managing a dynamic firewall." |
12 | HOMEPAGE="https://fedorahosted.org/firewalld/" |
13 | |
14 | COMMON_DEPEND=">= dev-lang/python-2.7 |
15 | >= sys-apps/dbus-1.5 |
16 | >= dev-python/dbus-python-1 |
17 | >= net-misc/iptables-1.4 |
18 | >= net-misc/ebtables-2 |
19 | >= dev-python/python-slip-dbus-0.2.20" |
20 | |
21 | APPLET_DEPEND=">= dev-libs/glib2-2.32 |
22 | >= net-libs/glib-networking-2.32 |
23 | >= x11-libs/gtk3+-2.24 |
24 | >= dev-python/pygobject3-3.2 |
25 | >= net-misc/networkmanager-0.9.4" |
26 | |
27 | SDEPEND="${COMMON_DEPEND} |
28 | ${APPLET_DEPEND} |
29 | >= dev-util/intltool-0.50 |
30 | >= sys-dev/gettext-0.18 |
31 | >= dev-util/pkgconfig-0.25" |
32 | |
33 | SRCFILE="${PNAME}-${PVER}.tar.bz2" |
34 | SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" |
35 | |
36 | sminclude gnome2 mtools cleanutils |
37 | |
38 | SRC_URI=( |
39 | https://fedorahosted.org/released/${PNAME}/${SRCFILE} |
40 | mirror://${PNAME}/${SRCFILE} |
41 | mirror://${PNAME}/${PNAME}-${PVER}-confd.patch |
42 | mirror://${PNAME}/firewalld.service |
43 | ) |
44 | |
45 | UP2DATE="updatecmd 'https://fedorahosted.org/released/firewalld/?C=M;O=A' | lasttarball" |
46 | |
47 | split_info_firewalld() |
48 | { |
49 | DESCRIPTION="A firewall service daemon with D-BUS interface managing a dynamic firewall." |
50 | DEPEND="${COMMON_DEPEND}" |
51 | } |
52 | |
53 | split_info_firewalld-applet() |
54 | { |
55 | DESCRIPTION="Firewalld panel applet." |
56 | DEPEND="== net-misc/firewalld-${PVER} |
57 | ${APPLET_DEPEND}" |
58 | } |
59 | |
60 | src_prepare() |
61 | { |
62 | munpack ${SRCFILE} || die |
63 | cd ${SRCDIR} |
64 | |
65 | # use /etc/conf.d for service configuration |
66 | mpatch ${PNAME}-${PVER}-confd.patch || die |
67 | #mautoreconf || die |
68 | ./autogen.sh || die |
69 | } |
70 | |
71 | src_compile() |
72 | { |
73 | cd ${SRCDIR} |
74 | |
75 | mconfigure --with-systemd-unitdir=/usr/lib/systemd/system || die |
76 | mmake || die |
77 | } |
78 | |
79 | src_install_firewalld() |
80 | { |
81 | cd ${SRCDIR} |
82 | mmake DESTDIR=${BINDIR} install || die |
83 | |
84 | # inject our firewalld.service |
85 | minstallunit firewalld.service || die |
86 | |
87 | # included with firewalld-applet |
88 | rm ${BINDIR}/usr/bin/firewall-applet || die |
89 | rm -r ${BINDIR}/usr/share/applications || die |
90 | rm -r ${BINDIR}/usr/share/icons || die |
91 | rm -r ${BINDIR}/usr/share/glib-2.0 || die |
92 | minstalldocs COPYING || die |
93 | } |
94 | |
95 | src_install_firewalld-applet() |
96 | { |
97 | cd ${SRCDIR} |
98 | mmake DESTDIR=${BINDIR} install || die |
99 | zapmost ${BINDIR} \ |
100 | usr/bin/firewall-applet \ |
101 | usr/share/applications \ |
102 | usr/share/icons \ |
103 | usr/share/glib-2.0 \ |
104 | || die |
105 | } |
106 | |
107 | postinstall_firewalld() |
108 | { |
109 | mreloadunit dbus.service |
110 | mstartunit firewalld.service |
111 | } |
112 | |
113 | postremove_firewalld() |
114 | { |
115 | mstopunit firewalld.service |
116 | mreloadunit dbus.service |
117 | } |
118 | |
119 | postinstall_firewalld-applet() |
120 | { |
121 | gn2_postinstall || die |
122 | } |
123 | |
124 | postremove_firewalld-applet() |
125 | { |
126 | gn2_postremove || die |
127 | } |