File: graphviz.spec.in

package info (click to toggle)
graphviz 2.8-2.4
  • links: PTS
  • area: main
  • in suites: etch-m68k
  • size: 20,472 kB
  • ctags: 22,070
  • sloc: ansic: 163,260; cpp: 36,565; sh: 25,032; yacc: 2,354; tcl: 1,808; makefile: 1,745; cs: 805; perl: 801; ml: 649; awk: 160; lex: 153; python: 105; ruby: 32; php: 6
file content (419 lines) | stat: -rw-r--r-- 11,496 bytes parent folder | download | duplicates (2)
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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
# $Id: graphviz.spec.in,v 1.68 2006/01/30 23:45:06 ellson Exp $ $Revision: 1.68 $
# @configure_input@

# Note: graphviz requires gd with gif support (and other fixes), hence use
# internal one for now.

# Define a default set incase none of the conditionals apply
%define SHARP  0
%define GUILE   0
%define _IO     0
%define JAVA    0
%define LUA     0
%define OCAML   0
%define PERL    0
%define PHP     0
%define PYTHON  0
%define RUBY    0
%define TCL     1

# Select packages according to dist (set in .rpmmacros on each build host)

# These are all single line conditional blocks because older versions
# of rpm can't handle multiline blocks/
%{?rh7: %{expand: %%define PERL    1}}
%{?rh7: %{expand: %%define TCL     1}}

%{?rh8: %{expand: %%define PERL    1}}
%{?rh8: %{expand: %%define TCL     1}}

%{?rh9: %{expand: %%define PERL    1}}
%{?rh9: %{expand: %%define TCL     1}}

%{?el2: %{expand: %%define PERL    1}}
%{?el2: %{expand: %%define TCL     1}}

%{?el3: %{expand: %%define PERL    1}}
%{?el3: %{expand: %%define TCL     1}}

%{?el4: %{expand: %%define PERL    1}}
%{?el4: %{expand: %%define PHP     1}}
%{?el4: %{expand: %%define RUBY    1}}
%{?el4: %{expand: %%define TCL     1}}

%{?el5: %{expand: %%define PERL    1}}
%{?el5: %{expand: %%define PHP     1}}
%{?el5: %{expand: %%define RUBY    1}}
%{?el5: %{expand: %%define TCL     1}}

%{?fc1: %{expand: %%define PERL    1}}
%{?fc1: %{expand: %%define TCL     1}}

%{?fc2: %{expand: %%define PERL    1}}
%{?fc2: %{expand: %%define TCL     1}}

%{?fc3: %{expand: %%define PERL    1}}
%{?fc3: %{expand: %%define TCL     1}}

%{?fc4: %{expand: %%define GUILE   1}}
%{?fc4: %{expand: %%define PERL    1}}
%{?fc4: %{expand: %%define PYTHON  1}}
%{?fc4: %{expand: %%define RUBY    1}}
%{?fc4: %{expand: %%define TCL     1}}

%{?fc5: %{expand: %%define SHARP   1}}
%{?fc5: %{expand: %%define GUILE   1}}
%{?fc5: %{expand: %%define JAVA    1}}
%{?fc5: %{expand: %%define LUA     1}}
%{?fc5: %{expand: %%define OCAML   1}}
%{?fc5: %{expand: %%define PERL    1}}
%{?fc5: %{expand: %%define PHP     1}}
%{?fc5: %{expand: %%define PYTHON  1}}
%{?fc5: %{expand: %%define RUBY    1}}
%{?fc5: %{expand: %%define TCL     1}}

Summary:	Graph Visualization Tools
Name:		graphviz
Version:	@VERSION@
Release:	1

Group:		Applications/Multimedia
License:	CPL
URL:		http://www.graphviz.org/
Source:		http://www.graphviz.org/pub/graphviz/ARCHIVE/graphviz-@VERSION@.tar.gz
%{?fc5:Requires: urw-fonts}
%{?fc4:Requires: urw-fonts}
%{?fc3:Requires: urw-fonts}
%{?fc2:Requires: urw-fonts}
%{?fc1:Requires: urw-fonts}
%{?el5:Requires: urw-fonts}
%{?el4:Requires: urw-fonts}
%{?el3:Requires: urw-fonts}

# SuSE uses a different mechanism to generate BuildRequires
# norootforbuild
# neededforbuild  expat freetype2 freetype2-devel gcc libjpeg libpng-devel-packages tcl tcl-devel tk tk-devel x-devel-packages

BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

