]> git.pld-linux.org Git - packages/gg.git/blob - gg.spec
- various fixes by Marcin Owsiany <porridge@debian.org>
[packages/gg.git] / gg.spec
1 # Conditional build:
2 #
3 # _without_gnome        - don't build with Gnome
4 # _without_gnome_applet - don't build Gnome applet
5 # _without_kde          - don't build KDE applet
6 # _without_wm_applet    - don't build WM applet
7 # _without_sound        - disable sound support
8
9 # This looks like overkill but some day we might have *everything* bconded :)
10 %{!?_without_gnome:%define _need_gnome  1}
11 %{!?_without_gnome:%define _need_esd   1}
12 %{!?_without_gnome_applet:%define       _need_gnome     1}
13 %{!?_without_gnome_applet:%define _nees_esd   1}
14 %{!?_without_kde:%define _need_arts     1}
15 %{!?_without_wm_applet:%define _need_esd        1}
16
17 Summary:        GNU Gadu - free talking
18 Summary(pl):    GNU Gadu - wolne gadanie
19 Name:           gg
20 Version:        1.0.0
21 Release:        2
22 Epoch:          5
23 License:        GPL
24 Group:          Applications/Communications
25 Source0:        http://dl.sf.net/ggadu/%{name}-%{version}.tar.gz
26 # Source0-md5:  7b32d4c866ef59dfe22373a83b1a9a2a
27 Source1:        %{name}.png
28 Source2:        %{name}_gnome.desktop
29 Source3:        %{name}_WM_applet.desktop
30 Source4:        %{name}_KDE.desktop
31 Icon:           gg.xpm
32 URL:            http://gadu.gnu.pl/
33 %{?_need_arts:BuildRequires:    arts-devel}
34 %if %{!?_without_sound:1}%{?_without_sound:0}
35 %{?_need_esd:BuildRequires:             esound-devel > 0.2.7}
36 %endif
37 %{?_need_gnome:BuildRequires:   gnome-libs-devel}
38 %{?_need_gnome:BuildRequires:   gnome-core-devel}
39 BuildRequires:  gtk+-devel > 1.2.8
40 BuildRequires:  xmms-devel
41
42 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
43
44 %define         _sysconfdir     /etc/X11/GNOME
45 %define         _prefix                 /usr/X11R6
46
47 %description
48 Gadu-Gadu client released on GNU/GPL.
49
50 %description -l pl
51 Klient Gadu-Gadu na licencji GNU/GPL.
52
53 %package common
54 Summary:        GNU Gadu - free talking - common files
55 Summary(pl):    GNU Gadu - wolne gadanie - wspólne pliki
56 Group:          Applications/Communications
57 Obsoletes:      gg =< 0.2.0
58
59 %description common
60 Gadu-Gadu client released on GNU/GPL.
61
62 %description common -l pl
63 Klient Gadu-Gadu na licencji GNU/GPL.
64
65 %package X11
66 Summary:        GNU Gadu - free talking
67 Summary(pl):    GNU Gadu - wolne gadanie
68 Group:          Applications/Communications
69 PreReq:         %{name}-common = %{epoch}:%{version}
70 Provides:       gg = %{epoch}:%{version}-%{release}
71
72 %description X11
73 Gadu-Gadu client released on GNU/GPL.
74
75 %description X11 -l pl
76 Klient Gadu-Gadu na licencji GNU/GPL. Wersja dla X11.
77
78 %package gnome
79 Summary:        GNU Gadu - free talking - GNOME version
80 Summary(pl):    GNU Gadu - wolne gadanie - wersja dla GNOME
81 Group:          Applications/Communications
82 PreReq:         %{name}-common = %{epoch}:%{version}
83 Provides:       gg = %{epoch}:%{version}-%{release}
84
85 %description gnome
86 Gadu-Gadu client released on GNU/GPL. GNOME version
87
88 %description gnome -l pl
89 Klient Gadu-Gadu na licencji GNU/GPL. Wersja dla GNOME.
90
91 %package gnome-applet
92 Summary:        GNU Gadu - free talking - GNOME dockable version
93 Summary(pl):    GNU Gadu - wolne gadanie - wersja dokowalna dla GNOME
94 Group:          Applications/Communications
95 PreReq:         %{name}-common = %{epoch}:%{version}
96 Provides:       gg = %{epoch}:%{version}-%{release}
97
98 %description gnome-applet
99 Gadu-Gadu client released on GNU/GPL. GNOME dockable version
100
101 %description gnome-applet -l pl
102 Klient Gadu-Gadu na licencji GNU/GPL. Wersja dokowalna dla gnome.
103
104 %package wm-applet
105 Summary:        GNU Gadu - free talking - WindowMaker dockable version
106 Summary(pl):    GNU Gadu - wolne gadanie - wersja dokowalna dla WindowMaker'a
107 Group:          Applications/Communications
108 PreReq:         %{name}-common = %{epoch}:%{version}
109 Provides:       gg = %{epoch}:%{version}-%{release}
110
111 %description wm-applet
112 Gadu-Gadu client released on GNU/GPL. WindowMaker dockable version
113
114 %description wm-applet -l pl
115 Klient Gadu-Gadu na licencji GNU/GPL. Wersja dokowalna dla
116 WindowMaker'a.
117
118 %package kde
119 Summary:        GNU Gadu - free talking - KDE version
120 Summary(pl):    GNU Gadu - wolne gadanie - wersja dla KDE
121 Group:          Applications/Communications
122 PreReq:         %{name}-common = %{epoch}:%{version}
123 Provides:       gg = %{epoch}:%{version}-%{release}
124
125 %description kde
126 Gadu-Gadu client released on GNU/GPL. KDE version
127
128 %description kde -l pl
129 Klient Gadu-Gadu na licencji GNU/GPL. Wersja dla KDE.
130
131 %prep
132 %setup -q 
133
134 %build
135 LDFLAGS=" -L%{_libdir} %{rpmldflags}"
136
137 %if %{!?_without_gnome_applet:1}%{?_without_gnome_applet:0}
138 %configure \
139         %{?_without_sound:--disable-esd} \
140         --enable-gnome \
141         --enable-panel \
142         --enable-xmms
143 %{__make}
144 mv -f src/gg src/gg_applet
145 %{__make} clean
146 %endif
147
148 %if %{!?_without_gnome:1}%{?_without_gnome:0}
149 %configure \
150         %{?_without_sound:--disable-esd} \
151         --enable-gnome \
152         --enable-xmms
153 %{__make}
154 mv -f src/gg src/gg_gnome
155 %{__make} clean
156 %endif
157
158 %if %{!?_without_wm_applet:1}%{?_without_wm_applet:0}
159 %configure \
160         %{?_without_sound:--disable-esd} \
161         --enable-dockapp \
162         --enable-xmms
163 %{__make}
164 mv -f src/gg src/gg_wm
165 %{__make} clean
166 %endif
167
168 %if %{!?_without_kde:1}%{?_without_kde:0}
169 %configure \
170         --enable-docklet \
171         %{!?_without_sound:--enable-arts} \
172         --disable-esd \
173         --enable-xmms
174 %{__make}
175 mv -f src/gg src/gg_kde
176 %{__make} clean
177 %endif
178
179 %configure %{?_without_sound:--disable-esd} --enable-xmms
180 %{__make}
181
182 %install
183 rm -rf $RPM_BUILD_ROOT
184 install -d $RPM_BUILD_ROOT{%{_applnkdir}/Network/Communications,%{_pixmapsdir},%{_datadir}/applets/Network/}
185
186 %{__make} install DESTDIR=$RPM_BUILD_ROOT
187 %{!?_without_gnome_applet:install src/gg_applet $RPM_BUILD_ROOT%{_bindir}}
188 %{!?_without_gnome:install src/gg_gnome $RPM_BUILD_ROOT%{_bindir}}
189 %{!?_without_wm_applet:install src/gg_wm $RPM_BUILD_ROOT%{_bindir}}
190 %{!?_without_kde:install src/gg_kde $RPM_BUILD_ROOT%{_bindir}}
191
192 sed -e 's/xpm$/png/' src/GnuGadu.desktop \
193         > $RPM_BUILD_ROOT%{_applnkdir}/Network/Communications/GnuGadu.desktop
194 sed -e 's/xpm$/png/' -e 's/Exec=gg/Exec=gg_applet\ --activate-goad-server=gg/' \
195         src/GnuGadu.desktop > $RPM_BUILD_ROOT%{_datadir}/applets/Network/GnuGadu.desktop
196
197 install %{SOURCE1} $RPM_BUILD_ROOT%{_pixmapsdir}
198 install %{SOURCE2} $RPM_BUILD_ROOT%{_applnkdir}/Network/Communications/GnuGadu_gnome.desktop
199 install %{SOURCE3} $RPM_BUILD_ROOT%{_datadir}/applets/Network/GnuGadu_WM_applet.desktop
200 install %{SOURCE4} $RPM_BUILD_ROOT%{_applnkdir}/Network/Communications/GnuGadu_KDE.desktop
201
202 install -d $RPM_BUILD_ROOT%{_sysconfdir}/CORBA/servers/
203 install src/GnuGadu.gnorba $RPM_BUILD_ROOT%{_sysconfdir}/CORBA/servers/
204
205 %clean
206 rm -rf $RPM_BUILD_ROOT
207
208 %files common
209 %defattr(644,root,root,755)
210 %doc README ChangeLog TODO
211 %{_datadir}/gg
212 %{_pixmapsdir}/*
213
214 %files X11
215 %defattr(644,root,root,755)
216 %attr(755,root,root) %{_bindir}/gg
217 %{_applnkdir}/Network/Communications/GnuGadu.desktop
218
219 %if %{!?_without_gnome:1}%{?_without_gnome:0}
220 %files gnome
221 %defattr(644,root,root,755)
222 %attr(755,root,root) %{_bindir}/gg_gnome
223 %{_applnkdir}/Network/Communications/GnuGadu_gnome.desktop
224 %endif
225
226 %if %{!?_without_gnome_applet:1}%{?_without_gnome_applet:0}
227 %files gnome-applet
228 %defattr(644,root,root,755)
229 %attr(755,root,root) %{_bindir}/gg_applet
230 %{_datadir}/applets/Network/GnuGadu.desktop
231 %{_sysconfdir}/CORBA/servers/GnuGadu.gnorba
232 %endif
233
234 %if %{!?_without_wm_applet:1}%{?_without_wm_applet:0}
235 %files wm-applet
236 %defattr(644,root,root,755)
237 %attr(755,root,root) %{_bindir}/gg_wm
238 %{_datadir}/applets/Network/GnuGadu_WM_applet.desktop
239 %endif
240
241 %if %{!?_without_kde:1}%{?_without_kde:0}
242 %files kde
243 %defattr(644,root,root,755)
244 %attr(755,root,root) %{_bindir}/gg_kde
245 %{_applnkdir}/Network/Communications/GnuGadu_KDE.desktop
246 %endif
This page took 0.149747 seconds and 3 git commands to generate.