X-Git-Url: http://git.pld-linux.org/?a=blobdiff_plain;f=ctdb.spec;h=56567f8efd488516d16199db0144fd06661a4ea7;hb=d8b39754e541d785443828a7b2e505cfe8b7f721;hp=75485a2ec26ef4e2faef6481b91b082722fd2a8d;hpb=1401040710e2f07896e0ad782ba788497fc7f150;p=packages%2Fctdb.git diff --git a/ctdb.spec b/ctdb.spec index 75485a2..56567f8 100644 --- a/ctdb.spec +++ b/ctdb.spec @@ -6,28 +6,38 @@ # - add support for /sbin/ss instead of /bin/netstat (ss uses kernel netlink # which is huge win on server with loads of open tcp sockets) # - patch scripts for pld +# +# Conditional build: +%bcond_without ibverbs # InfiniBand support +%bcond_without pcp # Performance Co-Pilot support +# Summary: A Clustered Database based on Samba's Trivial Database (TDB) +Summary(pl.UTF-8): Klastrowa baza danych oparta na bazie danych Trivial Database z Samby (TDB) Name: ctdb -Version: 1.0.113 +Version: 2.5 Release: 1 License: GPL v3+ Group: Daemons +Source0: http://www.samba.org/ftp/ctdb/%{name}-%{version}.tar.gz +# Source0-md5: 274db3a1ec3858092ec7dc960bfd0c40 +Patch0: %{name}-ib.patch +Patch1: %{name}-format.patch URL: http://ctdb.samba.org/ -# Tarfile created using git -# git clone git://git.samba.org/sahlberg/ctdb.git ctdb -# cd ctdb -# git-archive --format=tar --prefix=%{name}-%{version}/ %{name}-%{version} | bzip2 > %{name}-%{version}.tar.bz2 -Source0: %{name}-%{version}.tar.bz2 -# Source0-md5: ce3eda943bf81c7c9e513ec715f4a785 -BuildRequires: autoconf -BuildRequires: net-tools +%{?with_pcp:BuildRequires: pcp-devel} +BuildRequires: popt-devel BuildRequires: rpmbuild(macros) >= 1.268 +BuildRequires: talloc-devel +BuildRequires: tdb-devel +BuildRequires: tevent-devel +%if %{with ibverbs} +BuildRequires: libibverbs-devel +BuildRequires: librdmacm-devel +%endif Requires(post,preun): /sbin/chkconfig Requires: coreutils Requires: psmisc Requires: rc-scripts Requires: sed -Requires: tdb BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) %description @@ -36,35 +46,67 @@ other projects to store temporary data. If an application is already using TDB for temporary data it is very easy to convert that application to be cluster aware and use CTDB instead. +%description -l pl.UTF-8 +CTDB to klastrowa implementacja bazy danych TDB używanej w Sambie oraz +innych projektach do przechowywania danych tymczasowych. Jeśli jakaś +aplikacja już wykorzystuje TDB do trzymania danych tymczasowych, +bardzo przerobić ją na klastrowalną, wykorzystującą CTDB. + %package devel Summary: CTDB clustered database development package +Summary(pl.UTF-8): Pakiet programistyczny klastrowej bazy danych CTDB Group: Development/Libraries +Requires: tdb-devel # does not require base %description devel -Libraries, include files, etc you can use to develop CTDB -applications. +Header files etc. you can use to develop CTDB applications. + +%description devel -l pl.UTF-8 +Pliki nagłówkowe i inne, przy użyciu których można tworzyć aplikacje +wykorzystujące CTDB. + +%package -n pcp-ctdb +Summary: CTDB PMDA +Summary(pl.UTF-8): PMDA CTDB +Group: Applications/System +Requires: %{name} = %{version}-%{release} +Requires: pcp + +%description -n pcp-ctdb +This PMDA extracts metrics from the locally running ctdbd daemon for +export to PMCD. + +%description -n pcp-ctdb -l pl.UTF-8 +Ten PMDA odczytuje pomiary z lokalnie działającego demona ctdbd w celu +wyeksportowania do PMCD. %prep %setup -q +%patch0 -p1 +%patch1 -p1 %build -sh -x ./autogen.sh - -CFLAGS="%{rpmcflags} $EXTRA -D_GNU_SOURCE -DCTDB_VERS=\"%{version}-%{release}\"" -%configure +%configure \ + %{?with_pcp:--enable-pmda} \ + %{?with_ibverbs:--enable-infiniband} %{__make} showflags %{__make} %install rm -rf $RPM_BUILD_ROOT -install -d $RPM_BUILD_ROOT/etc/{sysconfig,rc.d/init.d} +install -d $RPM_BUILD_ROOT{/etc/{sysconfig,rc.d/init.d},%{systemdunitdir}} %{__make} install \ DESTDIR=$RPM_BUILD_ROOT cp -a config/ctdb.sysconfig $RPM_BUILD_ROOT/etc/sysconfig/ctdb install -p config/ctdb.init $RPM_BUILD_ROOT/etc/rc.d/init.d/ctdb +cp -p config/ctdb.service $RPM_BUILD_ROOT%{systemdunitdir} +install -d $RPM_BUILD_ROOT%{systemdtmpfilesdir} +cat >$RPM_BUILD_ROOT%{systemdtmpfilesdir}/ctdb.conf <