1 Summary: Cluster-based virtualization management software
6 Group: Applications/System
7 Source0: https://ganeti.googlecode.com/files/%{name}-%{version}.tar.gz
8 # Source0-md5: 9d9a0c5c0341d5775988961449f82b99
9 URL: https://code.google.com/p/ganeti/
10 BuildRequires: fakeroot
13 BuildRequires: ghc-QuickCheck
14 BuildRequires: ghc-curl
15 BuildRequires: ghc-haskell-platform
16 BuildRequires: ghc-json
18 BuildRequires: hscolour
20 BuildRequires: python-affinity
21 BuildRequires: python-modules
22 BuildRequires: python-paramiko
23 BuildRequires: python-pycurl
24 BuildRequires: python-pyinotify
25 BuildRequires: python-pyparsing
26 BuildRequires: python-simplejson
27 %if %{with initscript}
28 BuildRequires: rpmbuild(macros) >= 1.228
29 Requires(post,preun): /sbin/chkconfig
32 %if %{with systemd_service}
33 BuildRequires: rpmbuild(macros) >= 1.647
34 Requires(post,preun,postun): systemd-units >= 38
35 Requires: systemd-units >= 0.38
38 #BuildRequires: autoconf
39 #BuildRequires: automake
40 #BuildRequires: intltool
41 #BuildRequires: libtool
43 #Requires(pre,post): -
46 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
49 Ganeti is a cluster virtual server management software tool built on
50 top of existing virtualization technologies such as Xen or KVM and
51 other Open Source software.
57 # noarch subpackages only when building with rpm5
58 %if "%{_rpmversion}" >= "5"
62 %description subpackage
64 %description subpackage -l pl.UTF-8
73 %description libs -l pl.UTF-8
76 Summary: Header files for %{name} library
77 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki %{name}
78 Group: Development/Libraries
79 # if base package contains shared library for which these headers are
80 #Requires: %{name} = %{version}-%{release}
81 # if -libs package contains shared library for which these headers are
82 #Requires: %{name}-libs = %{version}-%{release}
85 Header files for %{name} library.
87 %description devel -l pl.UTF-8
88 Pliki nagłówkowe biblioteki %{name}.
91 Summary: Static %{name} library
92 Summary(pl.UTF-8): Statyczna biblioteka %{name}
93 Group: Development/Libraries
94 Requires: %{name}-devel = %{version}-%{release}
97 Static %{name} library.
99 %description static -l pl.UTF-8
100 Statyczna biblioteka %{name}.
106 # DON'T use full path to xl binary, just 'xl' (see lib/hypervisor/hv_xen.py for a reason)
110 PYLINT=/usr/bin/pylint \
111 SOCAT=/usr/bin/socat \
112 QEMUIMG_PATH=/usr/bin/qemu-img \
115 --enable-htools-rapi \
116 --enable-confd=python \
117 --enable-socat-escape \
118 --with-ssh-initscript=/etc/rc.d/init.d/sshd \
119 --with-ssh-config-dir=/stc/ssh \
121 --with-kvm-path=/usr/bin/qemu-kvm
126 rm -rf $RPM_BUILD_ROOT
128 %if %{with initscript}
129 install -d $RPM_BUILD_ROOT/etc/{sysconfig,rc.d/init.d}
131 #install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
134 DESTDIR=$RPM_BUILD_ROOT
137 rm -rf $RPM_BUILD_ROOT
140 %groupadd -g xxx %{name}
141 %useradd -u xxx -d /var/lib/%{name} -g %{name} -c "XXX User" %{name}
148 if [ "$1" = "0" ]; then
154 %post -p /sbin/ldconfig
155 %postun -p /sbin/ldconfig
158 %if %{with initscript}
160 /sbin/chkconfig --add %{name}
161 %service %{name} restart
164 if [ "$1" = "0" ]; then
165 %service -q %{name} stop
166 /sbin/chkconfig --del %{name}
170 %if %{with systemd_service}
172 %systemd_post %{name}.service
175 %systemd_preun %{name}.service
182 %defattr(644,root,root,755)
183 %doc AUTHORS CREDITS CHANGES ChangeLog NEWS README THANKS TODO
186 # if _sysconfdir != /etc:
187 #%%dir %{_sysconfdir}
188 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*
189 %attr(755,root,root) %{_bindir}/%{name}*
193 # initscript and its config
194 %if %{with initscript}
195 %attr(754,root,root) /etc/rc.d/init.d/%{name}
196 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/%{name}
199 %if %{with systemd_service}
200 %{systemdunitdir}/%{name}.service
203 #%{_examplesdir}/%{name}-%{version}
205 %if %{with subpackage}
207 %defattr(644,root,root,755)
209 #%{_datadir}/%{name}-ext