BuildRequires:	zlib-devel libpng-devel libjpeg-devel expat-devel freetype-devel >= 2
BuildRequires:	/bin/ksh bison m4 flex tk tcl >= 8.3 swig
BuildRequires:	/usr/include/tcl.h /usr/include/tk.h
%{?fc5:BuildRequires: fontconfig-devel libtool-ltdl-devel}
%{?fc5:BuildRequires: libXaw-devel libSM-devel libICE-devel libXpm-devel libXt-devel libXmu-devel libXext-devel libX11-devel}
%{?fc4:BuildRequires: fontconfig-devel xorg-x11-devel libtool-ltdl-devel} 
%{?fc3:BuildRequires: fontconfig-devel xorg-x11-devel} 
%{?fc2:BuildRequires: fontconfig-devel XFree86-devel}
%{?fc1:BuildRequires: fontconfig-devel XFree86-devel}
%{?el5:BuildRequires: fontconfig-devel xorg-x11-devel libtool-ltdl-devel}
%{?el4:BuildRequires: fontconfig-devel xorg-x11-devel}
%{?el3:BuildRequires: fontconfig-devel XFree86-devel}
%{?el2:BuildRequires: XFree86-devel}
%{?rh9:BuildRequires: XFree86-devel}
%{?rh8:BuildRequires: XFree86-devel}
%{?rh7:BuildRequires: XFree86-devel}
%{?rh6:BuildRequires: XFree86-devel}

%description
A collection of tools for the manipulation and layout
of graphs (as in nodes and edges, not as in barcharts).

%files
%defattr(-,root,root,-)
%doc AUTHORS COPYING ChangeLog NEWS README
%{_bindir}/*
%dir %{_libdir}/%{name}
%{_libdir}/%{name}/*.so.*
%{_mandir}/man1/*.1*
%dir %{_datadir}/%{name}
%{_datadir}/%{name}/lefty
%exclude %{_libdir}/%{name}/*/*

#------------------------------------------------------------------
%if %{SHARP}
%package sharp
Group:	Applications/Multimedia
Summary:	C# extension for %{name}
Requires:	%{name} = %{version}-%{release}

%description sharp
C# extensions for %{name}.

%files sharp
%defattr(-,root,root,-)
%dir %{_libdir}/%{name}/sharp
%{_libdir}/%{name}/sharp/*
%exclude %{_libdir}/%{name}/sharp/*.la
%endif

#------------------------------------------------------------------
%if %{GUILE}
%package guile
Group:		Applications/Multimedia
Summary:	Guile extension for %{name}
Requires:	%{name} = %{version}-%{release}

%description guile
Guile extensions for %{name}.

%files guile
%defattr(-,root,root,-)
%dir %{_libdir}/%{name}/guile
%{_libdir}/%{name}/guile/*
%exclude %{_libdir}/%{name}/guile/*.la
%endif

#------------------------------------------------------------------
%if %{_IO}
%package io
Group:		Applications/Multimedia
Summary:	Io extension for %{name}
Requires:	%{name} = %{version}-%{release}

%description io
Java extensions for %{name}.

%files io
%defattr(-,root,root,-)
%dir %{_libdir}/%{name}/io
%{_libdir}/%{name}/io/*
%exclude %{_libdir}/%{name}/io/*.la
%endif

#------------------------------------------------------------------
%if %{JAVA}
%package java
Group:		Applications/Multimedia
Summary:	Java extension for %{name}
Requires:	%{name} = %{version}-%{release}

%description java
Java extensions for %{name}.

%files java
%defattr(-,root,root,-)
%dir %{_libdir}/%{name}/java
%{_libdir}/%{name}/java/*
%exclude %{_libdir}/%{name}/java/*.la
%endif

#------------------------------------------------------------------
%if %{LUA}
%package lua
Group:		Applications/Multimedia
Summary:	Lua extension for %{name}
Requires:	%{name} = %{version}-%{release}

%description lua
Java extensions for %{name}.

%files lua
%defattr(-,root,root,-)
%dir %{_libdir}/%{name}/lua
%{_libdir}/%{name}/lua/*
%exclude %{_libdir}/%{name}/lua/*.la
%endif

#------------------------------------------------------------------
%if %{OCAML}
%package ocaml
Group:		Applications/Multimedia
Summary:	Ocaml extension for %{name}
Requires:	%{name} = %{version}-%{release}

%description ocaml
Ocaml extensions for %{name}.

%files ocaml
%defattr(-,root,root,-)
%dir %{_libdir}/%{name}/ocaml
%{_libdir}/%{name}/ocaml/*
%exclude %{_libdir}/%{name}/ocaml/*.la
%endif

#------------------------------------------------------------------
%if %{PERL}
%package perl
Group:		Applications/Multimedia
Summary:	Perl extension for %{name}
Requires:	%{name} = %{version}-%{release}

%description perl
Perl extensions for %{name}.

%files perl
%defattr(-,root,root,-)
%dir %{_libdir}/%{name}/perl
%{_libdir}/%{name}/perl/*
%exclude %{_libdir}/%{name}/perl/*.la
%endif

#------------------------------------------------------------------
%if %{PHP}
%package php
Group:		Applications/Multimedia
Summary:	PHP extension for %{name}
Requires:	%{name} = %{version}-%{release}

%description php
PHP extensions for %{name}.

%files php
%defattr(-,root,root,-)
%dir %{_libdir}/%{name}/php
%{_libdir}/%{name}/php/*
%exclude %{_libdir}/%{name}/php/*.la
%endif

#------------------------------------------------------------------
%if %{PYTHON}
%package python
Group:		Applications/Multimedia
Summary:	Python extension for %{name}
Requires:	%{name} = %{version}-%{release}

%description python
Python extensions for %{name}.

%files python
%defattr(-,root,root,-)
%dir %{_libdir}/%{name}/python
%{_libdir}/%{name}/python/*
%exclude %{_libdir}/%{name}/python/*.la
%endif

#------------------------------------------------------------------
%if %{RUBY}
%package ruby
Group:		Applications/Multimedia
Summary:	Ruby extension for %{name}
Requires:	%{name} = %{version}-%{release}

%description ruby
Ruby extensions for %{name}.

%files ruby
%defattr(-,root,root,-)
%dir %{_libdir}/%{name}/ruby
%{_libdir}/%{name}/ruby/*
%exclude %{_libdir}/%{name}/ruby/*.la
%endif

#------------------------------------------------------------------
%if %{TCL}
%package tcl
Group:		Applications/Multimedia
Summary:	Tcl extension & tools for %{name}
Requires:	%{name} = %{version}-%{release} tcl >= 8.3 tk

%description tcl
Various tcl packages (extensions) for the %{name} tools.

%files tcl
%defattr(-,root,root,-)
%dir %{_libdir}/%{name}/tcl
%{_libdir}/%{name}/tcl/*
%{_libdir}/%{name}/pkgIndex.tcl
%{_datadir}/%{name}/demo
%{_mandir}/mann/*.n*
%exclude %{_libdir}/%{name}/tcl/*.la
%endif

#------------------------------------------------------------------
%package devel
Group:		Development/Libraries
Summary:	Development package for %{name}
Requires:	%{name} = %{version}-%{release} pkgconfig

%description devel
A collection of tools for the manipulation and layout
of graphs (as in nodes and edges, not as in barcharts).
This package contains development files for %{name}.

%files devel
%defattr(-,root,root,-)
%{_includedir}/%{name}
%{_libdir}/%{name}/*.la
%{_libdir}/%{name}/*.so
%{_libdir}/pkgconfig/*.pc
%{_mandir}/man3/*.3*
%exclude %{_libdir}/%{name}/*/*

