forked from davidhrbac/specs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
glusterfs.spec
380 lines (293 loc) · 13.3 KB
/
glusterfs.spec
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
#define pre rc8
## NOTE: Lots of files in various subdirectories have the same name (such as
## "LICENSE") so this short macro allows us to distinguish them by using their
## directory names (from the source tree) as prefixes for the files.
## Usage: add_to_doc_files subdirname files
%define add_to_doc_files() \
%{__mkdir_p} %{buildroot}%{_docdir}/%{name}-%{version}/%1 ||: ; \
%{__cp} -p %2 %{buildroot}%{_docdir}/%{name}-%{version}/%1
# Possible rpmbuild options
%{?_without_ibverbs:%define _without_ibverbs --disable-ibverbs}
%{?_without_client:%define _without_client --disable-fuse-client}
%{?_without_python:%define _without_python --disable-python}
# Disable the python bindings if we have < 2.4, since 2.4+ is required
%if "%(%{__python} -c "import sys ; print sys.version[:3]")" < "2.4"
%define _without_python --disable-python
%endif
Summary: Cluster File System
Name: glusterfs
Version: 2.0.9
Release: 1%{?pre:.%{pre}}%{?dist}
License: GPLv3+
Group: System Environment/Base
URL: http://www.gluster.org/
Source0: http://ftp.gluster.com/pub/gluster/glusterfs/2.0/%{version}/glusterfs-%{version}%{?pre}.tar.gz
Source1: glusterfsd.init
Source2: glusterfsd.sysconfig
Source3: umount.glusterfs
Source4: glusterfs.logrotate
Source5: glusterfsd.logrotate
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Requires(post): /sbin/chkconfig
Requires(preun): /sbin/service, /sbin/chkconfig
Requires(postun): /sbin/service
%{!?_without_ibverbs:BuildRequires: libibverbs-devel}
%{!?_without_client:BuildRequires: fuse-devel}
%{!?_without_python:BuildRequires: python-devel}
BuildRequires: flex, bison, byacc
%description
GlusterFS is a clustered file-system capable of scaling to several
peta-bytes. It aggregates various storage bricks over Infiniband RDMA
or TCP/IP interconnect into one large parallel network file
system. GlusterFS is one of the most sophisticated file system in
terms of features and extensibility. It borrows a powerful concept
called Translators from GNU Hurd kernel. Much of the code in GlusterFS
is in userspace and easily manageable.
%package common
Summary: GlusterFS common files for both the client and the server
Group: System Environment/Libraries
Obsoletes: glusterfs-libs < 2.0.0
Provides: glusterfs-libs = %{version}-%{release}
%description common
GlusterFS is a clustered file-system capable of scaling to several
peta-bytes. It aggregates various storage bricks over Infiniband RDMA
or TCP/IP interconnect into one large parallel network file
system. GlusterFS is one of the most sophisticated file system in
terms of features and extensibility. It borrows a powerful concept
called Translators from GNU Hurd kernel. Much of the code in GlusterFS
is in userspace and easily manageable.
This package includes the glusterfs binary, libglusterfs and glusterfs
translator modules common to both GlusterFS server and client framework.
%package client
Summary: GlusterFS Client
Group: Applications/File
Requires: fuse
Requires: %{name}-common = %{version}-%{release}
%description client
GlusterFS is a clustered file-system capable of scaling to several
peta-bytes. It aggregates various storage bricks over Infiniband RDMA
or TCP/IP interconnect into one large parallel network file
system. GlusterFS is one of the most sophisticated file system in
terms of features and extensibility. It borrows a powerful concept
called Translators from GNU Hurd kernel. Much of the code in GlusterFS
is in userspace and easily manageable.
This package provides the FUSE based GlusterFS client.
%package server
Summary: GlusterFS Server
Group: System Environment/Daemons
Requires: %{name}-common = %{version}-%{release}
%description server
GlusterFS is a clustered file-system capable of scaling to several
peta-bytes. It aggregates various storage bricks over Infiniband RDMA
or TCP/IP interconnect into one large parallel network file
system. GlusterFS is one of the most sophisticated file system in
terms of features and extensibility. It borrows a powerful concept
called Translators from GNU Hurd kernel. Much of the code in GlusterFS
is in userspace and easily manageable.
This package provides the glusterfs server daemon.
%package devel
Summary: GlusterFS Development Libraries
Group: Development/Libraries
Requires: %{name}-common = %{version}-%{release}
%description devel
GlusterFS is a clustered file-system capable of scaling to several
peta-bytes. It aggregates various storage bricks over Infiniband RDMA
or TCP/IP interconnect into one large parallel network file
system. GlusterFS is one of the most sophisticated file system in
terms of features and extensibility. It borrows a powerful concept
called Translators from GNU Hurd kernel. Much of the code in GlusterFS
is in userspace and easily manageable.
This package provides the development libraries.
%prep
%setup -q -n %{name}-%{version}%{?pre}
# Remove file, it gets re-generated by bison (was causing koji build failures)
rm -f libglusterfs/src/y.tab.c
# Don't get executable sources in the debuginfo package (as of 2.0.0rc7)
chmod -x libglusterfsclient/src/*.{c,h}
%build
# Temp disable stack-protector until upstream fixes code
CFLAGS=`echo "%optflags"|sed 's/-D_FORTIFY_SOURCE=2/-D_FORTIFY_SOURCE=1/'`
%configure %{?_without_ibverbs} %{?_without_client} %{?_without_python}
# Remove rpath
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
%{__make} %{?_smp_mflags}
%install
%{__rm} -rf %{buildroot} examples
%{__make} install DESTDIR=%{buildroot}
%{__mkdir_p} %{buildroot}/var/log/glusterfs
%{__mkdir_p} %{buildroot}%{_includedir}/glusterfs
%{__install} -p -m 0644 libglusterfs/src/*.h \
%{buildroot}%{_includedir}/glusterfs/
# Remove unwanted files from all of the shared libraries
find %{buildroot}%{_libdir}/glusterfs -name '*.a' -o -name '*.la' | xargs rm -f
# Remove installed docs, we include them ourselves as %%doc
%{__rm} -rf %{buildroot}%{_datadir}/doc/glusterfs/
# Rename the samples, so we can include them as %%config
for file in %{buildroot}%{_sysconfdir}/glusterfs/*.sample; do
%{__mv} ${file} `dirname ${file}`/`basename ${file} .sample`
done
# Clean up the examples we want to include as %%doc
%{__cp} -a doc/examples examples
%{__rm} -f examples/Makefile*
# Install init script and sysconfig file
%{__install} -D -p -m 0755 %{SOURCE1} \
%{buildroot}%{_sysconfdir}/init.d/glusterfsd
%{__install} -D -p -m 0644 %{SOURCE2} \
%{buildroot}%{_sysconfdir}/sysconfig/glusterfsd
%if 0%{!?_without_client:1}
# Install wrapper umount script
%{__install} -D -p -m 0755 %{SOURCE3} \
%{buildroot}/sbin/umount.glusterfs
# Client logrotate entry
%{__install} -D -p -m 0644 %{SOURCE4} \
%{buildroot}%{_sysconfdir}/logrotate.d/glusterfs
%endif
# Server logrotate entry
%{__install} -D -p -m 0644 %{SOURCE5} \
%{buildroot}%{_sysconfdir}/logrotate.d/glusterfsd
# Install extra documentation
%add_to_doc_files benchmarking extras/benchmarking/{*.c,README,*.sh}
%clean
%{__rm} -rf %{buildroot}
%post common -p /sbin/ldconfig
%postun common -p /sbin/ldconfig
%post server
/sbin/chkconfig --add glusterfsd
%preun server
if [ $1 -eq 0 ]; then
/sbin/service glusterfsd stop &>/dev/null || :
/sbin/chkconfig --del glusterfsd
fi
%postun server
if [ $1 -ge 1 ]; then
/sbin/service glusterfsd condrestart &>/dev/null || :
fi
%files common
%doc AUTHORS ChangeLog COPYING NEWS README extras/{glusterfs-mode.el,glusterfs.vim}
%{_docdir}/%{name}-%{version}/benchmarking
%{_libdir}/glusterfs/
%{_libdir}/*.so.*
%{_sbindir}/glusterfs
%{_sbindir}/glusterfsd
%{_mandir}/man8/glusterfs.8*
%dir /var/log/glusterfs/
%if 0%{!?_without_client:1}
%files client
%config(noreplace) %{_sysconfdir}/logrotate.d/glusterfs
/sbin/mount.glusterfs
/sbin/umount.glusterfs
%endif
%files server
%doc examples/ doc/glusterfs*.vol.sample
%dir %{_sysconfdir}/glusterfs/
%config(noreplace) %{_sysconfdir}/glusterfs/*.vol
%config(noreplace) %{_sysconfdir}/logrotate.d/glusterfsd
%config(noreplace) %{_sysconfdir}/sysconfig/glusterfsd
%{_sysconfdir}/init.d/glusterfsd
%files devel
%{_includedir}/glusterfs/
%{_includedir}/libglusterfsclient.h
%{_datadir}/glusterfs/*
%{_bindir}/glusterfs-volgen
%exclude %{_libdir}/*.a
%exclude %{_libdir}/*.la
%{_libdir}/*.so
%changelog
* Fri Aug 27 2010 David Hrbáč <[email protected]> - 2.0.9-1
- new upstream release
* Thu Nov 19 2009 David Hrbáč <[email protected]> - 2.0.8-1
- initial release
* Sat Nov 8 2009 Jonathan Steffan <[email protected]> - 2.0.8-1
- Update to 2.0.8
- Remove install of glusterfs-volgen, it's properly added to
automake upstream now
* Sat Oct 31 2009 Jonathan Steffan <[email protected]> - 2.0.7-1
- Update to 2.0.7
- Install glusterfs-volgen, until it's properly added to automake
by upstream
- Add macro to be able to ship more docs
* Thu Sep 17 2009 Peter Lemenkov <[email protected]> 2.0.6-2
- Rebuilt with new fuse
* Sat Sep 12 2009 Matthias Saou <http://freshrpms.net/> 2.0.6-1
- Update to 2.0.6.
- No longer default to disable the client on RHEL5 (#522192).
- Update spec file URLs.
* Mon Jul 27 2009 Matthias Saou <http://freshrpms.net/> 2.0.4-1
- Update to 2.0.4.
* Thu Jun 11 2009 Matthias Saou <http://freshrpms.net/> 2.0.1-2
- Remove libglusterfs/src/y.tab.c to fix koji F11/devel builds.
* Sat May 16 2009 Matthias Saou <http://freshrpms.net/> 2.0.1-1
- Update to 2.0.1.
* Thu May 7 2009 Matthias Saou <http://freshrpms.net/> 2.0.0-1
- Update to 2.0.0 final.
* Wed Apr 29 2009 Matthias Saou <http://freshrpms.net/> 2.0.0-0.3.rc8
- Move glusterfsd to common, since the client has a symlink to it.
* Fri Apr 24 2009 Matthias Saou <http://freshrpms.net/> 2.0.0-0.2.rc8
- Update to 2.0.0rc8.
* Sun Apr 12 2009 Matthias Saou <http://freshrpms.net/> 2.0.0-0.2.rc7
- Update glusterfsd init script to the new style init.
- Update files to match the new default vol file names.
- Include logrotate for glusterfsd, use a pid file by default.
- Include logrotate for glusterfs, using killall for lack of anything better.
* Sat Apr 11 2009 Matthias Saou <http://freshrpms.net/> 2.0.0-0.1.rc7
- Update to 2.0.0rc7.
- Rename "libs" to "common" and move the binary, man page and log dir there.
* Tue Feb 24 2009 Fedora Release Engineering <[email protected]>
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
* Mon Feb 16 2009 Matthias Saou <http://freshrpms.net/> 2.0.0-0.1.rc1
- Update to 2.0.0rc1.
- Include new libglusterfsclient.h.
* Mon Feb 16 2009 Matthias Saou <http://freshrpms.net/> 1.3.12-1
- Update to 1.3.12.
- Remove no longer needed ocreat patch.
* Thu Jul 17 2008 Matthias Saou <http://freshrpms.net/> 1.3.10-1
- Update to 1.3.10.
- Remove mount patch, it's been included upstream now.
* Fri May 16 2008 Matthias Saou <http://freshrpms.net/> 1.3.9-1
- Update to 1.3.9.
* Fri May 9 2008 Matthias Saou <http://freshrpms.net/> 1.3.8-1
- Update to 1.3.8 final.
* Tue Apr 23 2008 Matthias Saou <http://freshrpms.net/> 1.3.8-0.10
- Include short patch to include fixes from latest TLA 751.
* Mon Apr 22 2008 Matthias Saou <http://freshrpms.net/> 1.3.8-0.9
- Update to 1.3.8pre6.
- Include glusterfs binary in both the client and server packages, now that
glusterfsd is a symlink to it instead of a separate binary.
* Sun Feb 3 2008 Matthias Saou <http://freshrpms.net/> 1.3.8-0.8
- Add python version check and disable bindings for version < 2.4.
* Sun Feb 3 2008 Matthias Saou <http://freshrpms.net/> 1.3.8-0.7
- Add --without client rpmbuild option, make it the default for RHEL (no fuse).
(I hope "rhel" is the proper default macro name, couldn't find it...)
* Wed Jan 30 2008 Matthias Saou <http://freshrpms.net/> 1.3.8-0.6
- Add --without ibverbs rpmbuild option to the package.
* Mon Jan 14 2008 Matthias Saou <http://freshrpms.net/> 1.3.8-0.5
- Update to current TLA again, patch-636 which fixes the known segfaults.
* Thu Jan 10 2008 Matthias Saou <http://freshrpms.net/> 1.3.8-0.4
- Downgrade to glusterfs--mainline--2.5--patch-628 which is more stable.
* Tue Jan 8 2008 Matthias Saou <http://freshrpms.net/> 1.3.8-0.3
- Update to current TLA snapshot.
- Include umount.glusterfs wrapper script (really needed? dunno).
- Include patch to mount wrapper to avoid multiple identical mounts.
* Sun Dec 30 2007 Matthias Saou <http://freshrpms.net/> 1.3.8-0.1
- Update to current TLA snapshot, which includes "volume-name=" fstab option.
* Mon Dec 3 2007 Matthias Saou <http://freshrpms.net/> 1.3.7-6
- Re-add the /var/log/glusterfs directory in the client sub-package (required).
- Include custom patch to support vol= in fstab for -n glusterfs client option.
* Mon Nov 26 2007 Matthias Saou <http://freshrpms.net/> 1.3.7-4
- Re-enable libibverbs.
- Check and update License field to GPLv3+.
- Add glusterfs-common obsoletes, to provide upgrade path from old packages.
- Include patch to add mode to O_CREATE opens.
* Thu Nov 22 2007 Matthias Saou <http://freshrpms.net/> 1.3.7-3
- Remove Makefile* files from examples.
- Include RHEL/Fedora type init script, since the included ones don't do.
* Wed Nov 21 2007 Matthias Saou <http://freshrpms.net/> 1.3.7-1
- Major spec file cleanup.
- Add misssing %%clean section.
- Fix ldconfig calls (weren't set for the proper sub-package).
* Sat Aug 4 2007 Matt Paine <[email protected]> - 1.3.pre7
- Added support to build rpm without ibverbs support (use --without ibverbs
switch)
* Sun Jul 15 2007 Matt Paine <[email protected]> - 1.3.pre6
- Initial spec file