#------------------------------------------------------------------
%package graphs
Group:		Applications/Multimedia
Summary:	Demo graphs for %{name}

%description graphs
Some demo graphs for %{name}.

%files graphs
%defattr(-,root,root,-)
%dir %{_datadir}/%{name}
%{_datadir}/%{name}/graphs

#------------------------------------------------------------------
%package doc
Group:		Documentation
Summary:	PDF and HTML documents for %{name}

%description doc
Provides some additional PDF and HTML documentation for %{name}.

%files doc
%defattr(-,root,root,-)
%doc __doc/*

#------------------------------------------------------------------
%prep
%setup -q

%build
# XXX ix86 only used to have -ffast-math, let's use everywhere
%{expand: %%define optflags %{optflags} -ffast-math}
# %%configure is broken in RH7.3 rpmbuild
# need unreleased changes to gd, so use --with-mylibgd for now.
CFLAGS="$RPM_OPT_FLAGS" \
./configure \
      --prefix=%{_prefix} \
      --bindir=%{_bindir} \
      --libdir=%{_libdir} \
      --includedir=%{_includedir} \
      --datadir=%{_datadir} \
      --mandir=%{_mandir} \
      --with-x \
      --with-mylibgd \
      --disable-static \
      --disable-dependency-tracking
%__make %{?_smp_mflags}

%install
rm -rf $RPM_BUILD_ROOT __doc
%{__make} \
    DESTDIR=$RPM_BUILD_ROOT \
    docdir=$RPM_BUILD_ROOT%{_docdir}/%{name} \
    pkgconfigdir=%{_libdir}/pkgconfig \
    install
chmod -x $RPM_BUILD_ROOT%{_datadir}/%{name}/lefty/*
cp -a $RPM_BUILD_ROOT%{_datadir}/%{name}/doc __doc
rm -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/doc

%clean
rm -rf $RPM_BUILD_ROOT

# run "dot -c" to generate plugin config in %{_libdir}/%{name}/config
%post
%{_bindir}/dot -c

# if there is not dot after everything else is done, the remove config
%postun
if ! test -x %{_bindir}/dot; then rm -f %{_libdir}/%{name}/config; fi

%changelog
* Tue Sep 13 2005 John Ellson <ellson@research.att.com>
- split out language bindings into their own rpms so that 
    main rpm doesn't depend on (e.g.) ocaml
* Sat Aug 13 2005 John Ellson <ellson@research.att.com>
- imported various fixes from the Fedora-Extras .spec by Oliver Falk <oliver@linux-kernel.at>
* Wed Jul 20 2005 John Ellson <ellson@research.att.com>
- release 2.4